GeneralChange chapter style in table of contents

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
lampageu
Posts: 1
Joined: Thu Jan 31, 2019 3:06 pm

Change chapter style in table of contents

Post by lampageu »

Code: Select all

\documentclass[12pt, times new roman, a4paper, onecolumn, oneside, final]{report}
\usepackage{tocbibind}
\usepackage{tocloft}
\usepackage{titletoc,tocloft}

\begin{document}
\setcounter{tocdepth}{3}
\tableofcontents

\addcontentsline{toc}{chapter}{Custom1}
\addcontentsline{toc}{chapter}{Custom2}
\addcontentsline{toc}{chapter}{Custom3}

\chapter{A}
\section{bla bla}
\section{bla bla}

\chapter{B}
\section{bla bla}

\chapter{C}
\end{document}
I get the following
Image
I want Custom1, Custom2, and Custom3 to be not bold and have dots leader. Right now, Custom1, Custom2, and Custom3 follows the style of Chapter A, B, C because I \addcontetsline Custom1, Custom2, and Custom3 as Chapter. Also the space(the blue line) between Custom1, Custom2, and Custom3 is too big, how could I make them smaller.

My attempt : If I change

Code: Select all

\addcontentsline{toc}{chapter}{Custom1}
\addcontentsline{toc}{chapter}{Custom2}
\addcontentsline{toc}{chapter}{Custom3}
to

Code: Select all

\addcontentsline{toc}{section}{Custom1}
\addcontentsline{toc}{section}{Custom2}
\addcontentsline{toc}{section}{Custom3}
I'll get the following
Image
which is close to what I want, but now Custom1, Custom2, and Custom3 got indented.

Any help appreciated.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

Post Reply