Theses, Books, Title pagesMoving section titles closer to the top of the page

Classicthesis, Bachelor and Master thesis, PhD, Doctoral degree
Post Reply
templateuser
Posts: 679
Joined: Tue Mar 03, 2015 4:01 pm

Moving section titles closer to the top of the page

Post by templateuser »

Hi Vel,
I wonder how to adjust the title of sections (Contents, List of tables, Chapter1…) to move them up closer to the top of the page. I looked around thesis.cls file but can not find the clue. Thank you so much

All the best
Nghia

Recommended reading 2024:

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

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

templateuser
Posts: 679
Joined: Tue Mar 03, 2015 4:01 pm

Moving section titles closer to the top of the page

Post by templateuser »

Hi. I have the same question and already tried several options and none of them worked. One of them I present next and was suggested in this forum but I don't understand what is blocking it from working.

Code: Select all

\usepackage[compact]{titlesec}
\titlespacing{\chapter}{0pt}{0pt}{0pt}
waiting for a clue, cheers
RM
User avatar
Vel
Site Moderator
Posts: 463
Joined: Fri Jun 29, 2012 1:20 am

Moving section titles closer to the top of the page

Post by Vel »

Hi,

Just add this in the preamble of main.tex:

Code: Select all

\usepackage{etoolbox}
\makeatletter
\patchcmd{\@makechapterhead}{\vspace*{50\p@}}{}{}{}% Removes space above \chapter head
\patchcmd{\@makeschapterhead}{\vspace*{50\p@}}{}{}{}% Removes space above \chapter* head
\makeatother
Adjust the \vspace numbers as you see fit!

Cheers,
Vel
Founder and administrator of LaTeXTemplates.com and LaTeXTypesetting.com
ClaudiaS
Posts: 1
Joined: Mon Jun 08, 2015 2:02 pm

Re: Moving section titles closer to the top of the page

Post by ClaudiaS »

Hey Vel,

thanks for the code, it works fine for me when I add only this code. But as soon as I add the code of another thread to remove the first chapter name, the space is too large again. Maybe because the removing space code refers to the chapter heading that is removed now?! How can I fix it ?

The other code is this one:

\usepackage{titlesec}
\titleformat{\chapter}{}{}{0em}{\bf\LARGE}
greennell
Posts: 10
Joined: Tue Jan 20, 2015 1:57 pm

Re: Moving section titles closer to the top of the page

Post by greennell »

Hi Vel,

How can I use etoolbox only for particular chapters? I would like to apply it only for appendix.

Thank you,
Nell
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Moving section titles closer to the top of the page

Post by Johannes_B »

Put the block beginning and ending with \makeat just before \appendix.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Moving section titles closer to the top of the page

Post by Johannes_B »

With a current version of the template, you can simple do the following:

Code: Select all

\renewcommand{\abovechapterskip}{\vspace*{10pt}}
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