Hi,
I am using the class book. My book has a table of content in 3 Depth : Chapter, section and subsection.
My editor is asking me to get the subsection in italic in the table of content. How can I do this ?
Text Formatting ⇒ How to control the text format in table of content
How to control the text format in table of content
Last edited by gwada74 on Sat Mar 19, 2011 3:33 pm, edited 1 time in total.
- localghost
- Site Moderator
- Posts: 9201
- Joined: Fri Feb 02, 2007 12:06 pm
How to control the text format in table of content
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes[/size]
¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1
Board Rules
Avoidable Mistakes[/size]
¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1
How to control the text format in table of content
Sorry about this simple question; I've found the solution :
Code: Select all
subsection\[textit{title}]{title}
- localghost
- Site Moderator
- Posts: 9201
- Joined: Fri Feb 02, 2007 12:06 pm
How to control the text format in table of content
That's far from being recommendable. Furthermore it won't work because it is syntactically wrong. The tocloft way is the better one.gwada74 wrote:[…] I've found the solution :Code: Select all
subsection\[textit{title}]{title}
Code: Select all
\documentclass[11pt,a4paper,english]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{babel}
\usepackage{tocloft}
\usepackage{blindtext}
\renewcommand{\cftsubsecfont}{\itshape}
\renewcommand{\cftsubsecpagefont}{\itshape}
\begin{document}
\tableofcontents
\medskip
\blinddocument
\end{document}
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes[/size]
¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1
Board Rules
Avoidable Mistakes[/size]
¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1