TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

It can be easily done with tocloft, however, as there are already many settings for the whole document, using it caused the changing of spacing, and some conflicts with other packages, etc, compared to the original style for book class.

enter image description here

So how to change the font of page numbers for chapters, sections , tabs and figs.. in front matter, without use of tocloft package.

Edit 1:

Using tocloft

\usepackage[ ]{tocloft}
\renewcommand{\cftchappagefont}{\bfseries \sffamily}
\renewcommand{\cftsecpagefont}{ \sffamily}
\renewcommand{\cftsubsecpagefont}{ \sffamily}  
\renewcommand{\cftsubsubsecpagefont}{ \sffamily}
\renewcommand{\cftfigpagefont}{ \sffamily}
\renewcommand{\cfttabpagefont}{ \sffamily}

The error:

enter image description here

The following commands have been commented:

% \setcounter{tocdepth}{3}  
% \setcounter{secnumdepth}{3}

I dont know if tocloft is conflicted with \usepackage[nottoc]{tocbibind}.

Besides, the spacing between entries in TOC, LOT, LOF are enlarged, and the blank pages are also removed which is created by default in book class.

share|improve this question
It might help if you explain why you can't use tocloft. – Joseph Wright Feb 9 '13 at 13:49

The formatting of these lines is controlled by macros \l@chapter \l@section etc. In book class, \l@chapter has a custom definition but all the rest are defined in terms of \@dottedcontentsline so it is enough to redefine just those two commands to use a custom font. Here I use italic and colour to highlight the effect.

enter image description here









share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.