5

Right now every time i end an enumerate/itemize i add the following: \\ To obtain a line break. Is there any way to do this only once and not have to keep repeating it??

6
  • 1
    Welcome to the site! A new line should begin at the end of a enumerate/itemize environment by default. Can you show us some complete but minimal code that shows the problem? You can edit this into your question. Commented Jan 13, 2015 at 20:58
  • 1
    You should almost never need to use \\ in a document other than to end a table row, hard to say what markuo to use without an example document. Commented Jan 13, 2015 at 21:03
  • Welcome to TeX.SX! You can have a look at our starter guide to familiarize yourself further with our format. Commented Jan 13, 2015 at 21:06
  • Thanks everyone for your help. Everyone's so nice it's rather weird :P
    – Moody
    Commented Jan 13, 2015 at 21:23
  • @Moody WE COULD BE RUDE AND SHOUT AT YOU IF YOU PREFER Commented Jan 13, 2015 at 21:29

2 Answers 2

4

Load the package enumitem and add the following lines to your preamble

\setlist[enumerate]{after={\bigskip}}
\setlist[itemize]{after={\bigskip}}

MWE

\documentclass{article}
\usepackage{enumitem}
\setlist[enumerate]{after={\bigskip}}
\setlist[itemize]{after={\bigskip}}

\begin{document}

\begin{itemize}
  \item aaa
  \item bbb
\end{itemize}
Some text

\begin{enumerate}
  \item aaa
  \item bbb
\end{enumerate}
Some text

\end{document} 

Output

enter image description here

2
  • ah and meanwhile I added an answer I wonder if I should delete mine now or leave it since it's marginally different:-) +1 anyway:-) Commented Jan 13, 2015 at 21:20
  • @Moody Glad to help, but to say thanks over here, we accept answers to mark the question as solved. See How do you accept an answer?. So accept either mine or David's answer (the one that you think helped you most) :-) Commented Jan 14, 2015 at 17:40
4

You should avoid using \\in documents.the space around a list is \topsep most easily set using the enumitem package:

enter image description here

\documentclass{article}

\usepackage{enumitem}
\setlist[enumerate]{topsep=1cm}

\begin{document}




aaaa
\begin{enumerate}
\item zzzzz
\item zzzzz
\item zzzzz
\end{enumerate}
aaaaaa


\end{document}
6
  • What about if i want to add a new line? Should i still not use \\?
    – Moody
    Commented Jan 13, 2015 at 21:26
  • 9999 times out of 10, when people add \\ to force a line break it would be better if they used some different markup (such as a blank line). but without an example of where you are using this it is hard to say. Commented Jan 13, 2015 at 21:27
  • I use it usually like this: \item Title\\ paragraph \item Title 2\\ paragraph 2
    – Moody
    Commented Jan 13, 2015 at 21:36
  • You can use backticks ` to show inline code:-) If it is an item title it should be better marked up as such, possibly with \item[title] paragraph using a suitable list environment such as description or a custom list. As well as making the source file clearer it will give better output, in particular control (suppression) of page break between the title and paragraph Commented Jan 13, 2015 at 21:53
  • Anyway, modifying topsep you are modifying also the spacing before the list and this was not requested by the OP... Commented Jan 14, 2015 at 11:27

You must log in to answer this question.

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