[Tex/LaTex] Remove indent when using enumerate

indentation

When we use the enumerate environment, there's an indent created as you can see in the picture:

enter image description here

Is there a way to remove that indent so that everytime I use the enumerate stuff doesn't give me such indent?

Best Answer

It is not entirely clear whether you want to eliminate the indentation entirely or whether you want the items to be indented but not the labels. A.Ellett interpreted your question in one way and I in another.

Here's my answer based on my interpretation. This takes it that you want to eliminate the indentation entirely so that the list is like a series of numbered paragraphs.

\documentclass{article}
\usepackage{enumitem,kantlipsum}

\begin{document}
  \kant[1]
  \begin{enumerate}[wide, labelwidth=!, labelindent=0pt]
    \item \kant[2]
    \item \kant[3]
    \item \kant[4]
    \item \kant[5]
  \end{enumerate}
  \kant[6]
\end{document}

tweaked enumeration

  • wide is a convenience style for non-indented lists which are paragraph-like.

More specifically (page 8 of the manual), this key is equivalent to setting

align=left, leftmargin=0pt, labelindent=\parindent, listparindent=\parindent, labelwidth=0pt, itemindent=!

That is, align the label left within the label box, set the leftmargin to zero, indent labels and paragraphs by \parindent, set the width of labels to zero and calculate an appropriate indentation for items based on the other values.

We then tweak this by overriding some of the settings used by wide:

  • labelindent=0pt (overriding the value set by wide) says not to indent the label relative to the left margin.
  • labelwidth=! tells enumitem to calculate the appropriate width for the label (again overriding the value set by wide).

Alternatively, the following is based on A.Ellett's interpretation which understood you to want indented items but non-indented labels:

\documentclass{article}
\usepackage{enumitem,kantlipsum}

\begin{document}
  \kant[1]
  \begin{enumerate}[leftmargin=*]
    \item \kant[2]
    \item \kant[3]
    \item \kant[4]
    \item \kant[5]
  \end{enumerate}
  \kant[6]
\end{document}

tweaked enumeration

  • leftmargin=* calculates an appropriate value for leftmargin based on the current label.