6

How can I get the chapter higher on the page in order to get as many words as possible per page. Here is my MWE of what I am talking about.

\documentclass[12pt]{book}
\usepackage[pass,showframe]{geometry}
\begin{document}
\chapter{example}
How do I get chapter to go higher on the page. In order to get as many words per page. 
\end{document}

enter image description here

I also would like to have chapter number and chapter title in one line.

3
  • Your title and body is contradicting... regardless, why do you use a \chapter then? Why not use something like a \section?
    – Werner
    May 16 '16 at 17:12
  • I added a figure of your MWE, but also put on a showframe to show the text margins. May 16 '16 at 17:15
  • I would use section but I was asked to keep everything in chapter form. Is there a way that I can get it to say Chapter 1 for example at the top of the page instead of the middle? If you could please help I would really appreciate it.
    – rabin
    May 16 '16 at 17:21
4

The vertical skip between text page top margin and the chapter title is controlled by \vspace*{50\p@} in \@makechapterhead. (\p@ is an internal representation for pt)

Either redefine this command completely or use a \xpatchcmd replacing \vspace*{50\p@} with some other length, that's easier to change, in a special length register, say \chaptertopskip.

\documentclass[12pt]{book}
\usepackage[pass,showframe]{geometry}
\usepackage{xpatch}
\newlength{\chaptertopskip}
\setlength{\chaptertopskip}{10pt}
\makeatletter
\xpatchcmd{\@makechapterhead}{\vspace*{50\p@}}{\vspace*{\chaptertopskip}}{\typeout{Success}}{\typeout{Failure!!!}}
\makeatother
\begin{document}
\chapter{example}
How do I get chapter to go higher on the page. In order to get as many words per page. 
\end{document}

enter image description here

Update

Changing the wrap and bottom skip as well:

\documentclass[12pt]{book}
\usepackage[pass,showframe]{geometry}
\usepackage{xpatch}
\newlength{\chaptertopskip}
\newlength{\chapterbottomskip}
\setlength{\chaptertopskip}{10pt}
\setlength{\chapterbottomskip}{10pt}
\makeatletter
\def\@makechapterhead#1{%
  \vspace*{\chaptertopskip}%
  {\parindent \z@ \raggedright \normalfont
    \ifnum \c@secnumdepth >\m@ne
      \if@mainmatter
        \huge\bfseries \@chapapp\space \thechapter\ 
%        \par\nobreak
%        \vskip 20\p@
      \fi
    \fi
    \interlinepenalty\@M
    \Huge \bfseries #1\par\nobreak
    \vskip \chapterbottomskip
  }}
\makeatother
\begin{document}
\chapter{example}
How do I get chapter to go higher on the page. In order to get as many words per page. 
\end{document}

enter image description here

6
  • I like the placement of where it says chapter. But is there a way to just make it say the chapter number and the chapter title on the same line?
    – rabin
    May 16 '16 at 17:22
  • 1
    @rabin: That's another question -- you asked for the movement of the chapter header.
    – user31729
    May 16 '16 at 17:26
  • @rabin: See the update at the bottom
    – user31729
    May 16 '16 at 17:31
  • Thank You very much. You have no idea how much I appreciate it.
    – rabin
    May 16 '16 at 17:43
  • @rabin: If it's what you requested, please consider to accept it later on
    – user31729
    May 16 '16 at 17:44
4

The default \chapter command issues three different spaces to set the chapter heading:

  1. Space from the top of the text block to the word Chapter; default is 50pt.

  2. Space between Chapter and the chapter title; default is 20pt.

  3. Space between the chapter title and the chapter body text; default is 40pt.

All of this is made by the macro \@makechapterhead (from book.cls; emphasis added):

\def\@makechapterhead#1{%
  \vspace*{50\p@}% <------------------------------------ (1)
  {\parindent \z@ \raggedright \normalfont
    \ifnum \c@secnumdepth >\m@ne
      \if@mainmatter
        \huge\bfseries \@chapapp\space \thechapter
        \par\nobreak
        \vskip 20\p@% <--------------------------------- (2)
      \fi
    \fi
    \interlinepenalty\@M
    \Huge \bfseries #1\par\nobreak
    \vskip 40\p@% <------------------------------------- (3)
  }}

For unnumbered chapters, there are still two spaces (1) and (3) above given as part of \@makeschapterhead:

\def\@makeschapterhead#1{%
  \vspace*{50\p@}% <------------------------------------ (1)
  {\parindent \z@ \raggedright
    \normalfont
    \interlinepenalty\@M
    \Huge \bfseries  #1\par\nobreak
    \vskip 40\p@% <------------------------------------- (3)
  }}

You can either get rid of these using an etoolbox patch, but it may be better to just write your own \@makechapterhead macro:

enter image description here

\documentclass{book}

\makeatletter
\renewcommand{\@makechapterhead}[1]{%
  {\noindent\raggedright\normalfont% Alignment and font reset
   \huge\bfseries \@chapapp\space\thechapter~~#1\par\nobreak}% Formatting
  \vspace{\baselineskip}% ...just a little space
}
\makeatother

\usepackage{showframe}% Just to show the frame

\begin{document}

\chapter{Example}
How do I get chapter to go higher on the page. In order to get as many words per page. 

\end{document}

You can do something similar for \@makeschapterhead.

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.