2

I want my table of contents to be displayed in two halves side by side on the same page, what am I supposed to do?

  • 1
    Please tell us which document class you employ. – Mico Nov 9 at 8:29
2

A way with multicol package:

\documentclass{article}
\usepackage{multicol}
\begin{document}
\begingroup% In order to make local the \columnsep change bellow
% As @Mico suggested you may handle the separation space of the columns
% by un-commenting the next line:
%\setlength\columnsep{20pt}
\begin{multicols}{2}
\tableofcontents
\end{multicols}
\endgroup
\part{part A}
\section{Test A}
Test
\section{Test B}

\subsection{Test BA}
\subsection{Test BB}
\section{Test C}
\section{Text D}
\part{part B}
\section{Test A}
Test
\section{Test B}

\subsection{Test BA}
\subsection{Test BB}
\section{Test C}
\section{Text D}
\part{part C}
\section{Test A}
Test
\section{Test B}

\subsection{Test BA}
\subsection{Test BB}
\section{Test C}
\section{Text D}
\part{part D}
\section{Test A}
Test
\section{Test B}

\subsection{Test BA}
\subsection{Test BB}
\section{Test C}
\section{Text D}
\end{document}

Output:

enter image description here

  • Also see this post that allows many many things in customizing any "table of ...": tex.stackexchange.com/a/503458/120578 – koleygr Nov 9 at 8:27
  • 2
    +1. You may want to add a comment to point out that if the OP wants to increase the horizontal distance between the columns, he/she can do so by changing the value of the length parameter \columsep; e.g., \setlength\columnsep{20pt}. (The default value of the parameter in most document classes is 10pt.) – Mico Nov 9 at 8:40
  • Thanks @Mico ... Added your comment's suggestion in the code given. – koleygr Nov 9 at 8:56
0

The tocloft and multicol package help with this.

\documentclass{...}
\usepackage{tocloft}
\usepackage{multicol}
% twocolumn ToC
\renewcommand{\cfttocprehook{\begin{multicols}{2}}
\renewcommand{\cfttocposthook}{\end{multicols}}
% twocolumn LoF (if required)
 \renewcommand{\cftlofprehook{\begin{multicols}{2}}
 \renewcommand{\cftlofposthook}{\end{multicols}}
% twocolumn LoT (if required)
 \renewcommand{\cftlotprehook{\begin{multicols}{2}}
 \renewcommand{\cftlotposthook}{\end{multicols}}

\begin{document}
\tableofcontents % in twocolumn
\listoffigures   % in twocolumn if \cftlofp... renewed 
\listoftables    % in twocolumn if \cftlotp... renewed
% etc
\end{document}

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.