20

I'm attempting to modify the Table of Contents in my document. Currently, chapter one in my document is listed as

1   Introduction

What I would like to see is

Chapter 1   Introduction

Seems like an easy enough thing to ask for, but can't seem to find a good way to do this. Any feedback would be most appreciative.

2 Answers 2

21

The titletoc package provides ToC entry manipulation for a \chapter via \titlecontents*{chapter}:

enter image description here

\documentclass{book}
\usepackage{lipsum}% http://ctan.org/pkg/lipsum
\usepackage{titletoc}% http://ctan.org/pkg/titletoc
\titlecontents*{chapter}% <section-type>
  [0pt]% <left>
  {}% <above-code>
  {\bfseries\chaptername\ \thecontentslabel\quad}% <numbered-entry-format>
  {}% <numberless-entry-format>
  {\bfseries\hfill\contentspage}% <filler-page-format>

\begin{document}
\tableofcontents
\chapter{Introduction} \lipsum[1]
\section{First section} \lipsum[2-3]
\section{Second section} \lipsum[4-5]
\section{Last section} \lipsum[6-7]
\chapter{Second chapter} \lipsum[1]
\section{First section} \lipsum[2-3]
\section{Second section} \lipsum[4-5]
\section{Last section} \lipsum[6-7]
\chapter{Last chapter} \lipsum[1]
\section{First section} \lipsum[2-3]
\section{Second section} \lipsum[4-5]
\section{Last section} \lipsum[6-7]
\end{document}

For adding space between ToC chapter entries, you could use \addvspace{1em} (where 1em is the regular book documentclass chapter skip) for <above-code>:

\usepackage{titletoc}% http://ctan.org/pkg/titletoc
\titlecontents*{chapter}% <section-type>
  [0pt]% <left>
  {\addvspace{1em}}% <above-code>
  {\bfseries\chaptername\ \thecontentslabel\quad}% <numbered-entry-format>
  {}% <numberless-entry-format>
  {\bfseries\hfill\contentspage}% <filler-page-format>

enter image description here

7
  • 1
    Thanks Werner, pictures helped a lot in conveying the information. Thanks again for your help. Dec 23, 2011 at 4:58
  • Dear Werner, I have two questions related to this post which I am having similar problems. a) I would like to ask how if I want to have the word "Chapter" in the capital letter "CHAPTER"? b) If I use [\titlecontents*{chapter}% [0pt]% {\addvspace{1em}}% {\bfseries\chaptername\ \thecontentslabel\quad}% {}% {\bfseries\hfill\contentspage}% ] I get error message saying "chemmacros.sty" . undefined control sequence. Could you help to resolve this issue? Thank you.
    – Vijay
    May 27, 2015 at 6:36
  • @Vijay: (a) Use \MakeUppercase{\chaptername} or CHAPTER directly instead of \chaptername. (b) I don't understand what might be causing that.
    – Werner
    May 27, 2015 at 6:39
  • @Werner, I am using "Easy thesis" template which is based on "book" type document class (sharelatex.com/templates/52fdfd8234a287a85245b4c6). After the "\begin{document}" command, there is another command "\frontmatter". So I am not so sure where I supposed to add the "command" you suggested in the post. Additionally, In the template the chapters are numbered like 1. Introduction, 2. Literature review, and so on. So I tried to make the word "CHAPTER" in front of the chapter number but I fail. Hope you could help.
    – Vijay
    May 27, 2015 at 7:26
  • 1
    This solution causes formatting problems in case some of the chapters have have no sections. egreg's answer works better for my case.
    – TTT
    Feb 12, 2020 at 10:27
15

With tocloft one can use \cftchappresnum to put something before the number; but we have also to reserve enough space. I defer the space setting when the text font is already established.

\documentclass[a4paper]{book}
\usepackage{tocloft,calc}

\renewcommand{\cftchappresnum}{Chapter }
\AtBeginDocument{\addtolength\cftchapnumwidth{\widthof{\bfseries Chapter }}}

\begin{document}
\tableofcontents

\chapter{Introduction}
\end{document}
2
  • This also adds Chapter before Appendix. I wonder how to avoid this one. Thanks
    – MYaseen208
    Dec 23, 2011 at 7:53
  • 1
    This problem can be solved here.
    – RghtHndSd
    Mar 31, 2014 at 21:43

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .