jbezos / enumitem

Customize enumerate, itemize and description
MIT License
45 stars 5 forks source link

[Feature Request] Support a "botsep" that can be set to different value from topsep #39

Open Ruminateer opened 2 years ago

Ruminateer commented 2 years ago

The package uses topsep for the margin before and after the listing. I wish to be able to set the bot margin differently from the top margin. Maybe have a key called botsep that

I understand that we can workaround this by using the after key, but I am having a problem using after with vspace. Here is a minimal example to reproduce the issue

\documentclass{article}
\usepackage{enumitem}
\setlist{nosep}

\begin{document}
    \begin{itemize}
        \item aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa bbbbbc
        \vspace*{0ex}
    \end{itemize}
    after
\end{document}

The last c in the example will introduce extra unwanted space between the line and after. image

If we just make the line one character shorter the issue is gone. image

In this example, I can get around this by adding an empty line or \par before the \vspace. image

For the package seems that after=\par\vspace*{0ex} will result in a compile error. I asked on https://tex.stackexchange.com/ and found that I can use \endgraf instead of \par to make it work. But I still think a built-in botsep will make life a lot easier, especially for those who are not experts in latex.

mforbes commented 11 months ago

A couple of comments:

There are a variety of relevant topics at TeX Stack Exchange. The following look for a customizable \parbottomsep.

Others would benefit from \bottomsep, but the specific questions can be answered by using before= and after=.

Some potential issues/interactions to also consider (just collecting for now: these might not be useful):