8

I'm wondering how to show the original enumerating instead of alpha inside the list. enumitem package is included.

\documentclass{article}
\usepackage{enumitem}
\begin{document}
    \begin{enumerate}[label=(\alph*)]
      \item The first item
      \begin{enumerate}[label*=\arabic*.]
        \item Nested item 1
        \item Nested item 2
      \end{enumerate}
      \item The second item
      \item The third etc \ldots
    \end{enumerate}
\end{document}

What the code gives:

enter image description here

What I want to achieve:

enter image description here

Am I missing something? Thanks in advance.

8

Just omit the * after label in the inner enumerate. The star appends the labelling of the outer ('parent') list to the inner list.

\documentclass{article}
\usepackage{enumitem}
\begin{document}
    \begin{enumerate}[label={(\alph*)}]
      \item The first item
        \begin{enumerate}[label={\arabic*.}]
        \item Nested item 1
        \item Nested item 2
      \end{enumerate}
      \item The second item
      \item The third etc \ldots
    \end{enumerate}
\end{document}

enter image description here

  • what is * doing after \alph and \arabic? – Fibo Kowalsky Nov 14 '18 at 21:54
  • 2
    @FiboKowalsky: Reading the manual helps: It is an internal format for enumerate labels, in order to prevent the code using \alph and \arabic directly. – user31729 Nov 15 '18 at 16:35
6

Remove the * from the label= in the nested list:

\documentclass{article}
\usepackage{enumitem}
\begin{document}
    \begin{enumerate}[label=(\alph*)]
      \item The first item
      \begin{enumerate}[label=\arabic*.]
        \item Nested item 1
        \item Nested item 2
      \end{enumerate}
      \item The second item
      \item The third etc \ldots
    \end{enumerate}
\end{document}

Gives you the list you want:

List

  • Yes, it seems as if you were a little bit faster than me with writing your answer. When submitting mine, I didn't see there is another one. I'm new to stackexchange - how do you usually handle those "duplicate replys"? Shall I remove mine? Or just leave it there? – Florian Bach Dec 8 '15 at 20:16
  • 3
    Apparently you're German: Wo kein Richter da kein Henker ;-) Willkommen bei TeX.SX -- der Guten Seite der Typographie ;-) – user31729 Dec 8 '15 at 20:18

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.