0

Coming from How to obtain a minitoc with classicthesis?, i now use etoc to produce local tocs with classicthesis style. However, the use of the etoc package alters the style of the contents heading to default, as shown in the picture. In the answer of https://tex.stackexchange.com/a/588678/306222, etoc does not show that behavior. I use the same minimal example. Altered heading style

Do you have any idea? Tested on two different computers, both with TexLive2023.

3
  • The linked MWE works correctly for me with texlive 2021 and 2023. You did not change anything? What do you to compile?
    – dexteritas
    Commented Oct 18, 2023 at 13:26
  • No, I use the original classicthesis 1.4 preferences and also compiled the MWE with Texlive 2023.
    – Albert3r4
    Commented Oct 18, 2023 at 14:20
  • As soon as i uncomment \usepackage{etoc}, the content header is displayed in the desired style.
    – Albert3r4
    Commented Oct 18, 2023 at 14:35

1 Answer 1

2

First, side remark, if I compile the linked example I do not get the same typeface as in your screenshot for the chapter titles. Second, yes loading etoc apparently undoes the modification done by classicthesis to the global TOC style. But there is \etockeeporiginaltableofcontents which allows \tableofcontents to retain a non-etoc behaviour.

TOC

Code from https://tex.stackexchange.com/a/588678/306222 solely modified via addition of \etockeeporiginaltableofcontents.

\documentclass[a4paper]{report}

\usepackage{kantlipsum} % dummy text <<<<

\usepackage{classicthesis}
\usepackage{etoc} % added <<<<<<<<<<<<
\etockeeporiginaltableofcontents
\begin{document}

\tableofcontents

\etocsettocstyle{\vskip0.3\baselineskip}{\noindent\rule{\linewidth}{0.5pt}\vskip0.5\baselineskip} % etoc style for local TOC

\chapter{Apple}
\localtableofcontents %<<<<<<<<<<<<<<

1. \kant[1]
\section{Alabama}
2. \kant[2-4]
\section{Arizona}
3. \kant[5-7]
\subsection{Afghanistan}
4. \kant[8-9]
\subsection{Austria}
4. \kant[10-12]

\chapter{Banana}
\localtableofcontents %<<<<<<<<<<<<<<

6. \kant[14]
\section{Split}
7. \kant[15]

\chapter{Cherry}
\localtableofcontents %<<<<<<<<<<<<<<

7. \kant[18]

\end{document}
2
  • Could the different typeface stem from different classicthesis versions? Or different package options? The "\etockeeporiginaltableofcontents" solved the problem with the heading style, thank you!
    – Albert3r4
    Commented Oct 23, 2023 at 8:13
  • I suppose indeed different package options influenced the output, I compiled with a copy-paste of the linked example and TL2023 somewhat up-to-date. Anyway, glad that \etockeeporiginaltableofcontents turned out to work for you!
    – user691586
    Commented Oct 23, 2023 at 9:41

You must log in to answer this question.

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