# How to change the font style of elements in KOMA-Script?

Is there a possibility to change the font-style in the table of contents? Everything I wrote down in my document was written with Times. However, the ToC does not have the same font family. Is there a way to change the font of the ToC to Times New Roman? Thank you : )

\documentclass[a4paper, fontsize=11pt]{scrbook}
\usepackage{geometry} \geometry{a4paper, top=25mm, left=25mm, right=25mm, bottom=20mm, headsep=10mm, footskip=12mm}
\usepackage[ngerman]{babel}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage{acronym}
\usepackage{anyfontsize}

\begin{document}

\tableofcontents

\chapter{Test}
Is there a possibility to change the font-style in the table of contents? Everthing I wrote down in my document was written with Times. However, the ToC does not have the same font family. Is there a way to change the font of the ToC to Times New Roman?

\end{document}

• The TOC has the same font as the main document. The reason why you must have something special defined. Show in an example that it is different! – user2478 Feb 13 '16 at 14:29
• I just guess you want all chaptertitles to be in roman, not sans: \addtokomafont{chapter}{\rmfamily} – Johannes_B Feb 13 '16 at 15:03
• Or if the the chapter titles in TOC should be in roman: \addtokomafont{chapterentry}{\rmfamily}. Or all headings in your document: \addtokomafont{disposition}{\rmfamily} – esdd Feb 13 '16 at 15:14
• @esdd Do you wanna write up an answer? We could mark the question by Nico Schlömer in the KOMA tag as a duplicate of this one here. Nico was asking for something about the title, but the question was too unclear to answer. – Johannes_B Feb 13 '16 at 16:04

Use \setkomafont or maybe better \addtokomafont to change the font settings for an element like the chapter heading.

For all headings in the document the element disposition is used first followed by a specific element for the section level. And the element disposition is also used for the chapter entries in TOC. Because it is predefined as \normalcolor\sffamily\bfseries all headings in the document will be sans serif while the normal font in the document is still roman.

If the headings of all section levels including the chapter entries in TOC should be changed to roman use

\addtokomafont{disposition}{\rmfamily}


If the heading of only a specific level should be roman change the settings for its specific element. For example if only the chapter heading should be changed to roman use

\addtokomafont{chapter}{\rmfamily}


If only the font of the chapter entries in TOC should be changed use the element chapterentry

\addtokomafont{chapterentry}{\rmfamily}


You can find a list of predefined elements in the documentation, section »Text markup«.

Code:

\documentclass{scrbook}
\usepackage{blindtext}% only dummy text
\begin{document}
\tableofcontents
\blinddocument
\end{document}


If you simply don't want sans serif fonts, use option egregdoesnotlikesansseriftitles:

\documentclass[egregdoesnotlikesansseriftitles]{scrbook}

\usepackage{mwe}

\begin{document}
\tableofcontents
\blinddocument
\end{document}


The option simply replaces all \sffamily in the default font settings of KOMA-Script. The result would be:

So not only the table of contents will not use sans serif fonts any longer but also the headings of chapter, section, subsection etc. and also, e.g., the labels of description environment.