Your manual settings of \paperwidth
and \paperheight
do not change the size of the text area or the margins. The text area is just outside the specified paper size. You would see this, if you would add some text, e.g. \emph{Text}
instead of \emph{}
, because you won't see the text. geometry
on the other hand tries to also set the text area. But because the paper height is too low, the height of text area is also too low (less than \baselineskip
+ \topskip
) and also the margins + the height of the text area > \paperheight
. This results in underfull and overfull \vboxes and also in several page breaks. Even for an empty document the too low \textheight
results in two pages:
\documentclass{book}
\usepackage[paperwidth=5.625in,paperheight=0.125in]{geometry}
%\paperwidth=5.625in \paperheight=0.125in
\usepackage{xcolor}
\pagecolor{red}
\pagestyle{empty}
\begin{document}
\end{document}
You can compare the values also from within the information geometry
writes to the log
:
\documentclass{book}
\usepackage[pass]{geometry}% don't change anything
%\usepackage[paperwidth=5.625in,paperheight=0.125in,nohead,nofoot,margin=0pt]{geometry}
\paperwidth=5.625in \paperheight=0.125in
\usepackage{xcolor}
\pagecolor{red}
\pagestyle{empty}
\begin{document}
\end{document}
results in
* \paperwidth=406.51874pt
* \paperheight=9.03374pt
* \textwidth=345.0pt
* \textheight=550.0pt
* \oddsidemargin=35.0pt
* \evensidemargin=89.0pt
* \topmargin=22.0pt
* \headheight=12.0pt
* \headsep=18.06749pt
* \topskip=10.0pt
* \footskip=25.29494pt
* \marginparwidth=125.0pt
* \marginparsep=7.0pt
* \columnsep=10.0pt
* \skip\footins=9.0pt plus 4.0pt minus 2.0pt
* \hoffset=0.0pt
* \voffset=0.0pt
* \mag=1000
* \@twocolumnfalse
* \@twosidetrue
* \@mparswitchtrue
* \@reversemarginfalse
* (1in=72.27pt=25.4mm, 1cm=28.453pt)
but
\documentclass{book}
\usepackage[paperwidth=5.625in,paperheight=0.125in]{geometry}
%\paperwidth=5.625in \paperheight=0.125in
\usepackage{xcolor}
\pagecolor{red}
\pagestyle{empty}
\begin{document}
\end{document}
results in
* layout: <same size as paper>
* layoutoffset:(h,v)=(0.0pt,0.0pt)
* modes: twoside
* h-part:(L,W,R)=(48.78275pt, 284.56187pt, 73.17412pt)
* v-part:(T,H,B)=(1.08405pt, 6.32358pt, 1.62611pt)
* \paperwidth=406.51874pt
* \paperheight=9.03374pt
* \textwidth=284.56187pt
* \textheight=6.32358pt
* \oddsidemargin=-23.48724pt
* \evensidemargin=0.90413pt
* \topmargin=-101.25343pt
* \headheight=12.0pt
* \headsep=18.06749pt
* \topskip=10.0pt
* \footskip=25.29494pt
* \marginparwidth=125.0pt
* \marginparsep=7.0pt
* \columnsep=10.0pt
* \skip\footins=9.0pt plus 4.0pt minus 2.0pt
* \hoffset=0.0pt
* \voffset=0.0pt
* \mag=1000
* \@twocolumnfalse
* \@twosidetrue
* \@mparswitchtrue
* \@reversemarginfalse
* (1in=72.27pt=25.4mm, 1cm=28.453pt)
book
nor any of the used packages provide optionborder
.border=
reserved only for thestandalone
class?border=0pt
, the phenomenon still occurred.standalone
provides but the standard classes don't. If you'd have a look into the log file you would find a warning about the unused global option, when usngbook
. And yes, removing the option changes nothing. That's the reason for using Off-topic at the start of my comment. BTW: To change the margins usinggeometry
see optionsmargin
,top
,left
, etc.