Remova a margem superior em multicolunas \enumerate

Remova a margem superior em multicolunas \enumerate

Estou tentando combinar os ambientes multicols e enumerate (alternativamente, os pacotes multicols e enumitem). Basicamente, quero me livrar da margem superior ao enumerar dentro do multicol. As configurações usuais, conforme mostrado abaixo, falham. Obrigado!

Aqui está meu exemplo mínimo:

\documentclass{article}
\usepackage{enumitem}
\usepackage{multicol}

\begin{document}
I can get rid of the margin here:
\begin{enumerate}[topsep=0pt]
    \item a
    \item b
\end{enumerate}
\vspace{10pt}

but not here
\begin{multicols}{2}
\begin{enumerate}[topsep=0pt]
    \item a
    \item b
\end{enumerate}
\end{multicols}
\vspace{10pt}

and
\begin{multicols}{2}
[not even like so]
\begin{enumerate}[noitemsep,nolistsep,partopsep=-20pt,topsep=-20pt]
    \item a
    \item b
\end{enumerate}
\end{multicols}

\end{document}

e aqui está a saída:

insira a descrição da imagem aqui

Responder1

Você pode eliminar isso através de \setlength\multicolsep{0pt}:

insira a descrição da imagem aqui

Código:

\documentclass{article}
\usepackage{enumitem}
\usepackage{multicol}


\begin{document}
I can get rid of the margin here:
\begin{enumerate}[topsep=0pt]
    \item a
    \item b
\end{enumerate}
\vspace{10pt}

and also here
{\setlength\multicolsep{0pt}%
\begin{multicols}{2}
\begin{enumerate}[topsep=0pt]
    \item a
    \item b
\end{enumerate}
\end{multicols}}
\vspace{10pt}

and
{\setlength\multicolsep{0pt}%
\begin{multicols}{2}
[also like so]
\begin{enumerate}[noitemsep,nolistsep,partopsep=-20pt,topsep=-20pt]
    \item a
    \item b
\end{enumerate}
\end{multicols}}

\end{document}

informação relacionada