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 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204
|
% ======================================================================
% common-0.tex
% Copyright (c) Markus Kohm, 2001-2013
%
% 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-0.tex
% Copyright (c) Markus Kohm, 2001-2013
%
% 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.
% ======================================================================
%
% Paragraphs that are common for several chapters of the KOMA-Script guide
% Maintained by Markus Kohm
%
% ----------------------------------------------------------------------
%
% Abstze, die mehreren Kapiteln der KOMA-Script-Anleitung gemeinsam sind
% Verwaltet von Markus Kohm
%
% ======================================================================
\KOMAProvidesFile{common-0.tex}
[$Date: 2013-12-13 12:11:01 +0100 (Fr, 13. Dez 2013) $
KOMA-Script guide (common paragraphs)]
\translator{Gernot Hassenpflug\and Krickette Murabayashi}
% Date of the translated German file: 2013/08/08
\makeatletter
\@ifundefined{ifCommonmaincls}{\newif\ifCommonmaincls}{}%
\@ifundefined{ifCommonscrextend}{\newif\ifCommonscrextend}{}%
\@ifundefined{ifCommonscrlttr}{\newif\ifCommonscrlttr}{}%
\@ifundefined{ifIgnoreThis}{\newif\ifIgnoreThis}{}%
\makeatother
\section{Early or late Selection of Options}
\label{sec:\csname label@base\endcsname.options}
\ifshortversion\IgnoreThisfalse\IfNotCommon{typearea}{\IgnoreThistrue}\fi
\ifIgnoreThis
All of what is described in \autoref{sec:typearea.options} is generally applicable.
\else
\BeginIndex{}{options}%
In this section a peculiarity of {\KOMAScript} is presented, which,
apart from %
\IfCommon{typearea}{the \Package{typearea} package, is also relevant to other {\KOMAScript} packages and classes}%
\IfCommon{maincls}{the classes \Class{scrbook}, \Class{scrreprt}, and
\Class{scrartcl} is also relevant to other {\KOMAScript} classes and packages}%
\IfCommon{scrlttr2}{the class \Class{scrlttr2} is also relevant to other
{\KOMAScript} classes and packages}%
\IfCommon{scrextend}{the classes and the \Package{scrextend} package is also relevant to several other
{\KOMAScript} packages}%
. Such that the user can find all information corresponding to a
single package or a single class in the relevant chapter, this section
is found almost identically in several chapters. Users who are not
only interested in a particular package or class, but wish to gain an
overview of {\KOMAScript} as a whole, may read the section in one
chapter and may thereafter skip it wherever coming across it in the
document.
\begin{Declaration}
\Macro{documentclass}\OParameter{option list}%
\Parameter{{\KOMAScript} class}\\
\Macro{usepackage}\OParameter{option list}%
\Parameter{package list}
\end{Declaration}
\BeginIndex{Cmd}{documentclass}%
\BeginIndex{Cmd}{usepackage}%
In \LaTeX{}, provision is made for the user to pass class options as a
comma-separated list of keywords as optional arguments to
\Macro{documentclass}.
Apart from being passed to the class,
these options are also passed on to all packages which can understand
the options. Provision is also made for the user to pass optional
arguments as a comma-separated list of keywords as optional arguments
to \Macro{usepackage}. {\KOMAScript}
expands\ChangedAt{v3.00}{\Class{scrbook}\and \Class{scrreprt}\and
\Class{scrartcl}\and \Package{scrextend}\and \Package{typearea}} the
option mechanism for the {\KOMAScript} classes and various packages to
use further possibilities. Thus, most {\KOMAScript} options can also
take a value. An option may have not only the form \PName{Option}, but
may also have the form \PName{option}\texttt{=}\PName{value}. Apart
from this difference \Macro{documentclass} and \Macro{usepackage}
function the same in {\KOMAScript} as described in
\cite{latex:usrguide} or any introduction to \LaTeX, for example
\cite{lshort}.%
%
\IfNotCommon{scrextend}{\par%
When using a {\KOMAScript} class, no options should be passed on
% Die Alternativen an dieser Stelle dienen der Verbesserung des Umbruchs
\IfCommon{typearea}{unnecessary, explicit }%
loading of the \Package{typearea} or \Package{scrbase} packages. The
reason for this is that the class already loads these packages
without options and \LaTeX{} refuses multiple loadings of a package
with different option settings.%
\IfCommon{maincls}{\ Actually, it is no longer necessary when using
any {\KOMAScript} class to explicity load either one of these
packages.}%
\IfCommon{scrlttr2}{\ Actually, it is no longer necessary when using
any {\KOMAScript} class to explicity load either one of these
packages.}}
You should note\textnote{Attention!}, that in opposite to the interface
described below the options interface of \Macro{documentclass} and
\Macro{usepackage} is not robust. So commands, lengths, counters and such
constructs may break inside the optional argument of these commands. Because
of this, the usage of a \LaTeX{} length inside the value of an option would
cause an error before \KOMAScript{} can get the control over the option
execution. So, if you want to use a \LaTeX{} length, counter or command a part
of the value of an option, you have to use \Macro{KOMAoptions} or
\Macro{KOMAoption}. These commands will be described next.%
%
\EndIndex{Cmd}{usepackage}%
\EndIndex{Cmd}{documentclass}%
\BeginIndex{Cmd}{KOMAoptions}%
\BeginIndex{Cmd}{KOMAoption}%
\begin{Declaration}
\Macro{KOMAoptions}\Parameter{option list}\\
\Macro{KOMAoption}\Parameter{option}\Parameter{value list}
\end{Declaration}
\KOMAScript{}\ChangedAt{v3.00}{\Class{scrbook}\and
\Class{scrreprt}\and \Class{scrartcl}\and \Package{scrextend}\and
\Package{typearea}} offers most class and package options the
opportunity to change the value of options even after loading of the
class or package. One may then change the values of a list of options
at will with the \Macro{KOMAoptions} command. Each option in the
\PName{option list} has the form
\PName{option}\texttt{=}\PName{value}.
Some options also have a default value. If one does not give a value,
i.\,e., gives the option simply in the form \PName{option}, then the
default value will be used.
Some options can %
\IfCommon{maincls}{also }% Umbruchkorrektur
\IfCommon{scrlttr2}{also }% Umbruchkorrektur
assume several values simultaneously. For such options there exists
the possibility, with the help of \Macro{KOMAoption}, to pass a single
\PName{option} a list of values. The individual values are given as a
comma-separated \PName{value list}.
\begin{Explain}
If in the \PName{option list} one sets an option to a disallowed
value, or the \PName{value list} contains an invalid value, then an
error is produced. If \LaTeX{} is run in an interactive mode, then
it stops at this point. Entering ``\texttt{h}'' displays a help
screen, in which also the valid values for the corresponding option
are given.
If a \PName{value} includes an equal sign or a comma, then the
\PName{value} must be enclosed in curly brackets.
To implement this possibility {\KOMAScript} uses the commands
\Macro{FamilyOptions} and \Macro{FamilyOption} with the family
``\PValue{KOMA}''. More information on these commands %
\IfCommon{maincls}{for experts }%
\IfCommon{scrlttr2}{for experts }%
is found in \autoref{sec:scrbase.keyvalue},
\autopageref{desc:scrbase.cmd.FamilyOptions}.
\end{Explain}
%
\EndIndex{Cmd}{KOMAoption}%
\EndIndex{Cmd}{KOMAoptions}%
%
\EndIndex{}{options}%
\fi % IgnoreThis
%%% Local Variables:
%%% mode: latex
%%% coding: iso-latin-1
%%% TeX-master: "../guide"
%%% End:
|