Theses, Books, Title pagesSmall capitals for Chapter titles, sections, subsection..

Classicthesis, Bachelor and Master thesis, PhD, Doctoral degree
Post Reply
janelle
Posts: 4
Joined: Sat Oct 29, 2016 1:12 am

Small capitals for Chapter titles, sections, subsection..

Post by janelle »

Hi everybody,

Here's my first question for the community, hope you can help.

Im using template master-doctoral-thesis for my msc thesis and im wondering how to change all titles (Chapters titles, Sections, Subsections, Bibliography, toc) to Small Capitals.

Any suggestions?

Thanks in advance!

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Small capitals for Chapter titles, sections, subsection..

Post by Johannes_B »

You can use package titlesec just like you would do with any other LaTeX-class.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
janelle
Posts: 4
Joined: Sat Oct 29, 2016 1:12 am

Re: Small capitals for Chapter titles, sections, subsection.

Post by janelle »

thx. im still a beginner and am not quite sure how or where to implement that
i tried by including the following in the "main.tex" file's preamble part

1.
usepackage(titlesec)
\titleformat{\section}{\textsc}
\titleformat{\chapter}{\textsc}
...

but i get this error:
! Paragraph ended before \ttl@format@ii was complete.

2. then i tried
\titleformat*{\section}{\textsc}

which results in:
! Package titlesec Error: Entered in horizontal mode.
See the titlesec package documentation for explanation.
Type H <return> for immediate help.

can you see what goes wrong here?
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Small capitals for Chapter titles, sections, subsection..

Post by Johannes_B »

Thinking about it more, you have two possibilities. Using package titlesec and define the headings by yourself entirely (destroys template defaults), or use package sectsty and just change the font. The design will be with changed to the sectsty defaults, so, default template design destroyed as well.

Code: Select all

\usepackage{titlesec}
\makeatletter
\titleformat{\chapter}[display]{\huge\bfseries\scshape}{\@chapapp~\thechapter}{1\baselineskip}{}
\titleformat{\section}{\large\bfseries\scshape}{\thesection}{1em}{}
\makeatother
Pay attention, titleformat has a few arguments than you tried to give.

Or use the following block to change the fonts.

Code: Select all

\let\chapterfont\relax
\usepackage{sectsty}
\allsectionsfont{\scshape}
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
janelle
Posts: 4
Joined: Sat Oct 29, 2016 1:12 am

Re: Small capitals for Chapter titles, sections, subsection.

Post by janelle »

that works!

minor detail
chapter and section names at the top of each page are still normal
would there be a fast method to change that font to smallcaps too?
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Small capitals for Chapter titles, sections, subsection..

Post by Johannes_B »

Code: Select all

\addtokomafont{pagehead}{\scshape}
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
janelle
Posts: 4
Joined: Sat Oct 29, 2016 1:12 am

Re: Small capitals for Chapter titles, sections, subsection.

Post by janelle »

i couldnt be more thankful
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Re: Small capitals for Chapter titles, sections, subsection.

Post by Johannes_B »

Glad to be helpful.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
Post Reply