我有一个奇怪的列表,被介绍其最后一项的正常文本打断:
\documentclass{memoir}
\usepackage{enumitem}
\usepackage{lipsum}
\begin{document}
\lipsum[1]
\begin{enumerate}[itemsep=-4pt]
\item My first item
\item My second item\\
Along with these should be mentioned:
\item My third item
\end{enumerate}
\end{document}
第二项和第三项之间的文本“除了这些……”应该脱离列表并从文本块的左边缘开始。如果可能的话,我该如何将其推到左边?
我已经在第 2 项和第 3 项之间尝试了以下操作,
\end{enumerate}
\vspace{-2\baselineskip}
Along with these should be mentioned:
\vspace{-\baselineskip}
\begin{enumerate}[itemsep=-4pt]
\setcounter{enumi}{2}
但行间空间有些偏离。
答案1
停止并恢复enumerate
:
\documentclass{memoir}
\usepackage{enumitem}
\usepackage{lipsum}
\begin{document}
\lipsum[1]
\begin{enumerate}[itemsep=-4pt]
\item My first item
\item My second item
\end{enumerate} %%<---------------------- stop here
Along with these should be mentioned:
\begin{enumerate}[resume] %%<----------- resume
\item My third item
\end{enumerate}
\end{document}
如果您想要紧密的间距:
\documentclass{memoir}
\usepackage{enumitem}
\usepackage{lipsum}
\begin{document}
\lipsum[1]
\begin{enumerate}[nosep]
\item My first item
\item My second item
\end{enumerate}
Along with these should be mentioned:
\begin{enumerate}[resume*]
\item My third item
\end{enumerate}
\end{document}
前后都有空格enumerate
:
\documentclass{memoir}
\usepackage{enumitem}
\usepackage{lipsum}
\begin{document}
\lipsum[1]
%\begin{enumerate}[nosep,before={\vspace{0.6\baselineskip}},after={\vspace{0.6\baselineskip}}] %% or shorter
\begin{enumerate}[noitemsep]
\item My first item
\item My second item
\end{enumerate}
Along with these should be mentioned:
\begin{enumerate}[resume*]
\item My third item
\end{enumerate}
Some text again
\end{document}