2

I am currently using \section{} followed by \begin{enumerate} to create numbered lists.

I would like the first number of the enumerated list to be the section number.

So Instead of:

2. Application of Income...
   1. ...

      1.1 ...

      1.2 ...
   2. ...

It would be:

2. Application of Income
   
   2.1 ...

          2.1.1 ...

          2.1.2 ...
   2.2

I would have just started each new section as \begin{enumerate}, however, I would like the sections to be included in a table of contents. If you think it would be easier to do this, and reference the first item the TOC, please let me know and would you mind providing an example of the code. Many thanks

The full file to replicate:

\documentclass[a4paper,12pt]{extarticle}
\usepackage[utf8]{inputenc}

% Section Headers
\usepackage{titlesec}
\titlespacing*{\section}{0mm}{9mm}{9mm}
\titleformat{\section}{\Large\bfseries}{\arabic{section}.}{0.5em}{}[\titlerule]

% Lists
\usepackage{enumitem}
\setlist{topsep=0pt,noitemsep,leftmargin=1.3cm}
\setlist[enumerate,1]{label*=\arabic*.}      
\setlist[enumerate,2]{label*=\arabic*.}
\setlist[enumerate,3]{label*=\arabic*.}


\begin{document}
\tableofcontents

\section{Powers}
\begin{enumerate}
    \item The CIO has power to do anything which is calculated to further its 
\begin{enumerate}
\item Borrow money and to charge the whole or any part of its property as security for 
\item Buy, take on lease or in exchange, hire or 
\item Sell, lease or otherwise dispose of all or any part of the property belonging to the 
\end{enumerate}
\end{enumerate}

\section{Application of Income and Property}
\begin{enumerate}
    \item The income and property of the CIO must be applied solely 
        \begin{enumerate}
        \item A charity trustee is entitled to be reimbursed from the property of the CIO or may pay 
        \item A charity trustee may benefit from trustee indemnity insurance cover purchased at the CIO’s expense in accordance with, and subject to the 
        \end{enumerate}         
    \item None of the income or property of the CIO may be paid or transferred
\end{enumerate}

\end{document}

1 Answer 1

2

You can just add \thesection to your first label definition:

\documentclass[a4paper,12pt]{extarticle}
\usepackage[utf8]{inputenc}

% Section Headers
\usepackage{titlesec}
%\titlespacing*{<command>}{<left>}{<before-sep>}{<after-sep>}
\titlespacing*{\section}{0mm}{9mm}{9mm}
\titleformat{\section}{\Large\bfseries}{\arabic{section}.}{0.5em}{}[\titlerule]

% Lists
\usepackage{enumitem}
\setlist{topsep=0pt,noitemsep,leftmargin=1.3cm}
\setlist[enumerate,1]{label*=\thesection.\arabic*.}
\setlist[enumerate,2]{label*=\arabic*.}
\setlist[enumerate,3]{label*=\arabic*.}


\begin{document}

\section{Powers}
\begin{enumerate}
    \item The CIO has power to do anything which is calculated to further its 
\begin{enumerate}
\item Borrow money and to charge the whole or any part of its property as security for 
\item Buy, take on lease or in exchange, hire or 
\item Sell, lease or otherwise dispose of all or any part of the property belonging to the 
\end{enumerate}
\end{enumerate}

\section{Application of Income and Property}
\begin{enumerate}
    \item The income and property of the CIO must be applied solely 
        \begin{enumerate}
        \item A charity trustee is entitled to be reimbursed from the property of the CIO or may pay 
        \item A charity trustee may benefit from trustee indemnity insurance cover purchased at the CIO’s expense in accordance with, and subject to the 
        \end{enumerate}         
    \item None of the income or property of the CIO may be paid or transferred
\end{enumerate}

\end{document}

output of code

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.