1

Suppose we were using small caps (rather than, e.g., bold face) to format a sectioning level in our TOC, say, section.

Consequently, we would use the appropriate alternative spelling of the section titles, to make sure the TOC entries will appear in small-caps only (rather mixed with upper-case letters, which looks clumsy) -- as, so far, there's no such thing as an upper- or lower-case command that can be used functionally identically to (and in combination with) the text style commands we already have (there's no \lcshape\scshape).

\section[lorem ipsum]{Lorem Ipsum}

But how to proceed with things like the names of \listoffigures and the likes? What would be the most elegant way to patch them before they get written to the TOC file?

\documentclass[listof=totoc]{scrartcl}
\usepackage{tocstyle,blindtext}

\settocfeature[toc][1]{entryhook}{\normalfont\scshape}

\setkomafont{section}{\normalfont\itshape}

\begin{document}
\tableofcontents

\section[lorem ipsum]{Lorem Ipsum}
\blindtext

\begin{figure}
  \dots
  \caption{\dots}\label{fig1}
\end{figure}

\blindtext

\listoffigures

\end{document} 

enter image description here

2

With \MakeLowercase you could automatically make your sections titles for the toc lowercase without manually specifying a short title.

\documentclass[listof=totoc]{scrartcl}
\usepackage{tocstyle,blindtext}

\settocfeature[toc][1]{entryhook}{\normalsize\scshape\MakeLowercase}

\setkomafont{section}{\normalfont\large\itshape}

\begin{document}
\tableofcontents

\section{Lorem Ipsum}
\blindtext

\begin{figure}
  \dots
  \caption{\dots}\label{fig1}
\end{figure}

\blindtext

\listoffigures

\end{document} 

enter image description here

Thanks to @DavidCarlisle for pointing out the advantages of \MakeLowercase compared to \lowercase!

  • 1
    @DavidCarlisle Do you want to post a \MakeLowercase answer? I'll happily delete my answer. – user36296 Jul 5 '18 at 20:21
  • 1
    @samcarter no, but you could edit yours:-) – David Carlisle Jul 5 '18 at 20:26
  • 1
    @NilsL why tricky? You can just replace \lowercase by \MakeLowercase in the above answer. – David Carlisle Jul 5 '18 at 20:27
  • 1
    @DavidCarlisle Edited - Thanks for your comments! – user36296 Jul 5 '18 at 20:34
  • 1
    +1 for the excellent suggestion to use \MakeLowercase :-) – David Carlisle Jul 5 '18 at 20:36

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.