0

I am writing a report in Latex, so I am writing the evidence found, each evidence is written in items, how to modify the white space when there is a line break?

enter image description here

I have tried:


    \begin{itemize}
       \setlength{\parsep}{-6pt}
       \setlength{\itemsep}{-6pt}
       % \setlength{\parskip}{0pt}
        \item item 1.
        \item item 2.
        \item item 3.
        \item item 4.
        \item long long long long long long long long long long long long long long long long long long long long long long long long long long long item 5.
        \item item 6.
    \end{itemize}

Thanks so much!!!

1
  • 4
    don't use negative values. Your items are overprinting. Jul 11, 2023 at 16:53

1 Answer 1

0

I would suggest using enumitem to help format lists. It provides an interface that makes changing the format easier.

For very compact lists, you can use the [nosep] option. This would make the spacing between individual items exactly the same as the spacing between lines in a running paragraph.

If for some reason you want the list to be even more compact, you can start playing with the value of \baselineskip. But I wouldn't recommend it as the output will be visually much more cramped than surrounding text, as you are basically overprinting. (In your picture, the descender on a g will overlap the ascender on an l from the line below.)

\documentclass{article}

\usepackage{enumitem}
\begin{document}

To remove all inter-item spacing:
\begin{itemize}[nosep]
\item item 1
\item item 2
\item item 3
        \item item 4.
        \item long long long long long long long long long long long long long long long long long long long long long long long long long long long item 5.
        \item item 6.
\end{itemize}
If the spacing between items are still too large, and you want it to be more compact then regular running text, you can also reduce baselineskip. But this makes text hard to read.
\begin{itemize}[nosep]
        \setlength{\baselineskip}{10pt}
        \item item 1
\item item 2
\item item 3
        \item item 4.
        \item long long long long long long long long long long long long long long long long long long long long long long long long long long long item 5.
        \item item 6.
\end{itemize}

\end{document}

enter image description here

1
  • If you are going to use nosep which also removes inter-paragraph space, I would also suggest adding listparindent=\parindent if you have items that span multiple paragraphs, so that paragraph breaks are visible. Jul 11, 2023 at 19:07

Not the answer you're looking for? Browse other questions tagged .