summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/koma-script/source-doc/english/common-headfootheight.tex
blob: 2e39697578be9354723db6a9dfbab423826feb60 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
% ======================================================================
% common-headfootheight.tex
% Copyright (c) Markus Kohm, 2013-2019
%
% This file is part of the LaTeX2e KOMA-Script bundle.
%
% This work may be distributed and/or modified under the conditions of
% the LaTeX Project Public License, version 1.3c of the license.
% The latest version of this license is in
%   http://www.latex-project.org/lppl.txt
% and version 1.3c or later is part of all distributions of LaTeX 
% version 2005/12/01 or later and of this work.
%
% This work has the LPPL maintenance status "author-maintained".
%
% The Current Maintainer and author of this work is Markus Kohm.
%
% This work consists of all files listed in manifest.txt.
% ----------------------------------------------------------------------
% common-headfootheight.tex
% Copyright (c) Markus Kohm, 2013-2019
%
% Dieses Werk darf nach den Bedingungen der LaTeX Project Public Lizenz,
% Version 1.3c, verteilt und/oder veraendert werden.
% Die neuste Version dieser Lizenz ist
%   http://www.latex-project.org/lppl.txt
% und Version 1.3c ist Teil aller Verteilungen von LaTeX
% Version 2005/12/01 oder spaeter und dieses Werks.
%
% Dieses Werk hat den LPPL-Verwaltungs-Status "author-maintained"
% (allein durch den Autor verwaltet).
%
% Der Aktuelle Verwalter und Autor dieses Werkes ist Markus Kohm.
% 
% Dieses Werk besteht aus den in manifest.txt aufgefuehrten Dateien.
% ======================================================================
%
% Text that is common for several chapters of the KOMA-Script guide
% Maintained by Markus Kohm
%
% ----------------------------------------------------------------------
%
% Absaetze, die mehreren Kapitels in der KOMA-Script-Anleitung gemeinsam sind
% Verwaltet von Markus Kohm
%
% ============================================================================

\KOMAProvidesFile{common-headfootheight.tex}
                 [$Date: 2019-10-10 10:04:30 +0200 (Thu, 10 Oct 2019) $
                  KOMA-Script guide (common paragraph: Head and Foot Height)]
\translator{Markus Kohm\and Jana Schubert\and Jens H\"uhne\and Karl Hagen}

% Date of the translated German file: 2019-10-10

\section{Header and Footer Height}
\seclabel{height}
\BeginIndexGroup
\BeginIndex{}{header>height}%
\BeginIndex{}{footer>height}%
\IfThisCommonLabelBase{scrlayer-scrpage}{%
  \begin{Explain}%
    The \LaTeX{} standard classes do not use the footer much, and if they do
    use it, they put the contents into a \Macro{mbox} which results in the
    footer being a single text line. This is probably the reason that \LaTeX{}
    itself does not have a well-defined footer height. Although the distance
    between the last baseline of the text area and the baseline of the footer
    is defined with \Length{footskip}\IndexLength[indexmain]{footskip}, if the
    footer consists of more than one text line, there is no definite statement
    whether this length should be the distance to the first or the last
    baseline of the footer.

    Although the page header of the standard classes will also be put into a
    horizontal box, and therefore is also a single text line, \LaTeX{} in fact
    provides a length to set the height of the header. The reason for this may
    be that this height is needed to determine the start of the text area.
  \end{Explain}%
}{%
  The header and footer of a page are central elements not just of a page
  style. They can also serve to restrict layers using the appropriate options
  (see \autoref{tab:scrlayer.layerkeys},
  \autopageref{tab:scrlayer.layerkeys}). Therefore the heights of these
  elements must be defined.%
}

\IfThisCommonFirstRun{}{%
  The information in \autoref{sec:\ThisCommonFirstLabelBase.height} applies
  equally to this chapter. So if you have already read and understood
  \autoref{sec:\ThisCommonFirstLabelBase.height}, you can skip ahead to 
  \autoref{sec:\ThisCommonLabelBase.height.next},
  \autopageref{sec:\ThisCommonLabelBase.height.next}.%
}

\begin{Declaration}
  \Length{footheight}
  \Length{headheight}
  \IfThisCommonLabelBase{scrlayer-scrpage}{%
    \OptionVName{autoenlargeheadfoot}{simple switch}%
  }{}%
\end{Declaration}
The \Package{scrlayer} package introduces a new length, \Length{footheight},
analogous to \Length{headheight}%
\IfThisCommonLabelBase{scrlayer-scrpage}{}{of the \LaTeX{} kernel}.
Additionally,
\Package{scrlayer\IfThisCommonLabelBase{scrlayer-scrpage}{-scrpage}{}}
interprets \Length{footskip} to be the distance from the last baseline of the
text area to the first normal baseline of the footer. The
\hyperref[cha:typearea]{\Package{typearea}}\IndexPackage{typearea}%
\important{\hyperref[cha:typearea]{\Package{typearea}}} package interprets
\Length{footheight} in the same way, so \Package{typearea}'s options for the
footer height can also be used to set the values for the \Package{scrlayer}
package. See the \DescRef{typearea.option.footheight} and 
\DescRef{typearea.option.footlines} options in
\autoref{sec:typearea.typearea}, \DescPageRef{typearea.option.footheight})
and option \DescRef{typearea.option.footinclude} on
\DescPageRef{typearea.option.footinclude} of the same section.

If you do not use the \hyperref[cha:typearea]{\Package{typearea}}%
\important{\hyperref[cha:typearea]{\Package{typearea}}} package, you should
adjust the header and footer heights using appropriate values for the lengths
where necessary. For the header, at least, the \Package{geometry} package, for
example, provides similar settings.
\IfThisCommonLabelBase{scrlayer-scrpage}{\par%
  If you choose a header or footer height that is too small for the actual
  content, \Package{scrlayer-scrpage} tries by default to adjust the lengths
  appropriately. At the same time, it will issue a warning containing
  suggestions for suitable settings. These automatic changes take effect
  immediately after the need for them has been detected and are not
  automatically reversed, for example, when the content of the header or
  footer becomes smaller afterwards.
  However,\ChangedAt{v3.25}{\Package{scrlayer-scrpage}}, this behaviour can be
  changed by using the \Option{autoenlargeheadfoot} option. This option
  recognizes the values for simple switches in \autoref{tab:truefalseswitch},
  \autopageref{tab:truefalseswitch}. The option is activated by default. If it
  is deactivated, the header and footer are no longer enlarged
  automatically. Only a warning with hints for suitable settings is issued.%
}{%
  \IfThisCommonLabelBase{scrlayer}{\par%
    If you choose a header or footer height that is too small for the actual
    content, \Package{scrlayer} usually accepts this without issuing an error
    message or a warning. The header then expands according to its height,
    usually upwards, with the footer moved down accordingly. Information about
    this change is not obtained automatically. However, packages like
    \hyperref[cha:scrlayer-scrpage]{\Package{scrlayer-scrpage}}%
    \important{\hyperref[cha:scrlayer-scrpage]{\Package{scrlayer-scrpage}}}%
    \IndexPackage{scrlayer-scrpage} that build upon \Package{scrlayer} may
    contain their own tests which can lead to their own actions (see
    \DescRef{scrlayer-scrpage.length.headheight} and
    \DescRef{scrlayer-scrpage.length.footheight} on
    \DescPageRef{scrlayer-scrpage.length.headheight}).%
  }{}%
}%
\EndIndexGroup
%
\EndIndexGroup

%%% Local Variables:
%%% mode: latex
%%% mode: flyspell
%%% coding: us-ascii
%%% ispell-local-dictionary: "en_GB"
%%% TeX-master: "../guide.tex"
%%% TeX-PDF-mode: t
%%% End: