[Tex/LaTex] Left margin flush for itemize’s item labels in LaTeX

indentationline-breakinglists

I am trying to get the item label to flush with the left margin of the page width within itemize, i.e.:

This is my sentence. Here are my items:

  1. ITEMNAME
    • notice my list definition is indented
  2. ITEMNAME
    • but my item labels are all flush with the left margin and not sticking out of it

Note I am using \item[ITEMNAME] \hfill \\ to create a definition style item with a linebreak between keyword and definition, as demonstrated above. How can I get the desired flush that only affects the item's label?

Best Answer

Consider using the enumitem package to perform your list management. Here's an example of what you might be after:

enter image description here

\documentclass{article}
\usepackage{enumitem}% http://ctan.org/pkg/enumitem
\usepackage{showframe}% http://ctan.org/pkg/showframe
\begin{document}
\begin{description}
    [align=left,style=nextline,leftmargin=*,labelsep=\parindent,font=\normalfont]
  \item[FIRST ITEM] Note that my list definition is not indented
  \item[SECOND ITEM] This one is also not indented and the description
    is long enough to span two lines.
\end{description}
\end{document}

The optional argument to description performs:

  • align=left: Ensures a left-aligned item label;
  • leftmargin=*: Left margin of description is flush with left margin of text block;
  • style=nextline: Automates the process of using \hfill \\;
  • labelsep=\parindent: The gap between the label and the start of the item is \labelsep, which is set to be the same as the regular paragraph indent.
  • font=\normalfont: This modifies the default bold font of the description item to \normalfont.

If need be, you can also create a new list environment to perform these "optional settings" automatically. For this, see \newlist and \setlist in the enumitem documentation (section 7 Cloning the basic lists, p 10).

showframe was only used to emphasize the text block boundaries within the example.