项目符号 - 设置第一个单词和句子其余部分之间的距离

项目符号 - 设置第一个单词和句子其余部分之间的距离

我有一篇在 Word 中编写的文本,现在想将其转移到 Latex。在要点中我遇到了两个问题。

1- 我无法在符号和解释之间设置恒定的间距(见图)

2-如果句子分为两行,我无法告诉 Latex 在解释下面继续。

下图显示了我想要的:

在此处输入图片描述

我目前的代码是:

\begin{itemize}
\setlength\itemsep{0em}
\item  $p_{3} (\lambda)$ : \tab \tab is the spectrally resolved power density after reflection in glass$ \vert $ polymer interface once 

\item  \( P_{3}: \) \tab \tab is the power loss in glass due to reflection in glass$ \vert $ polymer interface once\

\item  \(  \Delta P_{rel.f_{3}}: \) \tab \tab is the relative power loss reflected on the glass$ \vert $ polymer interface once

\item  \( p_{4} \left(  \lambda  \right) : \) \tab \tab is the spectrally resolved power density after absorption in polymer once

\item  \( P_{4}: \) \tab \tab is the power loss in glass due to absorption in polymer once

\item  \(  \Delta P_{rel.f_{4}}: \) \tab \tab is the relative power loss absorbed by the polymer once
\end{itemize}{}

我的 Latex 结果如下所示:

在此处输入图片描述

在此处输入图片描述

答案1

我认为您最好使用tabular-type 设置而不是itemize设置。下面显示的答案采用了tabularx总宽度的环境\textwidth;第二列的宽度由 LaTeX 计算为残差。

下面构建了两次环境tabularx——第一次带有前导文本项目符号,第二次没有。我个人认为文本项目符号甚至没有必要。

列间空白的宽度由参数 控制\tabcolsep;在大多数文档类中,它的默认值是。您可以通过and/or语句6pt随意更改它。\setlength\addtolength

请注意,我还用 替换了所有 实例$\vert$\slash因为我相信/分隔符更容易阅读和理解。

在此处输入图片描述

\documentclass{article}
\usepackage{tabularx,ragged2e,booktabs}
\newcolumntype{L}{>{\RaggedRight\arraybackslash}X}
\usepackage{caption}
\captionsetup{justification=RaggedRight,
              singlelinecheck=false,
              skip=0.5\baselineskip}
\begin{document}

\begin{figure}[ht!]
\caption{Workflow of the spectrally resolved optical model and\dots}
\textbf{Nomenclature}

\medskip
\begin{tabularx}{\textwidth}{@{}>{\textbullet\ }l L @{}}
$p_{3} (\lambda)$ & spectrally resolved power density after reflection in glass\slash polymer interface once \\ 
$P_{3}$ & power loss in glass due to reflection in glass\slash polymer interface once\\
$\Delta P_{\mathit{rel.f}_{3}}$ & relative power loss reflected on the glass\slash polymer interface once\\
$p_{4}(\lambda)$ & spectrally resolved power density after absorption in polymer once\\
$P_{4}$ & power loss in glass due to absorption in polymer once\\
$\Delta P_{\mathit{rel.f}_{4}}$ & relative power loss absorbed by the polymer once
\end{tabularx}
\end{figure}

%% second solution: same as the first, except no text bullets
\begin{figure}[h!]
\caption{Same material, but without text bullets}
\textbf{Nomenclature}

\medskip
\begin{tabularx}{\textwidth}{@{} l L @{}}
$p_{3} (\lambda)$ & spectrally resolved power density after reflection in glass\slash polymer interface once \\ 
$P_{3}$ & power loss in glass due to reflection in glass\slash polymer interface once\\
$\Delta P_{\mathit{rel.f}_{3}}$ & relative power loss reflected on the glass\slash polymer interface once\\
$p_{4}(\lambda)$ & spectrally resolved power density after absorption in polymer once\\
$P_{4}$ & power loss in glass due to absorption in polymer once\\
$\Delta P_{\mathit{rel.f}_{4}}$ & relative power loss absorbed by the polymer once
\end{tabularx}
\end{figure}

\end{document}

答案2

description环境下,使用enumitem

\documentclass{article}
\usepackage{enumitem}

\begin{document}
    \begin{description}[font=\normalfont\textbullet\space,%https://tex.stackexchange.com/questions/149187/
                        leftmargin=6em, labelsep=0em, labelwidth=6em]
\item[$p_{3}(\lambda)$:] is the spectrally resolved power density after reflection in glass$ \vert $ polymer interface once

\item[$P_{3}$:] is the power loss in glass due to reflection in glass$ \vert $ polymer interface once\

\item[$\Delta P_{rel.f_{3}}$:] is the relative power loss reflected on the glass$ \vert $ polymer interface once

\item[$p_{4}(\lambda)$:] is the spectrally resolved power density after absorption in polymer once

\item[$P_{4}$:] is the power loss in glass due to absorption in polymer once

\item[$\Delta P_{rel.f_{4}}$:] is the relative power loss absorbed by the polymer once
    \end{description}
\end{document}

在此处输入图片描述

答案3

我提出另一种解决方案,description在包的帮助下,基于 定义一个新环境eqparbox

\documentclass{book}
\usepackage{etoolbox}
\usepackage{eqparbox}
\usepackage{enumitem}
\newenvironment{mynomencl}{%
\renewcommand*\descriptionlabel[1]{%
\hspace\labelsep \eqmakebox[DL][l]{\textbullet\quad ##1}}\description[font=\normalfont, leftmargin=\dimexpr\eqboxwidth{DL} + \labelsep]}%
{\enddescription}

\begin{document}

\begin{mynomencl}
\item[$p_{3} (\lambda)$ :] is the spectrally resolved power density after reflection in glass$ \vert $ polymer interface once

\item[\( P_{3}: \)] is the power loss in glass due to reflection in glass$ \vert $ polymer interface once\

\item[\( \Delta P_{rel.f_{3}}: \)] is the relative power loss reflected on the glass$ \vert $ polymer interface once

\item[\( p_{4} \left( \lambda \right) : \)] is the spectrally resolved power density after absorption in polymer once

\item[\( P_{4}: \)] is the power loss in glass due to absorption in polymer once

\item[\( \Delta P_{rel.f_{4}}: \)] is the relative power loss absorbed by the polymer once
\end{mynomencl}

\end{document} 

在此处输入图片描述

相关内容