4

I have an enumerated list with points, intersected with comments to each point. I would like to align my comments vertically with the itemized points in the enumerated list. Below a MWE with its output.

\documentclass{article}
\usepackage{enumitem}
\begin{document}
\begin{enumerate}[align=left, label=\large{\textbf{\arabic*}}]
    \item Here is my first point.
\end{enumerate}
\textbf{C:} Here is my comment to the first point.
\begin{enumerate}[resume, align=left, label=\large{\textbf{\arabic*}}]
    \item Here is my second point.
\end{enumerate}
\textbf{C:} Here is my comment to the second point.
\end{document}

enter image description here

My desired output would be something like this (ignore the curly braces):

1 { } Here is my first point.

C { } Here is my comment to the first point.

2 { } Here is my second point.

C { } Here is my comment to the second point.


Edit: As David & Werner suggest:

\documentclass{article}
\usepackage{enumitem}
\newcommand{\citem}{\item[\textbf{C:}]}
\begin{document}
\begin{enumerate}[align=left, label=\large{\textbf{\arabic*}}]
    \item Here is my first point.
    \citem Here is my comment to the first point.
    \item Here is my second point.
    \citem Here is my comment to the second point.
\end{enumerate}
\end{document}

enter image description here

  • @lockstep Is my understanding of horizontal and vertical alignment wrong here? I assumed that when you want to align items on a (invisible or visible) horizontal line, that's horizontal alignment, and when you want to align items on a (invisible or visible) vertical line, that's vertical alignment. Since I aim to accomplish the latter, I thought it would be vertical, and not horizontal, alignment. – Sverre May 24 '13 at 13:39
  • 2
    In light of Consistent typography, and depending on the usages, define something like \newcommand{\citem}{\item[\textbf{C:}]} and use \citem My comment. – Werner May 24 '13 at 13:55
  • 1
    @Sverre Maybe think of it like this: aligning things vertically involves sliding them up or down, while aligning things horizontally involves sliding them left or right. – John Wickerson May 24 '13 at 14:16
  • 1
    @Sverre, the items and comments display their first character/letter at a certain $x$ coordinate. You want these coordinates to be the same. The $x$-axis is the horizontal axis, hence horizontal alignment. But anyway, its just terminology. – jmc May 24 '13 at 14:17
  • 2
    @JohnWickerson, typographically speaking, wouldn't it be even better to have the comments indented a bit more then the items. Since they depend on the item above them (as opposed to introducing the item below them). – jmc May 24 '13 at 14:19
3

Just use a single enumerate environment and use \item[C:] for your comments.

2

One possible solution is to define a list-like environment with the appropriate settings for the comments:

\documentclass{article}
\usepackage{enumitem}

\newlist{mycomm}{enumerate}{1}
\setlist[mycomm]{align=left,label=\bfseries C:}
\newcommand\mycomment[1]{%
  \begin{mycomm}\item#1\end{mycomm}}

\begin{document}
\begin{enumerate}[align=left, label=\large\bfseries\arabic*]
    \item Here is my first point.
\end{enumerate}
\mycomment{Here is my comment to the first point.}
\begin{enumerate}[resume*]
    \item Here is my second point.
\end{enumerate}
\mycomment{Here is my comment to the second point.}

\end{document}

enter image description here

Notice that \large doesn't take arguments. Using resume* you don't have to specify again the previous settings.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.