5

My question is similar to this one this one.

I use classicthesis and have the problem that

a) when I don't redefine \thepart, I get

  • lower case (instead of uppercase) roman numerals in the TOC
  • uppercase roman numeral in the text (on the "title page" of the part)

b) when I use \AtBeginDocument{\renewcommand{\thepart}{\Roman{part}}} in the preamble, I get

  • upper case roman numerals in small caps (instead of spaced low small caps) in the TOC
  • uppercase roman numeral in the text

c) when I use \AtBeginDocument{\renewcommand{\thepart}{\spacedlowsmallcaps{\Roman{part}}}}in the preamble, I get

  • upper case roman numerals in the TOC
  • uppercase roman numeral in low small caps (instead of standard font/capitalization) in the text

What I want, is a combination of both:

  • upper case roman numerals in spaced low small caps in the TOC
  • uppercase roman numerals in standard font/capitalization in the text

EDIT:

sorry, here is a MWE

\documentclass[12pt,
               a4paper,
               footinclude=true,
               headinclude=true,
               titlepages
               %draft
               ]{scrbook}

\usepackage[linedheaders,
            eulermath,
            eulerchapternumbers,
            parts,
            floatperchapter]{classicthesis} 

% a) without a redefinition of \thepart
% --

% b) redefinition with uppercase roman number
% \AtBeginDocument{\renewcommand{\thepart}{\Roman{part}}}

% c) redefinition with spaced low small caps
% \AtBeginDocument{\renewcommand{\thepart}{\spacedlowsmallcaps{\Roman{part}}}}

\begin{document}
% ******************************************************************************
\tableofcontents

\cleardoublepage\part{Introduction and Background}
\cleardoublepage\part{Empirical Studies}
\cleardoublepage\part{Conclusion}
\cleardoublepage\part{Appendix}
% ******************************************************************************
\end{document}
  • Can you please add a minimal example of code? – egreg Oct 21 '13 at 14:10
4

Is this what you want?

\documentclass[12pt,
               a4paper,
               footinclude=true,
               headinclude=true,
               titlepage,
               %draft
               ]{scrbook}

\usepackage[linedheaders,
            eulermath,
            eulerchapternumbers,
            parts,
            floatperchapter]{classicthesis}

%%% Magic code; don't ask ;-)
\makeatletter
\def\ttl@tocpart{%
  \def\ttl@a{\protect\numberline{\thepart}\@gobble{}}}
\makeatother

\begin{document}

\tableofcontents

\part{Introduction and Background}
\part{Empirical Studies}
\part{Conclusion}
\part{Appendix}

\end{document}

Table of contents

enter image description here

Part page

enter image description here

Here is a more thorough revision; you have two choices: with the code as is there will be a simple space between the part number and the title; in the code you find how to align part titles to chapter titles instead.

\documentclass[12pt,
               a4paper,
               footinclude=true,
               headinclude=true,
               titlepage,
               %draft
               ]{scrbook}

\usepackage[linedheaders,
            eulermath,
            eulerchapternumbers,
            parts,
            floatperchapter]{classicthesis} 

% make the part links in the TOC point to the right page
\usepackage{etoolbox}
\pretocmd{\oldpart}{\cleardoublepage}{}{}

\makeatletter
\def\ttl@tocpart{% %magic code, don't ask
  \def\ttl@a{\protect\numberline{\thepart}\@gobble{}}}

%% If you want part titles aligned with chapter titles
%% uncomment the following line and remove the code
%% up to (and excluding) \makeatother
% \setlength{\cftpartnumwidth}{\cftchapnumwidth}

\let\classic@l@part\l@part
\renewcommand\l@part[2]{%
  \begingroup
  \renewcommand{\numberline}[1]{\textsc{##1} }%
  \classic@l@part{#1}{#2}%
  \endgroup
}
\makeatother

\begin{document}

\tableofcontents

\part{Introduction and Background}
\chapter{Pippo}
\part{Empirical Studies}
\part{Conclusion}
\part{Appendix}

\end{document}
  • regarding the roman number, yes, thank you, but you introduced a fixed width between the roman numeral and the name of the part that is larger than it is for the chapters/sections. I would like to have either the same fixed space between numeral and text as for the chapters/sections (preferred) or classicthesis' standard behavior, i.e., just a space after the numeral – user21932 Oct 22 '13 at 10:04
  • @user21932 You can act on the space reserved for part numbers with \setlength{\cftpartnumwidht}{...} The initial value is approximately 2em in the text font. The magic code tells titlesec to write the TOC entry pertaining to parts in a way that's understandable by tocloft. If you want chapter and part titles aligned, issue \setlength{\cftpartnumwidth}{\cftchapnumwidth} – egreg Oct 22 '13 at 10:36
  • @user21932 I modified the code, you now may choose between two possibilities. I also added a trick for making the part titles into links to the right page. – egreg Oct 22 '13 at 10:58
  • Works great, thank you very much!! (linking to the right pages worked without your code, too, in my case...) – user21932 Oct 22 '13 at 14:18
  • @egreg Is this an incompatibility between titlesec and tocloft? It appear that as soon as one specifies \titleformat{\part}..., the command \cftpartpresnum from tocloft loses all functionality (hence ignoring \renewcommand{\cftpartpresnum}{\scshape} from classicthesis). – Jörg May 14 '14 at 10:03
0

I also had this problem. I resolved it using egreg's answer, but I still had problems with cleveref references to parts (the numerals were still lowercase). I resolved this second problem adding this line in the header:

\crefformat{part}{Part #2\MakeUppercase{#1}#3}

or if you don't want the capitalized P:

\crefformat{part}{part #2\MakeUppercase{#1}#3}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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