I use the tocloft package to design the Table of Contents. I want the part entries listed in one column and all the other entries such as chapter, section, subsection ... should be listed in two columns. For example, I want to have:
Part I entry
------------------------------------ \hrule ---------------------------------
Chapter 1 chapter title ............ 1|Chapter 2 chapter title ............ 4
1.1 section title............. 2| 2.1 section title............. 5
1.1.1 subsection title ... 3| 2.1.1 subsection title ... 6
Part 2 entry
------------------------------------ \hrule ---------------------------------
Chapter 3 chapter title ............ 7|Chapter 4 chapter title ........... 10
3.1 section title............. 8| 4.1 section title............ 11
3.1.1 subsection title ... 9| 4.1.1 subsection title .. 12
Em, the following is my MWE:
% !Mode:: "TeX:UTF-8"
\documentclass{book}
\usepackage{tocloft}
\usepackage{etoolbox}
\usepackage{tikz}
\renewcommand\cftpartafterpnum{\nopagebreak\vspace{-.7em}\par\tikz\draw (0,-0.1) -- (0,0) -- (\linewidth,0) -- (\linewidth, -0.1);\vspace{-2em}}
\setlength{\cftpartnumwidth}{0pt}
\setlength{\cftbeforepartskip}{.6em}
\makeatletter
\renewcommand{\cftpartfont}{\bfseries%
\def\numberline##1{\gdef\@temp@numberline{##1}}%
}
\renewcommand{\cftpartfillnum}[1]{%
{}%
{\centering\makebox[0em]{\cftpartpagefont}\cftpartafterpnum}%
}
\makeatother
% http://tex.stackexchange.com/questions/78980/how-to-emulate-titletoc-with-tocloft
\pretocmd{\part}{\addtocontents{toc}{\par}}{}{}
\pretocmd{\chapter}{\addtocontents{toc}{\par}}{}{}
\begin{document}
\tableofcontents
\part{Part Title}
\chapter{Chapter Title}
\section{Section Title}
\subsection{Subsection Title}
\subsubsection{Subsubsection Title}
\subsubsection{Subsubsection Title}
\section{Section Title}
\section{Section Title}
\subsection{Subsection Title}
\part{Part Title}
\chapter{Chapter Title}
\section{Section Title}
\subsection{Subsection Title}
\section{Section Title}
\section{Section Title}
\subsection{Subsection Title}
\subsubsection{Subsubsection Title}
\part{Part Title}
\chapter{Chapter Title}
\section{Section Title}
\subsection{Subsection Title}
\section{Section Title}
\section{Section Title}
\subsubsection{Subsubsection Title}
\end{document}
So how can I make all entries in two columns except the part ones just like the sample style presented Here.
Thanks.
