| 1 |
% \iffalse meta-comment |
| 2 |
% ====================================================================== |
| 3 |
% scrkernel-title.dtx |
| 4 |
% Copyright (c) Markus Kohm, 2002-2023 |
| 5 |
% |
| 6 |
% This file is part of the LaTeX2e KOMA-Script bundle. |
| 7 |
% |
| 8 |
% This work may be distributed and/or modified under the conditions of |
| 9 |
% the LaTeX Project Public License, version 1.3c of the license. |
| 10 |
% The latest version of this license is in |
| 11 |
% http://www.latex-project.org/lppl.txt |
| 12 |
% and version 1.3c or later is part of all distributions of LaTeX |
| 13 |
% version 2005/12/01 or later and of this work. |
| 14 |
% |
| 15 |
% This work has the LPPL maintenance status "author-maintained". |
| 16 |
% |
| 17 |
% The Current Maintainer and author of this work is Markus Kohm. |
| 18 |
% |
| 19 |
% This work consists of all files listed in MANIFEST.md. |
| 20 |
% ====================================================================== |
| 21 |
%%% From File: $Id: scrkernel-title.dtx 4032 2023-04-17 09:45:11Z kohm $ |
| 22 |
%<option>%%% (run: option) |
| 23 |
%<body>%%% (run: body) |
| 24 |
%<*dtx> |
| 25 |
\ifx\ProvidesFile\undefined\def\ProvidesFile#1[#2]{}\fi |
| 26 |
\begingroup |
| 27 |
\def\filedate$#1: #2-#3-#4 #5${\gdef\filedate{#2/#3/#4}} |
| 28 |
\filedate$Date: 2023-04-17 11:45:11 +0200 (Mo, 17. Apr 2023) $ |
| 29 |
\def\filerevision$#1: #2 ${\gdef\filerevision{r#2}} |
| 30 |
\filerevision$Revision: 4032 $ |
| 31 |
\edef\reserved@a{% |
| 32 |
\noexpand\endgroup |
| 33 |
\noexpand\ProvidesFile{scrkernel-title.dtx}% |
| 34 |
[\filedate\space\filerevision\space |
| 35 |
KOMA-Script source (title pages)] |
| 36 |
}% |
| 37 |
\reserved@a |
| 38 |
\documentclass[USenglish]{koma-script-source-doc} |
| 39 |
\usepackage{babel} |
| 40 |
\setcounter{StandardModuleDepth}{3} |
| 41 |
\begin{document} |
| 42 |
\DocInput{scrkernel-title.dtx} |
| 43 |
\end{document} |
| 44 |
%</dtx> |
| 45 |
% \fi |
| 46 |
% |
| 47 |
% \changes{v2.95}{2002/06/26}{first version after splitting \file{scrclass.dtx}} |
| 48 |
% \changes{v3.36}{2022/03/08}{switch over from \cls*{scrdoc} to |
| 49 |
% \cls*{koma-script-source-doc}} |
| 50 |
% \changes{v3.36}{2022/03/08}{whole implementation documentation in English} |
| 51 |
% \changes{v3.40}{2023/04/17}{guide names changed} |
| 52 |
% |
| 53 |
% \GetFileInfo{scrkernel-title.dtx} |
| 54 |
% \title{The Code to Implement the Extended Titles of |
| 55 |
% \href{https://komascript.de}{\KOMAScript} Classes} |
| 56 |
% \author{\href{mailto:[email protected]}{Markus Kohm}} |
| 57 |
% \date{Revision \fileversion{} of \filedate} |
| 58 |
% \maketitle |
| 59 |
% \begin{abstract} |
| 60 |
% \file{scrkernel-title.dtx} implements on-page titles and title pages, that |
| 61 |
% are extended a lot comparing with the titles of the standard classes. |
| 62 |
% \end{abstract} |
| 63 |
% \tableofcontents |
| 64 |
% |
| 65 |
% \section{User Manual} |
| 66 |
% |
| 67 |
% You can find the user documentation the commands implemented here in the |
| 68 |
% \KOMAScript{} manual, either the German \file{scrguide-de.pdf} or the |
| 69 |
% English \file{scrguide-en.pdf}. |
| 70 |
% |
| 71 |
% \MaybeStop{\PrintIndex} |
| 72 |
% |
| 73 |
% |
| 74 |
% \section{Implementation of Titles} |
| 75 |
% |
| 76 |
% This kind of titles are not needed for letters. |
| 77 |
% |
| 78 |
% \begin{macrocode} |
| 79 |
%<*!letter> |
| 80 |
% \end{macrocode} |
| 81 |
% |
| 82 |
% \begin{option}{titlepage} |
| 83 |
% \changes{v2.95c}{2006/08/21}{using \pkg*{scrkbase}} |
| 84 |
% \changes{v3.12}{2013/11/21}{value \opt{\quotechar=firstiscover} added} |
| 85 |
% \changes{v3.17}{2015/03/10}{using internal value storage} |
| 86 |
% \changes{v3.28}{2019/11/18}{\cs{ifstr} renamed to \cs{Ifstr}} |
| 87 |
% \changes{v3.39}{2022/11/11}{initial dot removed from member argument of |
| 88 |
% option storage commands} |
| 89 |
% \begin{macro}{\@titlepagetrue,\@titlepagefalse,\if@titlepage} |
| 90 |
% \begin{macro}{\@titlepageiscoverpagetrue,\@titlepageisvoerpagefalse, |
| 91 |
% \if@titlepageiscoverpage} |
| 92 |
% \changes{v3.12}{2013/11/21}{added} |
| 93 |
% There is support for two kinds of titles: in-page titles also known as title |
| 94 |
% heads and title pages. Usually title pages are the title pages of the inner |
| 95 |
% book. But some users prefer to interpret them as cover instead. With |
| 96 |
% \KOMAScript{} this does in fact makes some sense, but only, if the user uses |
| 97 |
% the mock title and wants to interpret it not as mock title but as cover. So |
| 98 |
% we provide the following values: |
| 99 |
% \begin{description} |
| 100 |
% \item[\opt{=false}:] use a in-page title (\cs{@titlepagefalse}, |
| 101 |
% \cs{@titlepageiscoverpagefalse}), |
| 102 |
% \item[\opt{=true}:] use several title pages (\cs{@titlepagetrue}, |
| 103 |
% \cs{@titlepageiscoverpagefalse}), |
| 104 |
% \item[\opt{=firstiscover}:] use several title pages and the first one is the |
| 105 |
% cover (\cs{@titlepagetrue}, \cs{@titlepageiscoverpagetrue}). We do not |
| 106 |
% test, if this is was originally a mock title of a main title. |
| 107 |
% \end{description} |
| 108 |
% With package \pkg*{scrextend} this feature is defined as activatable. And |
| 109 |
% the initial values differ from class to class. |
| 110 |
% \begin{macrocode} |
| 111 |
%<*option> |
| 112 |
%<*class> |
| 113 |
\newif\if@titlepage |
| 114 |
%<article>\@titlepagefalse |
| 115 |
%<report|book>\@titlepagetrue |
| 116 |
%</class> |
| 117 |
%<*package&extend> |
| 118 |
\scr@ext@activateable{title}{% |
| 119 |
\scr@ifundefinedorrelax{if@titlepage}{% |
| 120 |
\expandafter\newif\csname if@titlepage\endcsname |
| 121 |
\@titlepagefalse |
| 122 |
}{}% |
| 123 |
\scr@ifundefinedorrelax{if@titlepageiscoverpage}{% |
| 124 |
\expandafter\newif\csname if@titlepageiscoverpage\endcsname |
| 125 |
\@titlepageiscoverpagefalse |
| 126 |
}{}% |
| 127 |
%</package&extend> |
| 128 |
%<*class|package> |
| 129 |
%<class>\newif\if@titlepageiscoverpage |
| 130 |
\KOMA@key{titlepage}[true]{% |
| 131 |
%<!(package&extend)> \Ifstr{#1}{firstiscover}{% |
| 132 |
%<package&extend> \Ifstr{##1}{firstiscover}{% |
| 133 |
\@titlepagetrue |
| 134 |
\@titlepageiscoverpagetrue |
| 135 |
\FamilyKeyStateProcessed |
| 136 |
\KOMA@kav@replacevalue{% |
| 137 |
%<class> \KOMAClassFileName |
| 138 |
%<package&extend> scrextend.\scr@pkgextension |
| 139 |
}{titlepage}{firstiscover}% |
| 140 |
}{% |
| 141 |
\def\FamilyElseValue{, `firstiscover'}% |
| 142 |
%<!(package&extend)> \KOMA@set@ifkey{titlepage}{@titlepage}{#1}% |
| 143 |
%<package&extend> \KOMA@set@ifkey{titlepage}{@titlepage}{##1}% |
| 144 |
\ifx\FamilyKeyState\FamilyKeyStateProcessed |
| 145 |
\KOMA@kav@remove{% |
| 146 |
%<class> \KOMAClassFileName |
| 147 |
%<package&extend> scrextend.\scr@pkgextension |
| 148 |
}{titlepage}{firstiscover}% |
| 149 |
\KOMA@kav@replacebool{% |
| 150 |
%<class> \KOMAClassFileName |
| 151 |
%<package&extend> scrextend.\scr@pkgextension |
| 152 |
}{titlepage}{@titlepage}% |
| 153 |
\@titlepageiscoverpagefalse |
| 154 |
\fi |
| 155 |
}% |
| 156 |
} |
| 157 |
\KOMA@kav@xadd{% |
| 158 |
%<class> \KOMAClassFileName |
| 159 |
%<package&extend> scrextend.\scr@pkgextension |
| 160 |
}{titlepage}{\if@titlepage true\else false\fi} |
| 161 |
%<*extend> |
| 162 |
% \end{macrocode} |
| 163 |
% For \pkg*{scrextend} we allow to activate the feature at load time. |
| 164 |
% \begin{macrocode} |
| 165 |
\def\scr@ext@immediate@title{% |
| 166 |
\scr@ext@activate{title}% |
| 167 |
\let\scr@ext@immediate@title\relax |
| 168 |
}% |
| 169 |
} |
| 170 |
%</extend> |
| 171 |
%</class|package> |
| 172 |
% \end{macrocode} |
| 173 |
% \begin{option}{notitlepage} |
| 174 |
% \changes{v2.95c}{2006/08/21}{obsolete} |
| 175 |
% \changes{v3.01a}{2008/11/21}{standard not obsolete} |
| 176 |
% \begin{macrocode} |
| 177 |
\KOMA@DeclareStandardOption% |
| 178 |
%<package> [scrextend]% |
| 179 |
{notitlepage}{titlepage=false} |
| 180 |
%</option> |
| 181 |
% \end{macrocode} |
| 182 |
% \end{option}^^A notitlepage |
| 183 |
% \end{macro}^^A \if@titlepageiscoverpage |
| 184 |
% \end{macro}^^A \if@titlepage |
| 185 |
% \end{option}^^A titlepage |
| 186 |
% |
| 187 |
% \begin{command}{\extratitle} |
| 188 |
% \begin{macro}{\@extratitle} |
| 189 |
% \begin{command}{\frontispiece} |
| 190 |
% \changes{v3.25}{2017/11/21}{added} |
| 191 |
% \begin{macro}{\@frontispiece} |
| 192 |
% \changes{v3.25}{2017/11/21}{added} |
| 193 |
% \begin{command}{\titlehead} |
| 194 |
% \begin{macro}{\@titlehead} |
| 195 |
% \begin{command}{\subject} |
| 196 |
% \begin{macro}{\@subject} |
| 197 |
% \begin{command}{\subtitle} |
| 198 |
% \changes{v2.97c}{2007/06/20}{neue Möglichkeit} |
| 199 |
% \begin{macro}{\@subtitle} |
| 200 |
% \changes{v2.97c}{2007/06/20}{added} |
| 201 |
% \begin{command}{\publishers} |
| 202 |
% \begin{macro}{\@publishers} |
| 203 |
% \begin{command}{\uppertitleback} |
| 204 |
% \begin{macro}{\@uppertitleback} |
| 205 |
% \begin{command}{\lowertitleback} |
| 206 |
% \begin{macro}{\@lowertitleback} |
| 207 |
% \begin{command}{\dedication} |
| 208 |
% \begin{macro}{\@dedication} |
| 209 |
% The \LaTeX{} kernel already provides user commands \cs{title}, \cs{author}, |
| 210 |
% \cs{date}, which store their arguments globally into macros \cs{@title}, |
| 211 |
% \cs{@author} and \cs{@date}. But for \KOMAScript{} these are not enough for |
| 212 |
% several pages of title and even not for the main title. So several more |
| 213 |
% similar commands and macros are defined. All additional user commands but |
| 214 |
% \cs{subject} are long. |
| 215 |
% \begin{description} |
| 216 |
% \item[ToDo:] Make them all robust as \LaTeX{} from 2018/10/01 does. However |
| 217 |
% this could be incompatible with \pkg{uni-titlepage}, so when doing the |
| 218 |
% change, don't forget to also change \pkg{uni-titlepage} if needed. |
| 219 |
% \end{description} |
| 220 |
% For package \pkg*{scrextend} all the code is added to the activatable |
| 221 |
% \texttt{title}. |
| 222 |
% \begin{macrocode} |
| 223 |
%<*body> |
| 224 |
%<package&extend>\scr@ext@addto@activateable{title}{% |
| 225 |
\newcommand*{\@extratitle}{}% |
| 226 |
\newcommand{\extratitle}[1]{\gdef\@extratitle{% |
| 227 |
%<extend> ##1% |
| 228 |
%<!extend> #1% |
| 229 |
}}% |
| 230 |
\newcommand*{\@frontispiece}{}% |
| 231 |
\newcommand{\frontispiece}[1]{\gdef\@frontispiece{% |
| 232 |
%<extend> ##1% |
| 233 |
%<!extend> #1% |
| 234 |
}}% |
| 235 |
\newcommand*{\@titlehead}{}% |
| 236 |
\newcommand{\titlehead}[1]{\gdef\@titlehead{% |
| 237 |
%<extend> ##1% |
| 238 |
%<!extend> #1% |
| 239 |
}}% |
| 240 |
\newcommand*{\@subject}{}% |
| 241 |
\newcommand*{\subject}[1]{\gdef\@subject{% |
| 242 |
%<extend> ##1% |
| 243 |
%<!extend> #1% |
| 244 |
}}% |
| 245 |
\newcommand*{\subtitle}[1]{\gdef\@subtitle{% |
| 246 |
%<extend> ##1% |
| 247 |
%<!extend> #1% |
| 248 |
}}% |
| 249 |
\newcommand*{\@subtitle}{}% |
| 250 |
\newcommand*{\@publishers}{}% |
| 251 |
\newcommand{\publishers}[1]{\gdef\@publishers{% |
| 252 |
%<extend> ##1% |
| 253 |
%<!extend> #1% |
| 254 |
}}% |
| 255 |
\newcommand*{\@uppertitleback}{}% |
| 256 |
\newcommand{\uppertitleback}[1]{\gdef\@uppertitleback{% |
| 257 |
%<extend> ##1% |
| 258 |
%<!extend> #1% |
| 259 |
}}% |
| 260 |
\newcommand*{\@lowertitleback}{}% |
| 261 |
\newcommand{\lowertitleback}[1]{\gdef\@lowertitleback{% |
| 262 |
%<extend> ##1% |
| 263 |
%<!extend> #1% |
| 264 |
}}% |
| 265 |
\newcommand*{\@dedication}{}% |
| 266 |
\newcommand{\dedication}[1]{\gdef\@dedication{% |
| 267 |
%<extend> ##1% |
| 268 |
%<!extend> #1% |
| 269 |
}}% |
| 270 |
% \end{macrocode} |
| 271 |
% \end{macro} |
| 272 |
% \end{command} |
| 273 |
% \end{macro} |
| 274 |
% \end{command} |
| 275 |
% \end{macro} |
| 276 |
% \end{command} |
| 277 |
% \end{macro} |
| 278 |
% \end{command} |
| 279 |
% \end{macro} |
| 280 |
% \end{command} |
| 281 |
% \end{macro} |
| 282 |
% \end{command} |
| 283 |
% \end{macro} |
| 284 |
% \end{command} |
| 285 |
% \end{macro} |
| 286 |
% \end{command} |
| 287 |
% \end{macro} |
| 288 |
% \end{command} |
| 289 |
% |
| 290 |
% \begin{macro}{\next@tpage} |
| 291 |
% \changes{v2.3b}{1995/07/24}{\cs{null} removed} |
| 292 |
% \changes{v2.3g}{1996/01/14}{\cs{newpage} replaced by \cs{clearpage}} |
| 293 |
% \changes{v3.11c}{2013/02/14}{output \cs{@thanks}} |
| 294 |
% \changes{v3.11c}{2013/02/14}{initialize \cs{@thanks}} |
| 295 |
% \changes{v3.20}{2015/10/14}{\cs{setparsizes} resp. similar code added} |
| 296 |
% \begin{macro}{\next@tdpage} |
| 297 |
% \changes{v3.11c}{2013/02/14}{added} |
| 298 |
% \changes{v3.12}{2013/11/21}{\cs{titlepage@restore} added} |
| 299 |
% Because we have more than one title page but all title pages inside one |
| 300 |
% \env{titlepage} environment, we need a special kind of |
| 301 |
% \cs{newpage}/\cs{clearpage}. |
| 302 |
% \begin{description} |
| 303 |
% \item[ToDo:] Replace the original \cs{clearpage} and \cs{cleardoublepage} |
| 304 |
% inside \env{titlepage} by these two macros. With this, users could also |
| 305 |
% have more than one page inside a \env{titlepage} environment. |
| 306 |
% \end{description} |
| 307 |
% \begin{macrocode} |
| 308 |
\newcommand*{\next@tpage}{% |
| 309 |
\@thanks\global\let\@thanks\@empty |
| 310 |
\clearpage |
| 311 |
\csname titlepage@restore\endcsname |
| 312 |
%<!extend> \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative |
| 313 |
%<extend> \parskip\z@ \parindent\z@ \parfillskip\z@\@plus 1fil |
| 314 |
\thispagestyle{empty}% |
| 315 |
\let\footnote\thanks |
| 316 |
\setcounter{footnote}{0}% |
| 317 |
} |
| 318 |
\newcommand*{\next@tdpage}{% |
| 319 |
\next@tpage\if@twoside \ifodd\value{page}\else\null\next@tpage\fi\fi |
| 320 |
} |
| 321 |
% \end{macrocode} |
| 322 |
% \end{macro}^^A \next@tdpage |
| 323 |
% \end{macro}^^A \next@tpage |
| 324 |
% |
| 325 |
% \begin{command}{\maketitle} |
| 326 |
% \changes{v2.3a}{1995/07/08}{\texttt{plus} replaced by \cs{@plus}} |
| 327 |
% \changes{v2.3a}{1995/07/08}{\texttt{fill} replaced by \cs{fill}} |
| 328 |
% \changes{v2.3a}{1995/07/08}{\cs{vfil} replaced by \cs{vfill}} |
| 329 |
% \changes{v2.3a}{1995/07/08}{using \cs{@makefnmark} in \cs{@makefntext}} |
| 330 |
% \changes{v2.3a}{1995/07/08}{\cs{@makefnmark} and \cs{@makefntext} |
| 331 |
% independent from math mode} |
| 332 |
% \changes{v2.3b}{1995/07/24}{page break inside \cs{@extratitle} in |
| 333 |
% double-sided mode fixed} |
| 334 |
% \changes{v2.3d}{1995/08/19}{\cs{fill} replaced by \texttt{fill}} |
| 335 |
% \changes{v2.3e}{1995/08/30}{support but ignore optional argument in |
| 336 |
% single-sided mode} |
| 337 |
% \changes{v2.3g}{1996/01/14}{several \cs{null} to \cs{next@tpage} added} |
| 338 |
% \changes{v2.3g}{1996/01/14}{\cs{footnote} in titles fixed} |
| 339 |
% \changes{v2.3g}{1996/01/14}{deleting \cs{@date}, \cs{title} etc. to save memory} |
| 340 |
% \changes{v2.3g}{1996/01/14}{\cs{gdef} replaced by \cs{global}\cs{let}} |
| 341 |
% \changes{v2.4}{1996/02/25}{\cs{footnote} in titles fixed again} |
| 342 |
% \changes{v2.4h}{1996/11/09}{always use \cs{sectfont} followed by the side |
| 343 |
% for the \cs{@title}} |
| 344 |
% \changes{v2.4l}{1997/02/06}{using footnote symbols with width 0} |
| 345 |
% \changes{v2.4l}{1997/02/06}{redefining \cs{\@makefnmark} instead of |
| 346 |
% \cs{@makefntext} only} |
| 347 |
% \changes{v2.8d}{2001/07/05}{using \cs{titlepagestyle} for in-page title} |
| 348 |
% \changes{v2.8p}{2001/09/22}{\cs{sectfont} replaced by \cs{titlefont}} |
| 349 |
% \changes{v2.95c}{2006/08/21}{setting paragraph base values} |
| 350 |
% \changes{v2.97c}{2007/08/31}{interleaf pages with page style |
| 351 |
% \pstyle{emmpty}} |
| 352 |
% \changes{v3.04a}{2009/07/14}{distinguishing in-page titles and title pages |
| 353 |
% inside \cs{maketitle} instead of loading time} |
| 354 |
% \changes{v3.11c}{2013/02/14}{mock title moved to new macro} |
| 355 |
% \changes{v3.11c}{2013/02/14}{using \cs{next@tdpage}} |
| 356 |
% \changes{v3.12}{2013/05/29}{using font elements \fnt{titlehead}, |
| 357 |
% \fnt{author}, \fnt{date}, \fnt{publishers}, \fnt{dedication}} |
| 358 |
% \changes{v3.12}{2013/11/21}{support for |
| 359 |
% \opt{titlepage\quotechar=firstiscover}} |
| 360 |
% \changes{v3.12}{2013/11/21}{retro page only if needed} |
| 361 |
% \changes{v3.12}{2013/11/21}{kill the title macros only in compatibility mode} |
| 362 |
% \changes{v3.12a}{2014/03/03}{orphan spaced fixed} |
| 363 |
% \changes{v3.12a}{2014/03/03}{output extra/mock title in one-side mode only |
| 364 |
% if not empty} |
| 365 |
% \changes{v3.12a}{2014/03/03}{\cs{next@tdpage} removed from \cs{@maketitle} |
| 366 |
% and \cs{@makeextrattitle}} |
| 367 |
% \changes{v3.13}{2013/10/31}{\cs{next@tdpage} replaced by |
| 368 |
% \cs{cleardoubleemptypage} after dedication (last title page)} |
| 369 |
% \changes{v3.19}{2015/08/25}{don't use empty \cs{titlepagestyle}} |
| 370 |
% \changes{v3.25}{2017/11/21}{support for \cs{@frontispiece}} |
| 371 |
% \changes{v3.27}{2019/01/01}{warning for not empty retro page in single-sided |
| 372 |
% mode} |
| 373 |
% \changes{v3.27}{2019/03/18}{empty \cs{@thanks} after usage} |
| 374 |
% \changes{v3.27}{2019/03/18}{deleting \cs{@thanks} always globally} |
| 375 |
% The user command that prints either the in-page title or the title pages |
| 376 |
% with all the title macros filled before. |
| 377 |
% \begin{macrocode} |
| 378 |
%<package&extend>\let\maketitle\relax\let\@maketitle\relax |
| 379 |
\newcommand*\maketitle[1][1]{% |
| 380 |
% \end{macrocode} |
| 381 |
% \changes{v3.39}{2022/10/25}{using \cs{scr@v@is@ge}} |
| 382 |
% To support several \cs{maketitle} in the same document, we have to take care |
| 383 |
% to use the correct \cs{and} every time. So we define it here (instead of |
| 384 |
% outside). |
| 385 |
% \begin{macrocode} |
| 386 |
%<!v4> \expandafter\ifnum \scr@v@is@ge{3.12}% |
| 387 |
\def\and{% |
| 388 |
\end{tabular}% |
| 389 |
\hskip 1em \@plus.17fil% |
| 390 |
\begin{tabular}[t]{c}% |
| 391 |
}% |
| 392 |
%<!v4> \fi |
| 393 |
% \end{macrocode} |
| 394 |
% Depending on in-page titles or title pages, we have to use different |
| 395 |
% code. First the title pages. |
| 396 |
% \begin{macrocode} |
| 397 |
\if@titlepage |
| 398 |
\begin{titlepage} |
| 399 |
\setcounter{page}{% |
| 400 |
%<extend> ##1% |
| 401 |
%<!extend> #1% |
| 402 |
}% |
| 403 |
% \end{macrocode} |
| 404 |
% From \KOMAScript~3.12 we need special treatment for the case this is the |
| 405 |
% first title page and the first one should be the cover. The changes here has |
| 406 |
% to be restored later. So we locally define \cs{titlepage@restore} to restore |
| 407 |
% the original parameters. |
| 408 |
% \begin{macrocode} |
| 409 |
\if@titlepageiscoverpage |
| 410 |
\edef\titlepage@restore{% |
| 411 |
\noexpand\endgroup |
| 412 |
\noexpand\global\noexpand\@colht\the\@colht |
| 413 |
\noexpand\global\noexpand\@colroom\the\@colroom |
| 414 |
\noexpand\global\vsize\the\vsize |
| 415 |
\noexpand\global\noexpand\@titlepageiscoverpagefalse |
| 416 |
\noexpand\let\noexpand\titlepage@restore\noexpand\relax |
| 417 |
}% |
| 418 |
\begingroup |
| 419 |
\topmargin=\dimexpr \coverpagetopmargin-1in\relax |
| 420 |
\oddsidemargin=\dimexpr \coverpageleftmargin-1in\relax |
| 421 |
\evensidemargin=\dimexpr \coverpageleftmargin-1in\relax |
| 422 |
\textwidth=\dimexpr |
| 423 |
\paperwidth-\coverpageleftmargin-\coverpagerightmargin\relax |
| 424 |
\textheight=\dimexpr |
| 425 |
\paperheight-\coverpagetopmargin-\coverpagebottommargin\relax |
| 426 |
\headheight=0pt |
| 427 |
\headsep=0pt |
| 428 |
\footskip=\baselineskip |
| 429 |
\@colht=\textheight |
| 430 |
\@colroom=\textheight |
| 431 |
\vsize=\textheight |
| 432 |
\columnwidth=\textwidth |
| 433 |
\hsize=\columnwidth |
| 434 |
\linewidth=\hsize |
| 435 |
\else |
| 436 |
\let\titlepage@restore\relax |
| 437 |
\fi |
| 438 |
\let\footnotesize\small |
| 439 |
\let\footnoterule\relax |
| 440 |
\let\footnote\thanks |
| 441 |
\renewcommand*\thefootnote{\@fnsymbol\c@footnote}% |
| 442 |
\let\@oldmakefnmark\@makefnmark |
| 443 |
\renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark}% |
| 444 |
\ifx\@extratitle\@empty |
| 445 |
\ifx\@frontispiece\@empty |
| 446 |
\else |
| 447 |
\if@twoside\mbox{}\next@tpage\fi |
| 448 |
\noindent\@frontispiece\next@tdpage |
| 449 |
\fi |
| 450 |
\else |
| 451 |
\noindent\@extratitle |
| 452 |
\ifx\@frontispiece\@empty |
| 453 |
\else |
| 454 |
\next@tpage |
| 455 |
\noindent\@frontispiece |
| 456 |
\fi |
| 457 |
\next@tdpage |
| 458 |
\fi |
| 459 |
%<!extend> \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative |
| 460 |
%<extend> \parskip\z@ \parindent\z@ \parfillskip\z@\@plus 1fil |
| 461 |
\ifx\@titlehead\@empty \else |
| 462 |
\begin{minipage}[t]{\textwidth}% |
| 463 |
\usekomafont{titlehead}{\@titlehead\par}% |
| 464 |
\end{minipage}\par |
| 465 |
\fi |
| 466 |
\null\vfill |
| 467 |
\begin{center} |
| 468 |
\ifx\@subject\@empty \else |
| 469 |
{\usekomafont{subject}{\@subject\par}}% |
| 470 |
\vskip 3em |
| 471 |
\fi |
| 472 |
{\usekomafont{title}{\huge \@title\par}}% |
| 473 |
\vskip 1em |
| 474 |
{\ifx\@subtitle\@empty\else\usekomafont{subtitle}{\@subtitle\par}\fi}% |
| 475 |
\vskip 2em |
| 476 |
{% |
| 477 |
\usekomafont{author}{% |
| 478 |
\lineskip 0.75em |
| 479 |
\begin{tabular}[t]{c} |
| 480 |
\@author |
| 481 |
\end{tabular}\par |
| 482 |
}% |
| 483 |
}% |
| 484 |
\vskip 1.5em |
| 485 |
{\usekomafont{date}{\@date \par}}% |
| 486 |
\vskip \z@ \@plus3fill |
| 487 |
{\usekomafont{publishers}{\@publishers \par}}% |
| 488 |
\vskip 3em |
| 489 |
\end{center}\par |
| 490 |
\@thanks\global\let\@thanks\@empty |
| 491 |
\vfill\null |
| 492 |
\if@twoside |
| 493 |
% \end{macrocode} |
| 494 |
% \changes{v3.39}{2022/10/25}{using \cs{scr@v@is@ge}} |
| 495 |
% From \KOMAScript~3.12 we show the retro page only if needed. It is needed in |
| 496 |
% double-sided mode, if the upper and lower elements are not empty. |
| 497 |
% \begin{macrocode} |
| 498 |
\@tempswatrue |
| 499 |
%<!v4> \expandafter\ifnum \scr@v@is@ge{3.12}% |
| 500 |
\ifx\@uppertitleback\@empty\ifx\@lowertitleback\@empty |
| 501 |
\@tempswafalse |
| 502 |
\fi\fi |
| 503 |
%<!v4> \fi |
| 504 |
\if@tempswa |
| 505 |
\next@tpage |
| 506 |
\begin{minipage}[t]{\textwidth} |
| 507 |
\@uppertitleback |
| 508 |
\end{minipage}\par |
| 509 |
\vfill |
| 510 |
\begin{minipage}[b]{\textwidth} |
| 511 |
\@lowertitleback |
| 512 |
\end{minipage}\par |
| 513 |
\@thanks\global\let\@thanks\@empty |
| 514 |
\fi |
| 515 |
% \end{macrocode} |
| 516 |
% In single-sided mode, we warn for used but never printed upper and lower |
| 517 |
% retro page variables. |
| 518 |
% \begin{macrocode} |
| 519 |
\else |
| 520 |
\ifx\@uppertitleback\@empty\else |
| 521 |
%<package> \PackageWarning{scrextend}% |
| 522 |
%<class> \ClassWarning{\KOMAClassName}% |
| 523 |
{% |
| 524 |
non empty \string\uppertitleback\space ignored |
| 525 |
by \string\maketitle\MessageBreak |
| 526 |
in `twoside=false' mode% |
| 527 |
}% |
| 528 |
\fi |
| 529 |
\ifx\@lowertitleback\@empty\else |
| 530 |
%<package> \PackageWarning{scrextend}% |
| 531 |
%<class> \ClassWarning{\KOMAClassName}% |
| 532 |
{% |
| 533 |
non empty \string\lowertitleback\space ignored |
| 534 |
by \string\maketitle\MessageBreak |
| 535 |
in `twoside=false' mode% |
| 536 |
}% |
| 537 |
\fi |
| 538 |
\fi |
| 539 |
\ifx\@dedication\@empty |
| 540 |
\else |
| 541 |
\next@tdpage\null\vfill |
| 542 |
{\centering\usekomafont{dedication}{\@dedication \par}}% |
| 543 |
\vskip \z@ \@plus3fill |
| 544 |
% \end{macrocode} |
| 545 |
% \begin{description} |
| 546 |
% \item[ToDo:] Why can't we use \cs{next@tdpage} here? Would this be a |
| 547 |
% problem, if we redefine \cs{cleardoublepage} to \cs{next@tdpage}? |
| 548 |
% \end{description} |
| 549 |
% \begin{macrocode} |
| 550 |
\@thanks\global\let\@thanks\@empty |
| 551 |
\cleardoubleemptypage |
| 552 |
\fi |
| 553 |
% \end{macrocode} |
| 554 |
% If we are still at a cover page, we have to restore the title page. |
| 555 |
% \begin{macrocode} |
| 556 |
\ifx\titlepage@restore\relax\else\clearpage\titlepage@restore\fi |
| 557 |
\end{titlepage} |
| 558 |
\else |
| 559 |
% \end{macrocode} |
| 560 |
% Now, the in-page title. |
| 561 |
% \begin{macrocode} |
| 562 |
\par |
| 563 |
\@tempcnta=% |
| 564 |
%<extend> ##1% |
| 565 |
%<!extend> #1% |
| 566 |
\relax\ifnum\@tempcnta=1\else |
| 567 |
%<class> \ClassWarning{\KOMAClassName}% |
| 568 |
%<package> \PackageWarning{scrextend}% |
| 569 |
{% |
| 570 |
Optional argument of \string\maketitle\space ignored\MessageBreak |
| 571 |
in `titlepage=false' mode% |
| 572 |
}% |
| 573 |
\fi |
| 574 |
\ifx\@uppertitleback\@empty\else |
| 575 |
%<class> \ClassWarning{\KOMAClassName}% |
| 576 |
%<package> \PackageWarning{scrextend}% |
| 577 |
{% |
| 578 |
non empty \string\uppertitleback\space ignored |
| 579 |
by \string\maketitle\MessageBreak |
| 580 |
in `titlepage=false' mode% |
| 581 |
}% |
| 582 |
\fi |
| 583 |
\ifx\@lowertitleback\@empty\else |
| 584 |
%<class> \ClassWarning{\KOMAClassName}% |
| 585 |
%<package> \PackageWarning{scrextend}% |
| 586 |
{% |
| 587 |
non empty \string\lowertitleback\space ignored |
| 588 |
by \string\maketitle\MessageBreak |
| 589 |
in `titlepage=false' mode% |
| 590 |
}% |
| 591 |
\fi |
| 592 |
\begingroup |
| 593 |
\let\titlepage@restore\relax |
| 594 |
\renewcommand*\thefootnote{\@fnsymbol\c@footnote}% |
| 595 |
\let\@oldmakefnmark\@makefnmark |
| 596 |
\renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark}% |
| 597 |
\next@tdpage |
| 598 |
\if@twocolumn |
| 599 |
\ifnum \col@number=\@ne |
| 600 |
\ifx\@extratitle\@empty |
| 601 |
\ifx\@frontispiece\@empty\else\if@twoside\mbox{}\fi\fi |
| 602 |
\else |
| 603 |
\@makeextratitle |
| 604 |
\fi |
| 605 |
\ifx\@frontispiece\@empty |
| 606 |
\ifx\@extratitle\@empty\else\next@tdpage\fi |
| 607 |
\else |
| 608 |
\next@tpage |
| 609 |
\@makefrontispiece |
| 610 |
\next@tdpage |
| 611 |
\fi |
| 612 |
\@maketitle |
| 613 |
\else |
| 614 |
\ifx\@extratitle\@empty |
| 615 |
\ifx\@frontispiece\@empty\else\if@twoside\mbox{}\fi\fi |
| 616 |
\else |
| 617 |
\twocolumn[\@makeextratitle]% |
| 618 |
\fi |
| 619 |
\ifx\@frontispiece\@empty |
| 620 |
\ifx\@extratitle\@empty\else\next@tdpage\fi |
| 621 |
\else |
| 622 |
\next@tpage |
| 623 |
\twocolumn[\@makefrontispiece]% |
| 624 |
\next@tdpage |
| 625 |
\fi |
| 626 |
\twocolumn[\@maketitle]% |
| 627 |
\fi |
| 628 |
\else |
| 629 |
\ifx\@extratitle\@empty |
| 630 |
\ifx\@frontispiece\@empty\else \mbox{}\fi |
| 631 |
\else |
| 632 |
\@makeextratitle |
| 633 |
\fi |
| 634 |
\ifx\@frontispiece\@empty |
| 635 |
\ifx\@extratitle\@empty\else\next@tdpage\fi |
| 636 |
\else |
| 637 |
\next@tpage |
| 638 |
\@makefrontispiece |
| 639 |
\next@tdpage |
| 640 |
\fi |
| 641 |
\@maketitle |
| 642 |
\fi |
| 643 |
\ifx\titlepagestyle\@empty\else\thispagestyle{\titlepagestyle}\fi |
| 644 |
\@thanks\global\let\@thanks\@empty |
| 645 |
\endgroup |
| 646 |
\fi |
| 647 |
\setcounter{footnote}{0}% |
| 648 |
%<*!v4> |
| 649 |
\expandafter\ifnum \scr@v@is@lt{3.12}% |
| 650 |
\let\thanks\relax |
| 651 |
\let\maketitle\relax |
| 652 |
\let\@maketitle\relax |
| 653 |
\global\let\@thanks\@empty |
| 654 |
\global\let\@author\@empty |
| 655 |
\global\let\@date\@empty |
| 656 |
\global\let\@title\@empty |
| 657 |
\global\let\@subtitle\@empty |
| 658 |
\global\let\@extratitle\@empty |
| 659 |
\global\let\@frontispiece\@empty |
| 660 |
\global\let\@titlehead\@empty |
| 661 |
\global\let\@subject\@empty |
| 662 |
\global\let\@publishers\@empty |
| 663 |
\global\let\@uppertitleback\@empty |
| 664 |
\global\let\@lowertitleback\@empty |
| 665 |
\global\let\@dedication\@empty |
| 666 |
\global\let\author\relax |
| 667 |
\global\let\title\relax |
| 668 |
\global\let\extratitle\relax |
| 669 |
\global\let\titlehead\relax |
| 670 |
\global\let\subject\relax |
| 671 |
\global\let\publishers\relax |
| 672 |
\global\let\uppertitleback\relax |
| 673 |
\global\let\lowertitleback\relax |
| 674 |
\global\let\dedication\relax |
| 675 |
\global\let\date\relax |
| 676 |
\fi |
| 677 |
%</!v4> |
| 678 |
\global\let\and\relax |
| 679 |
}% |
| 680 |
% \end{macrocode} |
| 681 |
% \begin{macro}{\@maketitle} |
| 682 |
% \changes{v2.95c}{2006/08/21}{default paragraph settings} |
| 683 |
% \changes{v3.11c}{2012/02/14}{extra/mock title moved to \cs{@makeextratitle}} |
| 684 |
% \changes{v3.12a}{2014/03/03}{\cs{next@tdpage} removed} |
| 685 |
% \begin{macro}{\@makeextratitle} |
| 686 |
% \changes{v3.11c}{2013/02/14}{added} |
| 687 |
% \changes{v3.12a}{2014/03/03}{\cs{next@tdpage} removed} |
| 688 |
% \begin{macro}{\@makefrontispiece} |
| 689 |
% \changes{v3.25}{2017/11/21}{added} |
| 690 |
% These do the printing of the main title, the extra or mock title and the |
| 691 |
% frontispiece (retro page of the mock title). |
| 692 |
% \begin{macrocode} |
| 693 |
\newcommand*{\@makeextratitle}{% |
| 694 |
\ifx\@extratitle\@empty \else |
| 695 |
\noindent\@extratitle\par |
| 696 |
\fi |
| 697 |
} |
| 698 |
\newcommand*{\@makefrontispiece}{% |
| 699 |
\ifx\@frontispiece\@empty \else |
| 700 |
\noindent\@frontispiece\par |
| 701 |
\fi |
| 702 |
} |
| 703 |
\newcommand*{\@maketitle}{% |
| 704 |
\global\@topnum=\z@ |
| 705 |
%<!extend> \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative |
| 706 |
%<extend> \parskip\z@ \parindent\z@ \parfillskip\z@\@plus 1fil |
| 707 |
\ifx\@titlehead\@empty \else |
| 708 |
\begin{minipage}[t]{\textwidth} |
| 709 |
\usekomafont{titlehead}{\@titlehead\par}% |
| 710 |
\end{minipage}\par |
| 711 |
\fi |
| 712 |
\null |
| 713 |
\vskip 2em% |
| 714 |
\begin{center}% |
| 715 |
\ifx\@subject\@empty \else |
| 716 |
{\usekomafont{subject}{\@subject \par}}% |
| 717 |
\vskip 1.5em |
| 718 |
\fi |
| 719 |
{\usekomafont{title}{\huge \@title \par}}% |
| 720 |
\vskip .5em |
| 721 |
{\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% |
| 722 |
\vskip 1em |
| 723 |
{% |
| 724 |
\usekomafont{author}{% |
| 725 |
\lineskip .5em% |
| 726 |
\begin{tabular}[t]{c} |
| 727 |
\@author |
| 728 |
\end{tabular}\par |
| 729 |
}% |
| 730 |
}% |
| 731 |
\vskip 1em% |
| 732 |
{\usekomafont{date}{\@date \par}}% |
| 733 |
\vskip \z@ \@plus 1em |
| 734 |
{\usekomafont{publishers}{\@publishers \par}}% |
| 735 |
\ifx\@dedication\@empty \else |
| 736 |
\vskip 2em |
| 737 |
{\usekomafont{dedication}{\@dedication \par}}% |
| 738 |
\fi |
| 739 |
\end{center}% |
| 740 |
\par |
| 741 |
\vskip 2em |
| 742 |
}% |
| 743 |
% \end{macrocode} |
| 744 |
% \end{macro}^^A \@makefrontispiece |
| 745 |
% \end{macro}^^A \@makeextratitle |
| 746 |
% \end{macro}^^A \@maketitle |
| 747 |
% \end{command}^^A \maketitle |
| 748 |
% |
| 749 |
% \begin{command}{\coverpagetopmargin} |
| 750 |
% \changes{v3.12}{2013/11/21}{added} |
| 751 |
% Top margin of a cover page (\opt{titlepage=firstiscover}). |
| 752 |
% \begin{macrocode} |
| 753 |
\newcommand*{\coverpagetopmargin}{% |
| 754 |
\dimexpr \topmargin+1in\relax |
| 755 |
} |
| 756 |
% \end{macrocode} |
| 757 |
% \end{command} |
| 758 |
% |
| 759 |
% \begin{command}{\coverpagebottommargin} |
| 760 |
% \changes{v3.12}{2013/11/21}{added} |
| 761 |
% Bottom margin of a cover page (\opt{titlepage=firstiscover}). |
| 762 |
% \begin{macrocode} |
| 763 |
\newcommand*{\coverpagebottommargin}{% |
| 764 |
2\dimexpr\coverpagetopmargin\relax |
| 765 |
} |
| 766 |
% \end{macrocode} |
| 767 |
% \end{command} |
| 768 |
% |
| 769 |
% \begin{command}{\coverpageleftmargin} |
| 770 |
% \changes{v3.12}{2013/11/21}{added} |
| 771 |
% Left margin of a cover page (\opt{titlepage=firstiscover}). |
| 772 |
% \begin{macrocode} |
| 773 |
\newcommand*{\coverpageleftmargin}{% |
| 774 |
\dimexpr \evensidemargin+1in\relax |
| 775 |
} |
| 776 |
% \end{macrocode} |
| 777 |
% \end{command} |
| 778 |
% |
| 779 |
% \begin{command}{\coverpagerightmargin} |
| 780 |
% \changes{v3.12}{2013/11/21}{added} |
| 781 |
% Right margin of a cover page (\opt{titlepage=firstiscover}). |
| 782 |
% \begin{macrocode} |
| 783 |
\newcommand*{\coverpagerightmargin}{\coverpageleftmargin} |
| 784 |
% \end{macrocode} |
| 785 |
% \end{command} |
| 786 |
% |
| 787 |
% \begin{environment}{titlepage} |
| 788 |
% \changes{v3.39}{2022/10/25}{\LaTeX{} 2.09 compatibility mode with |
| 789 |
% \pkg{scrextend} only} |
| 790 |
% The environment to be used for title pages. Title pages are always |
| 791 |
% one-columned and use page style \pstyle{empty}. We have to take care to |
| 792 |
% reset this at the end of the title page. |
| 793 |
% \begin{description} |
| 794 |
% \item[ToDo:] Wouldn't it be better to use \cs{pagestyle} instead of |
| 795 |
% \cs{thispagestyle}, because \cs{pagestyle} would also be valid, if a user |
| 796 |
% uses more than one page inside a \env{titlepage} environment? |
| 797 |
% \item[ToDo:] See the note about \cs{next@tpage} above. |
| 798 |
% \end{description} |
| 799 |
% \begin{macrocode} |
| 800 |
%<package&extend>\scr@ifundefinedorrelax{titlepage}{% |
| 801 |
\newenvironment{titlepage}{% |
| 802 |
%<report|book> \cleardoublepage |
| 803 |
\if@twocolumn |
| 804 |
\@restonecoltrue\onecolumn |
| 805 |
\else |
| 806 |
\@restonecolfalse\newpage |
| 807 |
\fi |
| 808 |
\thispagestyle{empty}% |
| 809 |
%<package&extend> \if@compatibility \setcounter{page}{0}\fi |
| 810 |
}{% |
| 811 |
\if@restonecol\twocolumn \else \newpage \fi |
| 812 |
}% |
| 813 |
%<package&extend>}{}% |
| 814 |
% \end{macrocode} |
| 815 |
% \end{environment} |
| 816 |
% |
| 817 |
% In case of package \pkg*{scrextend} the code of activatable \texttt{title} |
| 818 |
% is complete and should be used if activated. |
| 819 |
% \begin{macrocode} |
| 820 |
%<package&extend>}\csname scr@ext@immediate@title\endcsname |
| 821 |
% \end{macrocode} |
| 822 |
% |
| 823 |
% \begin{fontelement}{subtitle} |
| 824 |
% \changes{v2.97c}{2007/06/20}{added} |
| 825 |
% \begin{macrocode} |
| 826 |
\newkomafont{subtitle}{\usekomafont{title}\large}% |
| 827 |
% \end{macrocode} |
| 828 |
% \end{fontelement} |
| 829 |
% |
| 830 |
% \begin{fontelement}{titlehead} |
| 831 |
% \changes{v3.12}{2013/05/29}{added} |
| 832 |
% \begin{macrocode} |
| 833 |
\newkomafont{titlehead}{}% |
| 834 |
% \end{macrocode} |
| 835 |
% \end{fontelement} |
| 836 |
% |
| 837 |
% \begin{fontelement}{author} |
| 838 |
% \changes{v3.12}{2013/05/29}{added} |
| 839 |
% \begin{macrocode} |
| 840 |
\newkomafont{author}{\Large} |
| 841 |
% \end{macrocode} |
| 842 |
% \end{fontelement} |
| 843 |
% |
| 844 |
% \begin{fontelement}{date} |
| 845 |
% \changes{v3.12}{2013/05/29}{added} |
| 846 |
% \begin{macrocode} |
| 847 |
\newkomafont{date}{\Large} |
| 848 |
% \end{macrocode} |
| 849 |
% \end{fontelement} |
| 850 |
% |
| 851 |
% \begin{fontelement}{publishers} |
| 852 |
% \changes{v3.12}{2013/05/29}{added} |
| 853 |
% \begin{macrocode} |
| 854 |
\newkomafont{publishers}{\Large} |
| 855 |
% \end{macrocode} |
| 856 |
% \end{fontelement} |
| 857 |
% |
| 858 |
% \begin{fontelement}{dedication} |
| 859 |
% \changes{v3.12}{2013/05/29}{added} |
| 860 |
% \begin{macrocode} |
| 861 |
\newkomafont{dedication}{\Large} |
| 862 |
% \end{macrocode} |
| 863 |
% \end{fontelement} |
| 864 |
% |
| 865 |
% \begin{fontelement}{title} |
| 866 |
% \changes{v2.8o}{2001/09/14}{added} |
| 867 |
% \begin{macro}{\titlefont} |
| 868 |
% \changes{v2.8p}{2001/09/22}{added} |
| 869 |
% Font to be used for the title. The font element has to be defined manually, |
| 870 |
% because of compatibility with \KOMAScript{} up to version 2.8n and old |
| 871 |
% \LaTeX~2.09 style \textsc{Script 2.0}. \cs{titlefont} is a user command for |
| 872 |
% compatibility only. So we index it a internal macro. |
| 873 |
% \begin{macrocode} |
| 874 |
\newcommand*\titlefont{\sectfont}% |
| 875 |
\newcommand*{\scr@fnt@title}{\titlefont}% |
| 876 |
% \end{macrocode} |
| 877 |
% \end{macro} |
| 878 |
% \end{fontelement} |
| 879 |
% |
| 880 |
% \begin{fontelement}{subject} |
| 881 |
% \changes{v2.8q}{2002/01/14}{added} |
| 882 |
% \changes{v2.95}{2002/06/26}{also with \cls*{scrbook}, \cls*{scrreprt}, |
| 883 |
% \cls*{scrartcl}} |
| 884 |
% \begin{macro}{\subject@font} |
| 885 |
% \changes{v2.8q}{2002/01/14}{added} |
| 886 |
% \changes{v2.95}{2002/06/26}{also defined with \cls*{scrbook}, |
| 887 |
% \cls*{scrreprt}, \cls*{scrartcl}} |
| 888 |
% This has to be defined manually, because of compatibility with \KOMAScript{} |
| 889 |
% up to version 2.8n and old \LaTeX~2.09 style \textsc{Script 2.0}. |
| 890 |
% \begin{macrocode} |
| 891 |
\newcommand*{\subject@font}{\normalfont\normalcolor\bfseries\Large}% |
| 892 |
\newcommand*{\scr@fnt@subject}{\subject@font}% |
| 893 |
%</body> |
| 894 |
% \end{macrocode} |
| 895 |
% \end{macro} |
| 896 |
% \end{fontelement} |
| 897 |
% |
| 898 |
% \begin{macrocode} |
| 899 |
%</!letter> |
| 900 |
% \end{macrocode} |
| 901 |
% |
| 902 |
% \section{Implementation of the Abstract} |
| 903 |
% |
| 904 |
% The abstract is not part of the title but related to it. But maybe it is |
| 905 |
% also a kind of section. |
| 906 |
% \begin{description} |
| 907 |
% \item[ToDo:] Should this be moved to \file{scrkernel-sections.dtx} or a new |
| 908 |
% file \file{scrkernel-abstract.dtx}? |
| 909 |
% \end{description} |
| 910 |
% It is only defined for the classes \cls*{scrartcl} and \cls*{scrreprt} but |
| 911 |
% not for \cls*{scrbook}, \cls*{scrlttr2} or package \pkg*{scrextend}. |
| 912 |
% \begin{macrocode} |
| 913 |
%<*class&(article|report)> |
| 914 |
% \end{macrocode} |
| 915 |
% |
| 916 |
% \begin{option}{abstract} |
| 917 |
% \changes{v2.95c}{2006/08/21}{added} |
| 918 |
% \begin{macro}{\@abstrttrue,\@abstrtfalse,\if@abstrt} |
| 919 |
% \changes{v3.17}{2015/03/10}{using \pkg*{scrkbase}} |
| 920 |
% \KOMAScript{} provides abstracts with and without titles and only for the |
| 921 |
% classes \cls*{scrartcl} and \cls*{scrreprt}. Books usually use a chapter for |
| 922 |
% the abstract. We just need a simple boolean option, that sets a boolean |
| 923 |
% switch. |
| 924 |
% \begin{macrocode} |
| 925 |
%<*option> |
| 926 |
\KOMA@ifkey{abstract}{@abstrt} |
| 927 |
% \end{macrocode} |
| 928 |
% \begin{option}{abstracton,abstractoff} |
| 929 |
% \changes{v2.95c}{2006/08/21}{obsolete} |
| 930 |
% \changes{v3.01a}{2008/11/21}{standard not obsolete} |
| 931 |
% \changes{v3.27}{2019/03/13}{deprecated} |
| 932 |
% \changes{v3.99}{2022/11/16}{removed from \KOMAScript~4} |
| 933 |
% \begin{macrocode} |
| 934 |
%<*!v4> |
| 935 |
\KOMA@DeclareDeprecatedOption{abstracton}{abstract=true} |
| 936 |
\KOMA@DeclareDeprecatedOption{abstractoff}{abstract=false} |
| 937 |
%</!v4> |
| 938 |
%</option> |
| 939 |
% \end{macrocode} |
| 940 |
% \end{option}^^A abstracton,abstractoff |
| 941 |
% \end{macro}^^A \if@abstrt |
| 942 |
% \end{option}^^A abstract |
| 943 |
% |
| 944 |
% \begin{environment}{abstract} |
| 945 |
% \changes{v2.3a}{1995/07/08}{\cs{@endparpenalty} added} |
| 946 |
% \changes{v2.3g}{1996/01/14}{\cs{@beginparpenalty} added} |
| 947 |
% \changes{v2.7a}{2001/01/04}{\cs{section*} replaced by \cs{addsec*}} |
| 948 |
% \changes{v3.04a}{2009/07/14}{\cs{if@titlepage} moved inside environment} |
| 949 |
% The abstract is different for documents with title page. We provide an |
| 950 |
% abstract with or without title. |
| 951 |
% \begin{macrocode} |
| 952 |
%<*body> |
| 953 |
\newenvironment{abstract}{% |
| 954 |
\if@titlepage |
| 955 |
\titlepage |
| 956 |
\null\vfil |
| 957 |
\@beginparpenalty\@lowpenalty |
| 958 |
\if@abstrt |
| 959 |
\begin{center} |
| 960 |
\normalfont\sectfont\nobreak\abstractname |
| 961 |
\@endparpenalty\@M |
| 962 |
\end{center} |
| 963 |
\fi |
| 964 |
\else |
| 965 |
\if@twocolumn\if@abstrt |
| 966 |
\addsec*{\abstractname} |
| 967 |
\fi |
| 968 |
\else |
| 969 |
\if@abstrt |
| 970 |
\small |
| 971 |
\begin{center} |
| 972 |
{\normalfont\sectfont\nobreak\abstractname |
| 973 |
\vspace{-.5em}\vspace{\z@}}% |
| 974 |
\end{center} |
| 975 |
\fi |
| 976 |
\quotation |
| 977 |
\fi |
| 978 |
\fi |
| 979 |
}{% |
| 980 |
\if@titlepage |
| 981 |
\par\vfil\null\endtitlepage |
| 982 |
\else |
| 983 |
\if@twocolumn\else\endquotation\fi |
| 984 |
\fi |
| 985 |
} |
| 986 |
% \end{macrocode} |
| 987 |
% \end{environment}^^A abstract |
| 988 |
% |
| 989 |
% \begin{command}{\abstractname} |
| 990 |
% \changes{v3.36}{2022/03/08}{explicit definition for English languages} |
| 991 |
% The name of the abstract (if a title is used). |
| 992 |
% \begin{macrocode} |
| 993 |
\newcommand*\abstractname{Abstract} |
| 994 |
\providecaptionname{american,australian,british,canadian,english,newzealand,% |
| 995 |
UKenglish,ukenglish,USenglish,usenglish}\abstractname{Abstract} |
| 996 |
%</body> |
| 997 |
% \end{macrocode} |
| 998 |
% \end{command}^^A \abstractname |
| 999 |
% |
| 1000 |
% \begin{macrocode} |
| 1001 |
%</class&(article|report)> |
| 1002 |
% \end{macrocode} |
| 1003 |
% |
| 1004 |
% |
| 1005 |
% \Finale |
| 1006 |
% \PrintChanges |
| 1007 |
% |
| 1008 |
\endinput |
| 1009 |
% Local Variables: |
| 1010 |
% mode: doctex |
| 1011 |
% ispell-local-dictionary: "en_US" |
| 1012 |
% eval: (flyspell-mode 1) |
| 1013 |
% TeX-master: t |
| 1014 |
% TeX-engine: luatex-dev |
| 1015 |
% eval: (setcar (or (cl-member "Index" (setq-local TeX-command-list (copy-alist TeX-command-list)) :key #'car :test #'string-equal) (setq-local TeX-command-list (cons nil TeX-command-list))) '("Index" "mkindex %s" TeX-run-index nil t :help "makeindex for dtx")) |
| 1016 |
% End: |