Debian Codegraph @

texmf-dist/source/generic/ltxcmds/ltxcmds.dtx

raw
1 % \iffalse meta-comment
2 %
3 % File: ltxcmds.dtx
4 % Version: 2023-12-04 v1.26
5 % Info: LaTeX kernel commands for general use
6 %
7 % Copyright (C)
8 % 2009-2011 Heiko Oberdiek
9 % 2016-2023 Oberdiek Package Support Group
10 % https://github.com/ho-tex/ltxcmds/issues
11 %
12 % This work may be distributed and/or modified under the
13 % conditions of the LaTeX Project Public License, either
14 % version 1.3c of this license or (at your option) any later
15 % version. This version of this license is in
16 % https://www.latex-project.org/lppl/lppl-1-3c.txt
17 % and the latest version of this license is in
18 % https://www.latex-project.org/lppl.txt
19 % and version 1.3 or later is part of all distributions of
20 % LaTeX version 2005/12/01 or later.
21 %
22 % This work has the LPPL maintenance status "maintained".
23 %
24 % The Current Maintainers of this work are
25 % Heiko Oberdiek and the Oberdiek Package Support Group
26 % https://github.com/ho-tex/ltxcmds/issues
27 %
28 % The Base Interpreter refers to any `TeX-Format',
29 % because some files are installed in TDS:tex/generic//.
30 %
31 % This work consists of the main source file ltxcmds.dtx
32 % and the derived files
33 % ltxcmds.sty, ltxcmds.pdf, ltxcmds.ins, ltxcmds.drv,
34 % ltxcmds-test1.tex, ltxcmds-test-gobble.tex,
35 % ltxcmds-test-ifempty.tex, ltxcmds-test-zapspace.tex,
36 % ltxcmds-test-ifboxempty.tex, ltxcmds-test-nextchar.tex,
37 % ltxcmds-test-carcdr.tex.
38 %
39 % Distribution:
40 % CTAN:macros/latex/contrib/ltxcmds/ltxcmds.dtx
41 % CTAN:macros/latex/contrib/ltxcmds/ltxcmds.pdf
42 %
43 % Unpacking:
44 % (a) If ltxcmds.ins is present:
45 % tex ltxcmds.ins
46 % (b) Without ltxcmds.ins:
47 % tex ltxcmds.dtx
48 % (c) If you insist on using LaTeX
49 % latex \let\install=y\input{ltxcmds.dtx}
50 % (quote the arguments according to the demands of your shell)
51 %
52 % Documentation:
53 % (a) If ltxcmds.drv is present:
54 % latex ltxcmds.drv
55 % (b) Without ltxcmds.drv:
56 % latex ltxcmds.dtx; ...
57 % The class ltxdoc loads the configuration file ltxdoc.cfg
58 % if available. Here you can specify further options, e.g.
59 % use A4 as paper format:
60 % \PassOptionsToClass{a4paper}{article}
61 %
62 % Programm calls to get the documentation (example):
63 % pdflatex ltxcmds.dtx
64 % makeindex -s gind.ist ltxcmds.idx
65 % pdflatex ltxcmds.dtx
66 % makeindex -s gind.ist ltxcmds.idx
67 % pdflatex ltxcmds.dtx
68 %
69 % Installation:
70 % TDS:tex/generic/ltxcmds/ltxcmds.sty
71 % TDS:doc/latex/ltxcmds/ltxcmds.pdf
72 % TDS:source/latex/ltxcmds/ltxcmds.dtx
73 %
74 %<*ignore>
75 \begingroup
76 \catcode123=1 %
77 \catcode125=2 %
78 \def\x{LaTeX2e}%
79 \expandafter\endgroup
80 \ifcase 0\ifx\install y1\fi\expandafter
81 \ifx\csname processbatchFile\endcsname\relax\else1\fi
82 \ifx\fmtname\x\else 1\fi\relax
83 \else\csname fi\endcsname
84 %</ignore>
85 %<*install>
86 \input docstrip.tex
87 \Msg{************************************************************************}
88 \Msg{* Installation}
89 \Msg{* Package: ltxcmds 2023-12-04 v1.26 LaTeX kernel commands for general use (HO)}
90 \Msg{************************************************************************}
91
92 \keepsilent
93 \askforoverwritefalse
94
95 \let\MetaPrefix\relax
96 \preamble
97
98 This is a generated file.
99
100 Project: ltxcmds
101 Version: 2023-12-04 v1.26
102
103 Copyright (C)
104 2009-2011 Heiko Oberdiek
105 2016-2023 Oberdiek Package Support Group
106
107 This work may be distributed and/or modified under the
108 conditions of the LaTeX Project Public License, either
109 version 1.3c of this license or (at your option) any later
110 version. This version of this license is in
111 https://www.latex-project.org/lppl/lppl-1-3c.txt
112 and the latest version of this license is in
113 https://www.latex-project.org/lppl.txt
114 and version 1.3 or later is part of all distributions of
115 LaTeX version 2005/12/01 or later.
116
117 This work has the LPPL maintenance status "maintained".
118
119 The Current Maintainers of this work are
120 Heiko Oberdiek and the Oberdiek Package Support Group
121 https://github.com/ho-tex/ltxcmds/issues
122
123
124 The Base Interpreter refers to any `TeX-Format',
125 because some files are installed in TDS:tex/generic//.
126
127 This work consists of the main source file ltxcmds.dtx
128 and the derived files
129 ltxcmds.sty, ltxcmds.pdf, ltxcmds.ins, ltxcmds.drv,
130 ltxcmds-test1.tex, ltxcmds-test-gobble.tex,
131 ltxcmds-test-ifempty.tex, ltxcmds-test-zapspace.tex,
132 ltxcmds-test-ifboxempty.tex, ltxcmds-test-nextchar.tex,
133 ltxcmds-test-carcdr.tex.
134
135 \endpreamble
136 \let\MetaPrefix\DoubleperCent
137
138 \generate{%
139 \file{ltxcmds.ins}{\from{ltxcmds.dtx}{install}}%
140 \file{ltxcmds.drv}{\from{ltxcmds.dtx}{driver}}%
141 \usedir{tex/generic/ltxcmds}%
142 \file{ltxcmds.sty}{\from{ltxcmds.dtx}{package}}%
143 }
144
145 \catcode32=13\relax% active space
146 \let =\space%
147 \Msg{************************************************************************}
148 \Msg{*}
149 \Msg{* To finish the installation you have to move the following}
150 \Msg{* file into a directory searched by TeX:}
151 \Msg{*}
152 \Msg{* ltxcmds.sty}
153 \Msg{*}
154 \Msg{* To produce the documentation run the file `ltxcmds.drv'}
155 \Msg{* through LaTeX.}
156 \Msg{*}
157 \Msg{* Happy TeXing!}
158 \Msg{*}
159 \Msg{************************************************************************}
160
161 \endbatchfile
162 %</install>
163 %<*ignore>
164 \fi
165 %</ignore>
166 %<*driver>
167 \NeedsTeXFormat{LaTeX2e}
168 \ProvidesFile{ltxcmds.drv}%
169 [2023-12-04 v1.26 LaTeX kernel commands for general use (HO)]%
170 \documentclass{ltxdoc}
171 \usepackage{holtxdoc}[2011/11/22]
172 \usepackage{zref-savepos}
173 \usepackage{paralist}
174 \hfuzz=1pt
175 \begin{document}
176 \DocInput{ltxcmds.dtx}%
177 \end{document}
178 %</driver>
179 % \fi
180 %
181 %
182 %
183 % \GetFileInfo{ltxcmds.drv}
184 %
185 % \title{The \xpackage{ltxcmds} package}
186 % \date{2023-12-04 v1.26}
187 % \author{Heiko Oberdiek\thanks
188 % {Please report any issues at \url{https://github.com/ho-tex/ltxcmds/issues}}}
189 %
190 % \maketitle
191 %
192 % \begin{abstract}
193 % The package \xpackage{ltxcmds} exports some utility macros
194 % from the \LaTeX\ kernel into a separate namespace and
195 % also provides them for other formats such as plain-\TeX.
196 % \end{abstract}
197 %
198 % \tableofcontents
199 %
200 % \newcounter{to}
201 % \renewcommand*{\theto}{to\arabic{to}}
202 % \newlength\tolength
203 % \tolength=\dimexpr .5\linewidth+\oddsidemargin+1in+15mm\relax
204 % \newcommand*{\TO}{^^A
205 % \quad
206 % \stepcounter{to}^^A
207 % \zsavepos\theto
208 % \ifdim\zposx\theto sp>0pt
209 % \ifdim\zposx\theto sp<\tolength
210 % \kern\dimexpr\tolength-\zposx\theto sp\relax
211 % \fi
212 % \fi
213 % $\rightarrow$\quad
214 % \ignorespaces
215 % }
216 %
217 % \section{Documentation}
218 %
219 % \subsection{Introduction}
220 %
221 % Many of my packages also support other formats such as plain-\TeX.
222 % Because I am rather familiar with the utility macros from
223 % \LaTeX's kernel (e.g. \cs{@gobble}, \cs{@firstoftwo}), I found
224 % myself rewriting them again and again, because they are lacking
225 % in plain-\TeX.
226 %
227 % Therefore this package provides often used macros and similar
228 % ones with the name prefix \cs{ltx@}. This avoids also faulty
229 % redefinitions. I remember an example where a package redefined
230 % \cs{@firstoftwo} with forgetting \cs{long}.
231 %
232 % \subsection{Numbers}
233 %
234 % \begin{declcs}{ltx@zero} \TO 0\\
235 % \cs{ltx@one} \TO 1\\
236 % \cs{ltx@two} \TO 2\\
237 % \cs{ltx@cclv} \TO 255\\
238 % \cs{ltx@minusone} \TO -1
239 % \end{declcs}
240 % These commands are numbers 0, 1, 2, 255 and -1. They are not digits
241 % and a space is not gobbled afterwards. Macro \cs{ltx@minusone}
242 % is available since version 2010/12/12 v1.15.
243 %
244 % \subsection{Scratch registers}
245 %
246 % Following the conventions of \hologo{plainTeX} and \hologo{LaTeX}
247 % the first ten registers are free to use. Even numbered registers
248 % are for local, odd numbered for global use.
249 %
250 % \begin{declcs}{ltx@(Loc,Glob)(Toks,Dimen,Skip)(A,B,C,D,E)}
251 % \end{declcs}
252 % The name consists of the prefix \cs{ltx@}, then
253 % \texttt{Loc} or \texttt{Glob} for local or global usage follows.
254 % The register type is given by \texttt{Toks} for token register,
255 % \texttt{Dimen} for dimen register and \texttt{Skip} for skip
256 % register. As last part the registers are numbered from \texttt{A}
257 % to \texttt{E}. Example: \cs{ltx@LocToksA}.
258 %
259 % Since 2011/04/14 v1.19.
260 %
261 % \subsection{Argument killers}
262 %
263 % \begin{declcs}{ltx@gobble} \M{1} \TO\\
264 % \cs{ltx@gobbletwo} \M{1} \M{2} \TO\\
265 % \cs{ltx@gobblethree} \M{1} \M{2} \M{3} \TO\\
266 % \cs{ltx@gobblefour} \M{1} \M{2} \M{3} \M{4} \TO
267 % \end{declcs}
268 %
269 % \begin{declcs}{ltx@GobbleNum} \M{num} \M{1} \M{2} \dots\space
270 % \M{\meta{num}} \TO
271 % \end{declcs}
272 % The first argument \meta{num} of macro \cs{ltx@GobbleNum} specifies,
273 % how many following arguments are eaten. Macro \cs{ltx@GobbleNum}
274 % is expandable in exact two expansion steps.
275 %
276 % \subsection{Argument grabbers}
277 %
278 % \begin{declcs}{ltx@firstofone} \M{1} \TO \meta{1}\\[1ex]
279 % \cs{ltx@firstoftwo} \M{1} \M{2} \TO \meta{1}\\
280 % \cs{ltx@secondoftwo} \M{1} \M{2} \TO \meta{2}\\[1ex]
281 % \cs{ltx@firstofthree} \M{1} \M{2} \M{3} \TO \meta{1}\\
282 % \cs{ltx@secondofthree} \M{1} \M{2} \M{3} \TO \meta{2}\\
283 % \cs{ltx@thirdofthree} \M{1} \M{2} \M{3} \TO \meta{3}\\
284 % \cs{ltx@firstoffour} \M{1} \M{2} \M{3} \M{4} \TO \meta{1}\\
285 % \cs{ltx@secondoffour} \M{1} \M{2} \M{3} \M{4} \TO \meta{2}\\
286 % \cs{ltx@thirdoffour} \M{1} \M{2} \M{3} \M{4} \TO \meta{3}\\
287 % \cs{ltx@fourthoffour} \M{1} \M{2} \M{3} \M{4} \TO \meta{4}
288 % \end{declcs}
289 % Macros \cs{ltx@firstofthree}, \cs{ltx@secondofthree}
290 % and \cs{ltx@thirdofthree} were added in version
291 % 2010/11/12 v1.11.
292 % Macros \cs{ltx@firstoffour}, \dots, \cs{ltx@fourthoffour}
293 % were added in version 2011/02/04 v1.16.
294 %
295 % \subsection{List helpers}
296 %
297 % \begin{declcs}{ltx@carzero} \dots\ \cs{@nil} \TO\\
298 % \cs{ltx@cdrzero} \dots\ \cs{@nil} \TO \dots
299 % \end{declcs}
300 %
301 % \begin{declcs}{ltx@car} \M{1} \dots\ \cs{@nil} \TO \meta{1}\\
302 % \cs{ltx@cdr} \M{1} \dots\ \cs{@nil} \TO \dots
303 % \end{declcs}
304 %
305 % \begin{declcs}{ltx@cartwo} \M{1} \M{2} \dots\ \cs{@nil}
306 % \TO \meta{1}\meta{2}\\
307 % \cs{ltx@carsecond} \M{1} \M{2} \dots\ \cs{@nil} \TO \meta{2}\\
308 % \cs{ltx@cdrtwo} \M{1} \M{2} \dots\ \cs{@nil} \TO \dots
309 % \end{declcs}
310 %
311 % \begin{declcs}{ltx@carthree} \M{1} \M{2} \M{3} \dots\ \cs{@nil}
312 % \TO \meta{1}\meta{2}\meta{3}\\
313 % \cs{ltx@carthird} \M{1} \M{2} \M{3} \dots\ \cs{@nil}
314 % \TO \meta{3}\\
315 % \cs{ltx@cdrthree} \M{1} \M{2} \M{3} \dots\ \cs{@nil} \TO \dots
316 % \end{declcs}
317 %
318 % \begin{declcs}{ltx@carfour} \M{1} \M{2} \M{3} \M{4} \dots\ \cs{@nil}
319 % \TO \meta{1}\meta{2}\meta{3}\meta{4}\\
320 % \cs{ltx@carfourth} \M{1} \M{2} \M{3} \M{4} \dots\ \cs{@nil}
321 % \TO \meta{4}\\
322 % \cs{ltx@cdrfour} \M{1} \M{2} \M{3} \M{4} \dots\ \cs{@nil} \TO \dots
323 % \end{declcs}
324 %
325 % \begin{declcs}{ltx@CarNum} \M{num} \M{1} \dots\ \M{\meta{num}}
326 % \M{\meta{num}+1} \dots\ \cs{@nil}\\
327 % \TO \M{1} \dots\ \M{\meta{num}} \dots\\
328 % \cs{ltx@CarNumth} \M{num} \M{1} \dots\ \M{\meta{num}}
329 % \M{\meta{num}+1} \dots\ \cs{@nil}\\
330 % \TO \M{\meta{num}} \dots\\
331 % \cs{ltx@CdrNum} \M{num} \M{1} \dots\ \M{\meta{num}}
332 % \M{\meta{num}+1} \dots\ \cs{@nil}\\
333 % \TO \M{\meta{num}+1} \dots
334 % \end{declcs}
335 %
336 % Macros with uppercase letters are expandable in two expansion steps.
337 % Changes in version 2023-12-04 v1.26:
338 % \begin{itemize}
339 % \item
340 % Macros \cs{ltx@carsecond}, \cs{ltx@carthird}, \cs{ltx@carfourth},
341 % \cs{ltx@CarNumth} added.
342 % \item
343 % Macros \cs{ltx@cdr}, \cs{ltx@cdrtwo}, \cs{ltx@cdrthree}, \cs{ltx@cdrfour},
344 % \cs{ltx@CdrNum} are expandable in two expansion steps and retain
345 % spaces and braces after the first gobbled arguments.
346 % \end{itemize}
347 %
348 % \subsection{Tail recursion}
349 %
350 % \begin{declcs}{ltx@ReturnAfterFi} \M{1} \cs{fi} \TO \cs{fi} \meta{1}\\
351 % \cs{ltx@ReturnAfterElseFi} \M{1} \cs{else} \M{2} \cs{fi}
352 % \TO \cs{fi} \meta{1}
353 % \end{declcs}
354 %
355 % \subsection{Empty macro}
356 %
357 % \begin{declcs}{ltx@empty} \TO
358 % \end{declcs}
359 %
360 % \subsection{Characters}
361 %
362 % \begin{declcs}{ltx@space} \TO \verb*| |\\
363 % \cs{ltx@percentchar} \TO \texttt{\%}\\
364 % \cs{ltx@backslashchar} \TO
365 % \makeatletter\texttt{\@backslashchar}\\
366 % \cs{ltx@hashchar} \TO \texttt{\#}\qquad(since v1.7)\\
367 % \cs{ltx@leftbracechar} \TO \texttt{\textbraceleft}\qquad(since v1.8)\\
368 % \cs{ltx@rightbracechar} \TO \texttt{\textbraceright}\qquad(since v1.8)
369 % \end{declcs}
370 %
371 % \subsection{Boolean switch}
372 %
373 % \begin{declcs}{ltx@newif} \M{cmd}
374 % \end{declcs}
375 % \cs{ltx@newif} defines a new boolean switch \meta{cmd} like \cs{newif}.
376 % Unlike \plainTeX's \cs{newif}, \cs{ltx@newif} is not \cs{outer}.
377 % The command \meta{cmd} must start with the two characters |if|.
378 %
379 % \begin{declcs}{ltx@newglobalif} \M{cmd}
380 % \end{declcs}
381 % \cs{ltx@newglobalif} defines a new boolean switch \meta{cmd}
382 % like \cs{ltx@newif}. However the switch setting commands,
383 % \meta{cmd} without the prefix |if| and followed by |true| or |false|
384 % are acting globally.
385 %
386 % \subsection{Command definitions}
387 %
388 % \begin{declcs}{ltx@ifundefined} \M{cmd} \M{yes} \M{no}
389 % \end{declcs}
390 % If \eTeX\ is available, \cs{ifcsname} is used that does
391 % not have the side effect of defining undefined commands
392 % with meaning of \cs{relax}. This command is always expandable.
393 % Change in version 1.1: Also the meaning \cs{relax} is
394 % always considered ``undefined''.
395 %
396 % \begin{declcs}{ltx@IfUndefined} \M{cmd} \M{yes} \M{no}
397 % \end{declcs}
398 % If \eTeX\ is available, \cs{ifcsname} is used that does
399 % not have the side effect of defining undefined commands
400 % with meaning of \cs{relax}. Also it always checks for
401 % the meaning of \cs{relax} and considers this as undefined.
402 % This macro is not expandable without \eTeX.
403 %
404 % \begin{declcs}{ltx@LocalExpandAfter}
405 % \end{declcs}
406 % It expands the token after the next token but in a local
407 % context. That is the difference to \cs{expandafter}.
408 % The local context discards the side effect of \cs{csname}
409 % and let the command undefined after the expansion step.
410 %
411 % \subsection{Stripping}
412 %
413 % \begin{declcs}{ltx@RemovePrefix}\\
414 % \cs{ltx@StripPrefix}
415 % \end{declcs}
416 % All tokens up to and including the next available character
417 % `\textgreater' are thrown away. Usually it is used to strip
418 % the first part of the output of the commands \cs{meaning}
419 % or \cs{pdflastmatch}. Macro \cs{ltx@RemovePrefix}
420 % has the same meaning as \LaTeX's \cs{strip@prefix}, whereas
421 % macro \cs{ltx@StripPrefix} expands the next token
422 % once before stripping the prefix.
423 %
424 % \begin{declcs}{ltx@onelevel@sanitize} \M{macro}
425 % \end{declcs}
426 % Macro \cs{ltx@onelevel@sanitize} provides \hologo{LaTeX}'s
427 % \cs{@onelevel@sanitize}. The macro is expanded once and
428 % the contents is converted to characters with catcode 12 (other)
429 % and space tokens with catcode 10 (space). Then then sanitized
430 % contents is stored into the macro again. Since version 1.12.
431 %
432 % \subsection{File management}
433 %
434 % All macros in this section are expandable like
435 % the counterparts of the \LaTeX\ kernel. Also they
436 % can be used after the preamble.
437 %
438 % \subsubsection{File extensions}
439 %
440 % \begin{declcs}{ltx@clsextension}\\
441 % \cs{ltx@pkgextension}
442 % \end{declcs}
443 % Macros \cs{ltx@clsextension} and \cs{ltx@styextension}
444 % stores the strings |cls| and |sty|. In opposite to \hologo{LaTeX}'s
445 % \cs{@clsextension} and \cs{@styextension} they can also be
446 % used after |\begin{document}|.
447 %
448 % \subsubsection{Load check}
449 %
450 % \begin{declcs}{ltx@ifclassloaded} \M{class} \M{yes} \M{no}\\
451 % \cs{ltx@ifpackageloaded} \M{package} \M{yes} \M{no}
452 % \end{declcs}
453 % Macros \cs{ltx@ifclassloaded}\slash\cs{ltx@ifpackageloaded}
454 % execute \meta{yes}, if the \meta{class} or \meta{package} is loaded,
455 % otherwise \meta{no} is called.
456 % Both \meta{class} and \meta{package} are specified without
457 % extension. The macros can also be used after |\begin{document}|.
458 %
459 % \begin{declcs}{ltx@iffileloaded} \M{file} \M{yes} \M{no}
460 % \end{declcs}
461 % If \LaTeX's \cs{ProvidesFile} macro was called before
462 % using \meta{file} as argument, then \cs{ltx@iffileloaded}
463 % calls \meta{yes}, otherwise \meta{no}.
464 % Therefore it is possible
465 % that the \meta{file} is loaded, but \meta{no} is executed because
466 % of a missing \cs{ProvidesFile}. The \LaTeX\ kernel does not have
467 % a counterpart of \cs{ltx@iffileloaded}.
468 %
469 % Note that the file name used in \cs{ProvidesFile} and
470 % \cs{ltx@iffileloaded} must match. For example, if \TeX's
471 % default extension \xext{tex} was given in the first command,
472 % then it must also specified in the latter command and vice versa.
473 %
474 % \subsubsection{Version date check}
475 %
476 % \begin{declcs}{ltx@ifclasslater} \M{class} \M{date} \M{yes} \M{no}\\
477 % \cs{ltx@ifpackagelater} \M{package} \M{date} \M{yes} \M{no}\\
478 % \cs{ltx@iffilelater} \M{file} \M{date} \M{yes} \M{no}
479 % \end{declcs}
480 % If a \cs{ProvidesClass}\slash\cs{ProvidesPackage}\slash
481 % \cs{ProvidesFile} command with exact the same class\slash package\slash
482 % file was executed before with an optional
483 % argument that starts with a \LaTeX\ version date, then
484 % this version date is compared with the argument \meta{date}.
485 % If they are equal or if the version date is the later date,
486 % then \meta{yes} is called. In all other cases \meta{no} is executed.
487 %
488 % A \LaTeX\ date has the format |YYYY/MM/DD| with |YYYY| as year
489 % with four digits, |MM| as month with two digits and |DD| as day
490 % with two digits. If \pdfTeX's \cs{pdfmatch} is available, then
491 % it is used to detect the version date, to reject invalid
492 % date formats and to reject some invalid dates.
493 % Dates before 1994/01/01 are always invalid, because version
494 % dates are introduced with \LaTeXe\ in 1994.
495 %
496 % \subsection{Macro additions}
497 %
498 % \begin{declcs}{ltx@GlobalAppendToMacro} \M{cmd} \M{addition}\\
499 % \cs{ltx@LocalAppendToMacro} \M{cmd} \M{addition}
500 % \end{declcs}
501 % The \meta{addition} is appended to the parameterless macro \meta{cmd}.
502 % If \meta{cmd} is undefined or has the meaning \cs{relax}, then
503 % it will be initialized as empty macro beforehand. Due to a bug \meta{addition}
504 % must not contain \cs{par} before version 2010/10/25 v1.9.
505 %
506 % \begin{declcs}{ltx@GlobalPrependToMacro} \M{cmd} \M{addition}\\
507 % \cs{ltx@LocalPrependToMacro} \M{cmd} \M{addition}
508 % \end{declcs}
509 % The \meta{addition} is prepended to the parameterless macro \meta{cmd}.
510 % If \meta{cmd} is undefined or has the meaning \cs{relax}, then
511 % it will be initialized as empty macro beforehand. The macros
512 % were added in version 2011/08/22 v1.21.
513 %
514 % \subsection{Next character detection}
515 %
516 % \begin{declcs}{ltx@ifnextchar} \M{char} \M{yes} \M{no}
517 % \end{declcs}
518 % If next character is \meta{char} then \meta{yes} is called,
519 % otherwise \meta{no}. The character is not removed.
520 % Spaces are silently removed when looking for \meta{char}
521 % as \hologo{LaTeX}'s version \cs{kernel@ifnextchar} does.
522 % But there are also small differences:
523 % \begin{itemize}
524 % \item The space can be used as \meta{char}. In this case
525 % optional spaces before \meta{char} are not supported of course.
526 % \item If the optional space is a command that is a character
527 % (defined by \cs{let} or \cs{futurelet}), then
528 % \cs{kernel@ifnextchar} breaks with an \hologo{TeX} error.
529 % \cs{ltx@ifnextchar} silently removes this token as
530 % optional space.
531 % \end{itemize}
532 % Since 2010/03/01 v1.3.
533 %
534 % \begin{declcs}{ltx@ifnextchar@nospace} \M{char} \M{yes} \M{no}
535 % \end{declcs}
536 % Macro \cs{ltx@ifnextchar@nospace} behaves like
537 % macro \cs{ltx@ifnextchar} with the exception that
538 % optional spaces are not supported before \meta{char}.
539 % Since 2011/04/14 v1.19.
540 %
541 % \subsection{\cs{ltx@leavevmode}, \cs{ltx@mbox}}
542 %
543 % \begin{declcs}{ltx@leavevmode}
544 % \end{declcs}
545 % Macro \cs{ltx@leavevmode} calls \hologo{pdfTeX}'s \cs{quitvmode}.
546 % Otherwise \cs{leavevmode} is used and defined if it is necessary.
547 %
548 % \begin{declcs}{ltx@mbox}
549 % \end{declcs}
550 % Macro \cs{ltx@mbox} reimplements \cs{mbox} with two changes.
551 % Instead of \cs{leavevmode} it uses \cs{ltx@leavevmode} and
552 % stops right after \cs{hbox}. Especially it does not grab
553 % the argument and allows the extended syntax of \cs{hbox}.
554 %
555 % \subsection{Expandable test for emptiness}
556 %
557 % \begin{declcs}{ltx@ifempty} \M{stuff} \M{yes} \M{no}
558 % \end{declcs}
559 % Macro \cs{ltx@ifempty} checks in exact two expansion steps
560 % whether \meta{stuff}
561 % is empty or contains token. Depending on the result
562 % \meta{yes} or \meta{no} is executed. The token in \meta{stuff}
563 % may contain \cs{par} and unmatched conditionals (\cs{if}, \cs{else},
564 % \cs{fi}, \dots). Since version 2010/11/12 v1.11.
565 %
566 % \begin{declcs}{ltx@ifblank} \M{stuff} \M{yes} \M{no}
567 % \end{declcs}
568 % Macro \cs{ltx@ifblank} tests in exact two expansion steps
569 % if \meta{stuff} is empty or contain only blank spaces.
570 % In this case argument \meta{yes} is called. If \meta{stuff}
571 % contains other tokens than spaces then \meta{no} is executed.
572 % Since version 2010/12/04 v1.13.
573 %
574 % \subsection{Stripping spaces}
575 %
576 % \begin{declcs}{ltx@zapspace} \M{stuff}
577 % \end{declcs}
578 % Macro \cs{ltx@zapspace} strips spaces from \meta{stuff}
579 % that are not hidden inside curly braces. Like \hologo{LaTeX}'s
580 % \cs{zap@space} it is expandable. Differences:
581 % \begin{itemize}
582 % \item
583 % Syntax: \cs{zap@space} also expects a space token
584 % and \cs{@empty} after \meta{stuff}.
585 % \item
586 % Macro \cs{ltx@zapspace} is expandable in exact two
587 % expansion steps.
588 % \item
589 % Macro \cs{ltx@zapspace} always retains curly braces.
590 % \item
591 % Macro \cs{zap@space} has a bug. It stops stripping spaces
592 % after a token group in curly braces if the first two tokens
593 % inside the group are equal.
594 % \item
595 % Macro \cs{ltx@zapspace} also works with \cs{par}
596 % and conditionals (\cs{if}, \cs{else}, \cs{fi}, \dots).
597 % \end{itemize}
598 % Macro \cs{ltx@zapspace} is available since version
599 % 2010/12/07 v1.14.
600 %
601 % \subsection{Check for emptiness of boxes}
602 %
603 % \begin{declcs}{ltx@IfBoxEmpty} \M{box register number}
604 % \M{yes} \M{no}
605 % \end{declcs}
606 % Macro \cs{ltx@IfBoxEmpty} calls \meta{yes} if
607 % the box exists (\cs{ifvoid} returns false) and the box
608 % does not contain any content. Otherwise if the box
609 % is void or contains something, then \meta{no} is executed.
610 % Thus being empty means that the box exists and is either
611 % an \cs{hbox} or a \cs{vbox} and may even have dimensions other than
612 % 0.0\,pt, but the box does not contain anything.
613 % Macro \cs{ltx@IfBoxEmpty} is available since 2010/02/04 v1.16.
614 %
615 % \begin{declcs}{ltx@IfBoxVoidOrEmpty} \M{box register number}
616 % \M{yes} \M{no}
617 % \end{declcs}
618 % Macro \cs{ltx@IfBoxVoidOrEmpty} calls \meta{yes} if
619 % the box is either void or does not contain any content.
620 % Otherwise \meta{no} is executed.
621 % Macro \cs{ltx@IfBoxVoidOrEmpty} is available since 2010/02/04 v1.16.
622 %
623 % \StopEventually{
624 % }
625 %
626 % \section{Implementation}
627 %
628 % \subsection{Identification}
629 %
630 % \begin{macrocode}
631 %<*package>
632 % \end{macrocode}
633 % Reload check, especially if the package is not used with \LaTeX.
634 % \begin{macrocode}
635 \begingroup\catcode61\catcode48\catcode32=10\relax%
636 \catcode13=5 % ^^M
637 \endlinechar=13 %
638 \catcode35=6 % #
639 \catcode39=12 % '
640 \catcode44=12 % ,
641 \catcode45=12 % -
642 \catcode46=12 % .
643 \catcode58=12 % :
644 \catcode64=11 % @
645 \catcode123=1 % {
646 \catcode125=2 % }
647 \expandafter\let\expandafter\x\csname [email protected]\endcsname
648 \ifx\x\relax % plain-TeX, first loading
649 \else
650 \def\empty{}%
651 \ifx\x\empty % LaTeX, first loading,
652 % variable is initialized, but \ProvidesPackage not yet seen
653 \else
654 \expandafter\ifx\csname PackageInfo\endcsname\relax
655 \def\x#1#2{%
656 \immediate\write-1{Package #1 Info: #2.}%
657 }%
658 \else
659 \def\x#1#2{\PackageInfo{#1}{#2, stopped}}%
660 \fi
661 \x{ltxcmds}{The package is already loaded}%
662 \aftergroup\endinput
663 \fi
664 \fi
665 \endgroup%
666 % \end{macrocode}
667 % Package identification:
668 % \begin{macrocode}
669 \begingroup\catcode61\catcode48\catcode32=10\relax%
670 \catcode13=5 % ^^M
671 \endlinechar=13 %
672 \catcode35=6 % #
673 \catcode39=12 % '
674 \catcode40=12 % (
675 \catcode41=12 % )
676 \catcode44=12 % ,
677 \catcode45=12 % -
678 \catcode46=12 % .
679 \catcode47=12 % /
680 \catcode58=12 % :
681 \catcode64=11 % @
682 \catcode91=12 % [
683 \catcode93=12 % ]
684 \catcode123=1 % {
685 \catcode125=2 % }
686 \expandafter\ifx\csname ProvidesPackage\endcsname\relax
687 \def\x#1#2#3[#4]{\endgroup
688 \immediate\write-1{Package: #3 #4}%
689 \xdef#1{#4}%
690 }%
691 \else
692 \def\x#1#2[#3]{\endgroup
693 #2[{#3}]%
694 \ifx#1\@undefined
695 \xdef#1{#3}%
696 \fi
697 \ifx#1\relax
698 \xdef#1{#3}%
699 \fi
700 }%
701 \fi
702 \expandafter\x\csname [email protected]\endcsname
703 \ProvidesPackage{ltxcmds}%
704 [2023-12-04 v1.26 LaTeX kernel commands for general use (HO)]%
705 % \end{macrocode}
706 %
707 % \begin{macrocode}
708 \begingroup\catcode61\catcode48\catcode32=10\relax%
709 \catcode13=5 % ^^M
710 \endlinechar=13 %
711 \catcode123=1 % {
712 \catcode125=2 % }
713 \catcode64=11 % @
714 \def\x{\endgroup
715 \expandafter\edef\csname LTXcmds@AtEnd\endcsname{%
716 \endlinechar=\the\endlinechar\relax
717 \catcode13=\the\catcode13\relax
718 \catcode32=\the\catcode32\relax
719 \catcode35=\the\catcode35\relax
720 \catcode61=\the\catcode61\relax
721 \catcode64=\the\catcode64\relax
722 \catcode123=\the\catcode123\relax
723 \catcode125=\the\catcode125\relax
724 }%
725 }%
726 \x\catcode61\catcode48\catcode32=10\relax%
727 \catcode13=5 % ^^M
728 \endlinechar=13 %
729 \catcode35=6 % #
730 \catcode64=11 % @
731 \catcode123=1 % {
732 \catcode125=2 % }
733 \def\TMP@EnsureCode#1#2{%
734 \edef\LTXcmds@AtEnd{%
735 \LTXcmds@AtEnd
736 \catcode#1=\the\catcode#1\relax
737 }%
738 \catcode#1=#2\relax
739 }
740 \TMP@EnsureCode{36}{3}% $
741 \TMP@EnsureCode{38}{4}% &
742 \TMP@EnsureCode{40}{12}% (
743 \TMP@EnsureCode{41}{12}% )
744 \TMP@EnsureCode{45}{12}% -
745 \TMP@EnsureCode{46}{12}% .
746 \TMP@EnsureCode{47}{12}% /
747 \TMP@EnsureCode{60}{12}% <
748 \TMP@EnsureCode{62}{12}% >
749 \TMP@EnsureCode{91}{12}% [
750 \TMP@EnsureCode{96}{12}% `
751 \TMP@EnsureCode{93}{12}% ]
752 \TMP@EnsureCode{94}{12}% ^ (superscript) (!)
753 \TMP@EnsureCode{124}{12}% |
754 \edef\LTXcmds@AtEnd{\LTXcmds@AtEnd\noexpand\endinput}
755 % \end{macrocode}
756 %
757 % \subsection{Numbers}
758 %
759 % \begin{macro}{\ltx@zero}
760 % \begin{macrocode}
761 \chardef\ltx@zero=0 %
762 % \end{macrocode}
763 % \end{macro}
764 % \begin{macro}{\ltx@one}
765 % \begin{macrocode}
766 \chardef\ltx@one=1 %
767 % \end{macrocode}
768 % \end{macro}
769 % \begin{macro}{\ltx@two}
770 % \begin{macrocode}
771 \chardef\ltx@two=2 %
772 % \end{macrocode}
773 % \end{macro}
774 % \begin{macro}{\ltx@active}
775 % \begin{macrocode}
776 \chardef\ltx@active=13 %
777 % \end{macrocode}
778 % \end{macro}
779 % \begin{macro}{\ltx@cclv}
780 % \begin{macrocode}
781 \chardef\ltx@cclv=255 %
782 % \end{macrocode}
783 % \end{macro}
784 %
785 % \begin{macro}{\ltx@minusone}
786 % \begin{macrocode}
787 \def\ltx@minusone{%
788 -\ltx@one
789 }
790 % \end{macrocode}
791 % \end{macro}
792 %
793 % \subsection{Scratch registers}
794 %
795 % \begin{macro}{\ltx@LocToksA}
796 % \begin{macrocode}
797 \toksdef\ltx@LocToksA=0 %
798 % \end{macrocode}
799 % \end{macro}
800 % \begin{macro}{\ltx@LocToksB}
801 % \begin{macrocode}
802 \toksdef\ltx@LocToksB=2 %
803 % \end{macrocode}
804 % \end{macro}
805 % \begin{macro}{\ltx@LocToksC}
806 % \begin{macrocode}
807 \toksdef\ltx@LocToksC=4 %
808 % \end{macrocode}
809 % \end{macro}
810 % \begin{macro}{\ltx@LocToksD}
811 % \begin{macrocode}
812 \toksdef\ltx@LocToksD=6 %
813 % \end{macrocode}
814 % \end{macro}
815 % \begin{macro}{\ltx@LocToksE}
816 % \begin{macrocode}
817 \toksdef\ltx@LocToksE=8 %
818 % \end{macrocode}
819 % \end{macro}
820 %
821 % \begin{macro}{\ltx@GlobToksA}
822 % \begin{macrocode}
823 \toksdef\ltx@GlobToksA=1 %
824 % \end{macrocode}
825 % \end{macro}
826 % \begin{macro}{\ltx@GlobToksB}
827 % \begin{macrocode}
828 \toksdef\ltx@GlobToksB=3 %
829 % \end{macrocode}
830 % \end{macro}
831 % \begin{macro}{\ltx@GlobToksC}
832 % \begin{macrocode}
833 \toksdef\ltx@GlobToksC=5 %
834 % \end{macrocode}
835 % \end{macro}
836 % \begin{macro}{\ltx@GlobToksD}
837 % \begin{macrocode}
838 \toksdef\ltx@GlobToksD=7 %
839 % \end{macrocode}
840 % \end{macro}
841 % \begin{macro}{\ltx@GlobToksE}
842 % \begin{macrocode}
843 \toksdef\ltx@GlobToksE=9 %
844 % \end{macrocode}
845 % \end{macro}
846 %
847 % \begin{macro}{\ltx@LocDimenA}
848 % \begin{macrocode}
849 \dimendef\ltx@LocDimenA=0 %
850 % \end{macrocode}
851 % \end{macro}
852 % \begin{macro}{\ltx@LocDimenB}
853 % \begin{macrocode}
854 \dimendef\ltx@LocDimenB=2 %
855 % \end{macrocode}
856 % \end{macro}
857 % \begin{macro}{\ltx@LocDimenC}
858 % \begin{macrocode}
859 \dimendef\ltx@LocDimenC=4 %
860 % \end{macrocode}
861 % \end{macro}
862 % \begin{macro}{\ltx@LocDimenD}
863 % \begin{macrocode}
864 \dimendef\ltx@LocDimenD=6 %
865 % \end{macrocode}
866 % \end{macro}
867 % \begin{macro}{\ltx@LocDimenE}
868 % \begin{macrocode}
869 \dimendef\ltx@LocDimenE=8 %
870 % \end{macrocode}
871 % \end{macro}
872 %
873 % \begin{macro}{\ltx@GlobDimenA}
874 % \begin{macrocode}
875 \dimendef\ltx@GlobDimenA=1 %
876 % \end{macrocode}
877 % \end{macro}
878 % \begin{macro}{\ltx@GlobDimenB}
879 % \begin{macrocode}
880 \dimendef\ltx@GlobDimenB=3 %
881 % \end{macrocode}
882 % \end{macro}
883 % \begin{macro}{\ltx@GlobDimenC}
884 % \begin{macrocode}
885 \dimendef\ltx@GlobDimenC=5 %
886 % \end{macrocode}
887 % \end{macro}
888 % \begin{macro}{\ltx@GlobDimenD}
889 % \begin{macrocode}
890 \dimendef\ltx@GlobDimenD=7 %
891 % \end{macrocode}
892 % \end{macro}
893 % \begin{macro}{\ltx@GlobDimenE}
894 % \begin{macrocode}
895 \dimendef\ltx@GlobDimenE=9 %
896 % \end{macrocode}
897 % \end{macro}
898 %
899 % \begin{macro}{\ltx@LocSkipA}
900 % \begin{macrocode}
901 \skipdef\ltx@LocSkipA=0 %
902 % \end{macrocode}
903 % \end{macro}
904 % \begin{macro}{\ltx@LocSkipB}
905 % \begin{macrocode}
906 \skipdef\ltx@LocSkipB=2 %
907 % \end{macrocode}
908 % \end{macro}
909 % \begin{macro}{\ltx@LocSkipC}
910 % \begin{macrocode}
911 \skipdef\ltx@LocSkipC=4 %
912 % \end{macrocode}
913 % \end{macro}
914 % \begin{macro}{\ltx@LocSkipD}
915 % \begin{macrocode}
916 \skipdef\ltx@LocSkipD=6 %
917 % \end{macrocode}
918 % \end{macro}
919 % \begin{macro}{\ltx@LocSkipE}
920 % \begin{macrocode}
921 \skipdef\ltx@LocSkipE=8 %
922 % \end{macrocode}
923 % \end{macro}
924 %
925 % \begin{macro}{\ltx@GlobSkipA}
926 % \begin{macrocode}
927 \skipdef\ltx@GlobSkipA=1 %
928 % \end{macrocode}
929 % \end{macro}
930 % \begin{macro}{\ltx@GlobSkipB}
931 % \begin{macrocode}
932 \skipdef\ltx@GlobSkipB=3 %
933 % \end{macrocode}
934 % \end{macro}
935 % \begin{macro}{\ltx@GlobSkipC}
936 % \begin{macrocode}
937 \skipdef\ltx@GlobSkipC=5 %
938 % \end{macrocode}
939 % \end{macro}
940 % \begin{macro}{\ltx@GlobSkipD}
941 % \begin{macrocode}
942 \skipdef\ltx@GlobSkipD=7 %
943 % \end{macrocode}
944 % \end{macro}
945 % \begin{macro}{\ltx@GlobSkipE}
946 % \begin{macrocode}
947 \skipdef\ltx@GlobSkipE=9 %
948 % \end{macrocode}
949 % \end{macro}
950 %
951 %
952 % \subsection{Argument killers}
953 %
954 % \begin{macro}{\ltx@gobble}
955 % \begin{macrocode}
956 \long\def\ltx@gobble#1{}
957 % \end{macrocode}
958 % \end{macro}
959 % \begin{macro}{\ltx@gobbletwo}
960 % \begin{macrocode}
961 \long\def\ltx@gobbletwo#1#2{}
962 % \end{macrocode}
963 % \end{macro}
964 % \begin{macro}{\ltx@gobblethree}
965 % \begin{macrocode}
966 \long\def\ltx@gobblethree#1#2#3{}
967 % \end{macrocode}
968 % \end{macro}
969 % \begin{macro}{\ltx@gobblefour}
970 % \begin{macrocode}
971 \long\def\ltx@gobblefour#1#2#3#4{}
972 % \end{macrocode}
973 % \end{macro}
974 %
975 % \begin{macro}{\ltx@GobbleNum}
976 % \begin{macrocode}
977 \def\ltx@GobbleNum#1{%
978 \romannumeral
979 \csname ltx@zero%
980 \expandafter\LTXcmds@GobbleNum
981 \romannumeral\LTXcmds@num{#1}000{m\endcsname}%
982 }
983 % \end{macrocode}
984 % \end{macro}
985 % \begin{macro}{\LTXcmds@GobbleNum}
986 % \begin{macrocode}
987 \def\LTXcmds@GobbleNum#1{%
988 \csname LTXcmds@G#1\LTXcmds@GobbleNum
989 }
990 % \end{macrocode}
991 % \end{macro}
992 % \begin{macro}{\LTXcmds@Gm}
993 % \begin{macrocode}
994 \long\def\LTXcmds@Gm#1{%
995 \endcsname
996 }
997 % \end{macrocode}
998 % \end{macro}
999 %
1000 % \subsection{Argument grabbers}
1001 %
1002 % \begin{macro}{\ltx@firstofone}
1003 % \begin{macrocode}
1004 \long\def\ltx@firstofone#1{#1}
1005 % \end{macrocode}
1006 % \end{macro}
1007 % \begin{macro}{\ltx@firstoftwo}
1008 % \begin{macrocode}
1009 \long\def\ltx@firstoftwo#1#2{#1}
1010 % \end{macrocode}
1011 % \end{macro}
1012 % \begin{macro}{\ltx@secondoftwo}
1013 % \begin{macrocode}
1014 \long\def\ltx@secondoftwo#1#2{#2}
1015 % \end{macrocode}
1016 % \end{macro}
1017 %
1018 % \begin{macro}{\ltx@firstofthree}
1019 % \begin{macrocode}
1020 \long\def\ltx@firstofthree#1#2#3{#1}
1021 % \end{macrocode}
1022 % \end{macro}
1023 % \begin{macro}{\ltx@secondofthree}
1024 % \begin{macrocode}
1025 \long\def\ltx@secondofthree#1#2#3{#2}
1026 % \end{macrocode}
1027 % \end{macro}
1028 % \begin{macro}{\ltx@thirdofthree}
1029 % \begin{macrocode}
1030 \long\def\ltx@thirdofthree#1#2#3{#3}%
1031 % \end{macrocode}
1032 % \end{macro}
1033 %
1034 % \begin{macro}{\ltx@firstoffour}
1035 % \begin{macrocode}
1036 \long\def\ltx@firstoffour#1#2#3#4{#1}
1037 % \end{macrocode}
1038 % \end{macro}
1039 % \begin{macro}{\ltx@secondoffour}
1040 % \begin{macrocode}
1041 \long\def\ltx@secondoffour#1#2#3#4{#2}
1042 % \end{macrocode}
1043 % \end{macro}
1044 % \begin{macro}{\ltx@thirdoffour}
1045 % \begin{macrocode}
1046 \long\def\ltx@thirdoffour#1#2#3#4{#3}%
1047 % \end{macrocode}
1048 % \end{macro}
1049 % \begin{macro}{\ltx@fourthoffour}
1050 % \begin{macrocode}
1051 \long\def\ltx@fourthoffour#1#2#3#4{#4}%
1052 % \end{macrocode}
1053 % \end{macro}
1054 %
1055 % \subsection{List helpers}
1056 %
1057 % \begin{macro}{\ltx@carzero}
1058 % \begin{macrocode}
1059 \long\def\ltx@carzero#1\@nil{}%
1060 % \end{macrocode}
1061 % \end{macro}
1062 % \begin{macro}{\LTXcmds@cdrzero}
1063 % \begin{macrocode}
1064 \long\def\LTXcmds@cdrzero#1\@nil{#1}
1065 % \end{macrocode}
1066 % \end{macro}
1067 % \begin{macro}{\ltx@cdrzero}
1068 % \begin{macrocode}
1069 \def\ltx@cdrzero{%
1070 \romannumeral\LTXcmds@cdrzero\ltx@zero
1071 }
1072 % \end{macrocode}
1073 % \end{macro}
1074 %
1075 % \begin{macro}{\ltx@car}
1076 % \begin{macrocode}
1077 \long\def\ltx@car#1#2\@nil{#1}
1078 % \end{macrocode}
1079 % \end{macro}
1080 % \begin{macro}{\ltx@cdr}
1081 % \begin{macrocode}
1082 \long\def\ltx@cdr#1{%
1083 \romannumeral\LTXcmds@cdrzero\ltx@zero
1084 }
1085 % \end{macrocode}
1086 % \end{macro}
1087 %
1088 % \begin{macro}{\ltx@cartwo}
1089 % \begin{macrocode}
1090 \long\def\ltx@cartwo#1#2#3\@nil{#1#2}
1091 % \end{macrocode}
1092 % \end{macro}
1093 % \begin{macro}{\ltx@carsecond}
1094 % \begin{macrocode}
1095 \long\def\ltx@carsecond#1#2#3\@nil{#2}
1096 % \end{macrocode}
1097 % \end{macro}
1098 % \begin{macro}{\ltx@cdrtwo}
1099 % \begin{macrocode}
1100 \long\def\ltx@cdrtwo#1#2{%
1101 \romannumeral\LTXcmds@cdrzero\ltx@zero
1102 }
1103 % \end{macrocode}
1104 % \end{macro}
1105 %
1106 % \begin{macro}{\ltx@carthree}
1107 % \begin{macrocode}
1108 \long\def\ltx@carthree#1#2#3#4\@nil{#1#2#3}
1109 % \end{macrocode}
1110 % \end{macro}
1111 % \begin{macro}{\ltx@carthird}
1112 % \begin{macrocode}
1113 \long\def\ltx@carthird#1#2#3#4\@nil{#3}
1114 % \end{macrocode}
1115 % \end{macro}
1116 % \begin{macro}{\ltx@cdrthree}
1117 % \begin{macrocode}
1118 \long\def\ltx@cdrthree#1#2#3{%
1119 \romannumeral\LTXcmds@cdrzero\ltx@zero
1120 }
1121 % \end{macrocode}
1122 % \end{macro}
1123 %
1124 % \begin{macro}{\ltx@carfour}
1125 % \begin{macrocode}
1126 \long\def\ltx@carfour#1#2#3#4#5\@nil{#1#2#3#4}
1127 % \end{macrocode}
1128 % \end{macro}
1129 % \begin{macro}{\ltx@carfourth}
1130 % \begin{macrocode}
1131 \long\def\ltx@carfourth#1#2#3#4#5\@nil{#4}
1132 % \end{macrocode}
1133 % \end{macro}
1134 % \begin{macro}{\ltx@cdrfour}
1135 % \begin{macrocode}
1136 \long\def\ltx@cdrfour#1#2#3#4{%
1137 \romannumeral\LTXcmds@cdrzero\ltx@zero
1138 }
1139 % \end{macrocode}
1140 % \end{macro}
1141 %
1142 % \begin{macro}{\ltx@CarNum}
1143 % \begin{macrocode}
1144 \def\ltx@CarNum#1{%
1145 \romannumeral
1146 \csname LTXcmds@CarNumFinish%
1147 \expandafter\LTXcmds@CarNum
1148 \romannumeral\LTXcmds@num{#1}000{x\endcsname}%
1149 }
1150 % \end{macrocode}
1151 % \end{macro}
1152 % \begin{macro}{\LTXcmds@CarNum}
1153 % \begin{macrocode}
1154 \def\LTXcmds@CarNum#1{%
1155 \csname LTXcmds@C#1\LTXcmds@CarNum
1156 }
1157 % \end{macrocode}
1158 % \end{macro}
1159 % \begin{macro}{\LTXcmds@Cm}
1160 % \begin{macrocode}
1161 \long\def\LTXcmds@Cm#1#2{%
1162 \endcsname{#1#2}%
1163 }
1164 % \end{macrocode}
1165 % \end{macro}
1166 % \begin{macro}{\LTXcmds@Cx}
1167 % \begin{macrocode}
1168 \def\LTXcmds@Cx#1{%
1169 \endcsname{}%
1170 }
1171 % \end{macrocode}
1172 % \end{macro}
1173 % \begin{macro}{\LTXcmds@CarNumFinish}
1174 % \begin{macrocode}
1175 \long\def\LTXcmds@CarNumFinish#1#2\@nil{%
1176 \ltx@zero
1177 #1%
1178 }
1179 % \end{macrocode}
1180 % \end{macro}
1181 %
1182 % \begin{macro}{\ltx@CarNumth}
1183 % \begin{macrocode}
1184 \def\ltx@CarNumth#1{%
1185 \romannumeral
1186 \expandafter\expandafter\expandafter
1187 \LTXcmds@CarNumth
1188 \ltx@GobbleNum{#1}{}%
1189 }
1190 % \end{macrocode}
1191 % \end{macro}
1192 % \begin{macro}{\LTXcmds@CarNumth}
1193 % \begin{macrocode}
1194 \long\def\LTXcmds@CarNumth#1#2\@nil{%
1195 \ltx@zero
1196 #1%
1197 }
1198 % \end{macrocode}
1199 % \end{macro}
1200 %
1201 % \begin{macro}{\ltx@CdrNum}
1202 % \begin{macrocode}
1203 \def\ltx@CdrNum#1{%
1204 \romannumeral%
1205 \expandafter\expandafter\expandafter\ltx@cdrzero
1206 \expandafter\expandafter\expandafter\ltx@zero
1207 \ltx@GobbleNum{#1}%
1208 }
1209 % \end{macrocode}
1210 % \end{macro}
1211 %
1212 % \subsection{Tail recursion}
1213 %
1214 % \begin{macro}{\ltx@ReturnAfterFi}
1215 % \begin{macrocode}
1216 \long\def\ltx@ReturnAfterFi#1\fi{\fi#1}
1217 % \end{macrocode}
1218 % \end{macro}
1219 % \begin{macro}{\ltx@ReturnAfterElseFi}
1220 % \begin{macrocode}
1221 \long\def\ltx@ReturnAfterElseFi#1\else#2\fi{\fi#1}
1222 % \end{macrocode}
1223 % \end{macro}
1224 %
1225 % \subsection{Empty macro}
1226 %
1227 % \begin{macro}{\ltx@empty}
1228 % \begin{macrocode}
1229 \def\ltx@empty{}
1230 % \end{macrocode}
1231 % \end{macro}
1232 %
1233 % \subsection{Characters}
1234 %
1235 % \begin{macro}{\ltx@space}
1236 % \begin{macrocode}
1237 \def\ltx@space{ }
1238 % \end{macrocode}
1239 % \end{macro}
1240 % \begin{macro}{\ltx@percentchar}
1241 % \begin{macrocode}
1242 \begingroup
1243 \lccode`0=`\%\relax
1244 \lowercase{\endgroup
1245 \def\ltx@percentchar{0}%
1246 }
1247 % \end{macrocode}
1248 % \end{macro}
1249 % \begin{macro}{\ltx@backslashchar}
1250 % \begin{macrocode}
1251 \begingroup
1252 \lccode`0=`\\\relax
1253 \lowercase{\endgroup
1254 \def\ltx@backslashchar{0}%
1255 }
1256 % \end{macrocode}
1257 % \end{macro}
1258 % \begin{macro}{\ltx@hashchar}
1259 % \begin{macrocode}
1260 \begingroup
1261 \lccode`0=`\#\relax
1262 \lowercase{\endgroup
1263 \def\ltx@hashchar{0}%
1264 }
1265 % \end{macrocode}
1266 % \end{macro}
1267 % \begin{macro}{\ltx@leftbracechar}
1268 % \begin{macrocode}
1269 \begingroup
1270 \lccode`0=`\{\relax
1271 \lowercase{\endgroup
1272 \def\ltx@leftbracechar{0}%
1273 }
1274 % \end{macrocode}
1275 % \end{macro}
1276 % \begin{macro}{\ltx@rightbracechar}
1277 % \begin{macrocode}
1278 \begingroup
1279 \lccode`0=`\}\relax
1280 \lowercase{\endgroup
1281 \def\ltx@rightbracechar{0}%
1282 }
1283 % \end{macrocode}
1284 % \end{macro}
1285 %
1286 % \subsection{Boolean switch}
1287 %
1288 % \begin{macro}{\ltx@newif}
1289 % \begin{macrocode}
1290 \def\ltx@newif#1{%
1291 \begingroup
1292 \escapechar=-1 %
1293 \expandafter\endgroup
1294 \expandafter\LTXcmds@newif\string#1\@nil
1295 }
1296 % \end{macrocode}
1297 % \end{macro}
1298 % \begin{macro}{\LTXcmds@newif}
1299 % \begin{macrocode}
1300 \begingroup
1301 \escapechar=-1 %
1302 \expandafter\endgroup
1303 \expandafter\def\expandafter\LTXcmds@newif\string\if#1\@nil{%
1304 \expandafter\edef\csname#1true\endcsname{%
1305 \let
1306 \expandafter\noexpand\csname if#1\endcsname
1307 \noexpand\iftrue
1308 }%
1309 \expandafter\edef\csname#1false\endcsname{%
1310 \let
1311 \expandafter\noexpand\csname if#1\endcsname
1312 \noexpand\iffalse
1313 }%
1314 \csname#1false\endcsname
1315 }
1316 % \end{macrocode}
1317 % \end{macro}
1318 %
1319 % \begin{macro}{\ltx@newglobalif}
1320 % \begin{macrocode}
1321 \def\ltx@newglobalif#1{%
1322 \begingroup
1323 \escapechar=-1 %
1324 \expandafter\endgroup
1325 \expandafter\LTXcmds@newglobalif\string#1\@nil
1326 }
1327 % \end{macrocode}
1328 % \end{macro}
1329 % \begin{macro}{\LTXcmds@newglobalif}
1330 % \begin{macrocode}
1331 \begingroup
1332 \escapechar=-1 %
1333 \expandafter\endgroup
1334 \expandafter
1335 \def\expandafter\LTXcmds@newglobalif\string\if#1\@nil{%
1336 \expandafter\edef\csname#1true\endcsname{%
1337 \global\let
1338 \expandafter\noexpand\csname if#1\endcsname
1339 \noexpand\iftrue
1340 }%
1341 \expandafter\edef\csname#1false\endcsname{%
1342 \global\let
1343 \expandafter\noexpand\csname if#1\endcsname
1344 \noexpand\iffalse
1345 }%
1346 \csname#1false\endcsname
1347 }
1348 % \end{macrocode}
1349 % \end{macro}
1350 %
1351 % \subsection{Command definitions}
1352 %
1353 % \begin{macro}{\ltx@LocalExpandAfter}
1354 % \begin{macrocode}
1355 \def\ltx@LocalExpandAfter{%
1356 \begingroup
1357 \expandafter\expandafter\expandafter
1358 \endgroup
1359 \expandafter
1360 }
1361 % \end{macrocode}
1362 % \end{macro}
1363 %
1364 % \begin{macrocode}
1365 \ltx@LocalExpandAfter
1366 \ifx\csname ifcsname\endcsname\relax
1367 % \end{macrocode}
1368 % \begin{macro}{\ltx@ifundefined}
1369 % \begin{macrocode}
1370 \def\ltx@ifundefined#1{%
1371 \expandafter\ifx\csname #1\endcsname\relax
1372 \expandafter\ltx@firstoftwo
1373 \else
1374 \expandafter\ltx@secondoftwo
1375 \fi
1376 }%
1377 % \end{macrocode}
1378 % \end{macro}
1379 % \begin{macro}{\ltx@IfUndefined}
1380 % \begin{macrocode}
1381 \def\ltx@IfUndefined#1{%
1382 \begingroup\expandafter\expandafter\expandafter\endgroup
1383 \expandafter\ifx\csname #1\endcsname\relax
1384 \expandafter\ltx@firstoftwo
1385 \else
1386 \expandafter\ltx@secondoftwo
1387 \fi
1388 }%
1389 % \end{macrocode}
1390 % \end{macro}
1391 % \begin{macrocode}
1392 \expandafter\ltx@gobble
1393 \else
1394 \expandafter\ltx@firstofone
1395 \fi
1396 {%
1397 % \end{macrocode}
1398 % \begin{macro}{\ltx@ifundefined}
1399 % \begin{macrocode}
1400 \def\ltx@ifundefined#1{%
1401 \ifcsname #1\endcsname
1402 \expandafter\ifx\csname #1\endcsname\relax
1403 \expandafter\expandafter\expandafter\ltx@firstoftwo
1404 \else
1405 \expandafter\expandafter\expandafter\ltx@secondoftwo
1406 \fi
1407 \else
1408 \expandafter\ltx@firstoftwo
1409 \fi
1410 }%
1411 % \end{macrocode}
1412 % \end{macro}
1413 % \begin{macro}{\ltx@IfUndefined}
1414 % \begin{macrocode}
1415 \let\ltx@IfUndefined\ltx@ifundefined
1416 % \end{macrocode}
1417 % \end{macro}
1418 % \begin{macrocode}
1419 }
1420 % \end{macrocode}
1421 %
1422 % \subsection{Stripping}
1423 %
1424 % \begin{macro}{\ltx@RemovePrefix}
1425 % \begin{macrocode}
1426 \def\ltx@RemovePrefix#1>{}
1427 % \end{macrocode}
1428 % \end{macro}
1429 %
1430 % \begin{macro}{\ltx@StripPrefix}
1431 % \begin{macrocode}
1432 \def\ltx@StripPrefix{%
1433 \expandafter\ltx@RemovePrefix
1434 }
1435 % \end{macrocode}
1436 % \end{macro}
1437 %
1438 % \begin{macro}{\ltx@onelevel@sanitize}
1439 % \begin{macrocode}
1440 \def\ltx@onelevel@sanitize#1{%
1441 \edef#1{%
1442 \expandafter
1443 \ltx@RemovePrefix\meaning#1%
1444 }%
1445 }
1446 % \end{macrocode}
1447 % \end{macro}
1448 %
1449 % \subsection{File management}
1450 %
1451 % \subsubsection{File extensions}
1452 %
1453 % \begin{macro}{\ltx@clsextension}
1454 % \begin{macrocode}
1455 \def\ltx@clsextension{cls}
1456 % \end{macrocode}
1457 % \end{macro}
1458 % \begin{macro}{\ltx@pkgextension}
1459 % \begin{macrocode}
1460 \def\ltx@pkgextension{sty}
1461 % \end{macrocode}
1462 % \end{macro}
1463 %
1464 % \subsubsection{Load check}
1465 %
1466 % \begin{macro}{\ltx@iffileloaded}
1467 % \begin{macrocode}
1468 \def\ltx@iffileloaded#1{%
1469 \ltx@ifundefined{ver@#1}\ltx@secondoftwo\ltx@firstoftwo
1470 }
1471 % \end{macrocode}
1472 % \end{macro}
1473 % \begin{macro}{\ltx@ifclassloaded}
1474 % \begin{macrocode}
1475 \def\ltx@ifclassloaded#1{%
1476 \ltx@iffileloaded{#1.\ltx@clsextension}%
1477 }
1478 % \end{macrocode}
1479 % \end{macro}
1480 % \begin{macro}{\ltx@ifpackageloaded}
1481 % \begin{macrocode}
1482 \def\ltx@ifpackageloaded#1{%
1483 \ltx@iffileloaded{#1.\ltx@pkgextension}%
1484 }
1485 % \end{macrocode}
1486 % \end{macro}
1487 %
1488 % \subsubsection{Version date check}
1489 % changed 2020-05-10 to adapt to dates with dashes (ISO)
1490 % The core of the commands are copies from the latex commands.
1491 % \begin{macro}{\ltx@ifl@ter}
1492 % \begin{macro}{\ltx@parse@version@}
1493 % \begin{macrocode}
1494 \def\ltx@ifl@ter#1#2{%
1495 \expandafter\ltx@ifl@t@r
1496 \csname ver@#2.#1\endcsname}
1497 \def\ltx@ifl@t@r#1#2{%
1498 \ifnum\expandafter\ltx@parse@version@#1//00\@nil<%
1499 \expandafter\ltx@parse@version@#2//00\@nil
1500 \expandafter\ltx@secondoftwo
1501 \else
1502 \expandafter\ltx@firstoftwo
1503 \fi}
1504 \def\ltx@parse@version@#1{\ltx@parse@version0#1}
1505 \def\ltx@parse@version#1/#2/#3#4#5\@nil{%
1506 \ltx@parse@version@dash#1-#2-#3#4\@nil
1507 }
1508 \def\ltx@parse@version@dash#1-#2-#3#4#5\@nil{%
1509 \if\relax#2\relax\else#1\fi#2#3#4 }
1510 % \end{macrocode}
1511 % \end{macro}
1512 % \end{macro}
1513 % \begin{macro}{\ltx@iffilelater}
1514 % \begin{macrocode}
1515 \def\ltx@iffilelater#1{\expandafter\ltx@ifl@t@r\csname ver@#1\endcsname}
1516 % \end{macrocode}
1517 % \end{macro}
1518 % \begin{macro}{\ltx@ifclasslater}
1519 % \begin{macrocode}
1520 \def\ltx@ifclasslater{\ltx@ifl@ter\ltx@clsextension}
1521 % \end{macrocode}
1522 % \end{macro}
1523 % \begin{macro}{\ltx@ifpackagelater}
1524 % \begin{macrocode}
1525 \def\ltx@ifpackagelater{\ltx@ifl@ter\ltx@pkgextension}
1526 % \end{macrocode}
1527 % \end{macro}
1528 %
1529 %
1530 % \subsection{Macro additions}
1531 %
1532 % \begin{macro}{\ltx@GlobalAppendToMacro}
1533 % \begin{macrocode}
1534 \long\def\ltx@GlobalAppendToMacro#1#2{%
1535 \ifx\ltx@undefined#1%
1536 \let#1\ltx@empty
1537 \else
1538 \ifx\relax#1%
1539 \let#1\ltx@empty
1540 \fi
1541 \fi
1542 \begingroup
1543 \ltx@LocToksA\expandafter{#1#2}%
1544 \xdef#1{\the\ltx@LocToksA}%
1545 \endgroup
1546 }
1547 % \end{macrocode}
1548 % \end{macro}
1549 % \begin{macro}{\ltx@LocalAppendToMacro}
1550 % \begin{macrocode}
1551 \long\def\ltx@LocalAppendToMacro#1#2{%
1552 \global\let\LTXcmds@gtemp#1%
1553 \ifx\ltx@undefined\LTXcmds@gtemp
1554 \global\let\LTXcmds@gtemp\ltx@empty
1555 \else
1556 \ifx\relax\LTXcmds@gtemp
1557 \global\letLTXcmds@gtemp\ltx@empty
1558 \fi
1559 \fi
1560 \begingroup
1561 \ltx@LocToksA\expandafter{\LTXcmds@gtemp#2}%
1562 \xdef\LTXcmds@gtemp{\the\ltx@LocToksA}%
1563 \endgroup
1564 \let#1\LTXcmds@gtemp
1565 }
1566 % \end{macrocode}
1567 % \end{macro}
1568 %
1569 % \begin{macro}{\ltx@GlobalPrependToMacro}
1570 % \begin{macrocode}
1571 \long\def\ltx@GlobalPrependToMacro#1#2{%
1572 \ifx\ltx@undefined#1%
1573 \let#1\ltx@empty
1574 \else
1575 \ifx\relax#1%
1576 \let#1\ltx@empty
1577 \fi
1578 \fi
1579 \begingroup
1580 \ltx@LocToksA{#2}%
1581 \ltx@LocToksB\expandafter{#1}%
1582 \xdef#1{\the\ltx@LocToksA\the\ltx@LocToksB}%
1583 \endgroup
1584 }
1585 % \end{macrocode}
1586 % \end{macro}
1587 % \begin{macro}{\ltx@LocalPrependToMacro}
1588 % \begin{macrocode}
1589 \long\def\ltx@LocalPrependToMacro#1#2{%
1590 \global\let\LTXcmds@gtemp#1%
1591 \ifx\ltx@undefined\LTXcmds@gtemp
1592 \global\let\LTXcmds@gtemp\ltx@empty
1593 \else
1594 \ifx\relax\LTXcmds@gtemp
1595 \global\letLTXcmds@gtemp\ltx@empty
1596 \fi
1597 \fi
1598 \begingroup
1599 \ltx@LocToksA{#2}%
1600 \ltx@LocToksB\expandafter{\LTXcmds@gtemp}%
1601 \xdef\LTXcmds@gtemp{\the\ltx@LocToksA\the\ltx@LocToksB}%
1602 \endgroup
1603 \let#1\LTXcmds@gtemp
1604 }
1605 % \end{macrocode}
1606 % \end{macro}
1607 %
1608 % \subsection{Next character detection}
1609 %
1610 % \begin{macro}{\ltx@ifnextchar}
1611 % \begin{macrocode}
1612 \long\def\ltx@ifnextchar#1#2#3{%
1613 \begingroup
1614 \let\LTXcmds@CharToken= #1\relax
1615 \ltx@LocToksA{\endgroup#2}%
1616 \ltx@LocToksB{\endgroup#3}%
1617 \futurelet\LTXcmds@LetToken\LTXcmds@ifnextchar
1618 }
1619 % \end{macrocode}
1620 % \end{macro}
1621 % \begin{macro}{\LTXcmds@ifnextchar}
1622 % \begin{macrocode}
1623 \def\LTXcmds@ifnextchar{%
1624 \ifx\LTXcmds@LetToken\LTXcmds@CharToken
1625 \the\expandafter\ltx@LocToksA
1626 \else
1627 \expandafter
1628 \ifx\csname LTXcmds@LetToken\endcsname\LTXcmds@SpaceToken
1629 \expandafter\expandafter\expandafter\LTXcmds@@ifnextchar
1630 \else
1631 \the\expandafter\expandafter\expandafter\ltx@LocToksB
1632 \fi
1633 \fi
1634 }
1635 % \end{macrocode}
1636 % \end{macro}
1637 % \begin{macro}{\LTXcmds@@ifnextchar}
1638 % \cs{futurelet} does not distinguish between a
1639 % character and a command that is a character
1640 % (defined by using \cs{let} or \cs{futurelet}).
1641 % Therefore the space is catched by \cs{romannumeral}
1642 % with negative character constant that gobbles one
1643 % optional space.
1644 % \begin{macrocode}
1645 \def\LTXcmds@@ifnextchar{%
1646 \expandafter\futurelet
1647 \expandafter\LTXcmds@LetToken
1648 \expandafter\LTXcmds@ifnextchar
1649 \romannumeral-`\.%
1650 }
1651 % \end{macrocode}
1652 % \end{macro}
1653 % \begin{macro}{\LTXcmds@SpaceToken}
1654 % \begin{macrocode}
1655 \ltx@firstofone{\let\LTXcmds@SpaceToken= } %
1656 % \end{macrocode}
1657 % \end{macro}
1658 %
1659 % \begin{macro}{\ltx@ifnextchar@nospace}
1660 % \begin{macrocode}
1661 \long\def\ltx@ifnextchar@nospace#1#2#3{%
1662 \begingroup
1663 \let\LTXcmds@CharToken= #1\relax
1664 \ltx@LocToksA{\endgroup#2}%
1665 \ltx@LocToksB{\endgroup#3}%
1666 \futurelet\LTXcmds@LetToken\LTXcmds@ifnextchar@nospace
1667 }
1668 % \end{macrocode}
1669 % \end{macro}
1670 % \begin{macro}{\LTXcmds@ifnextchar@nospace}
1671 % \begin{macrocode}
1672 \def\LTXcmds@ifnextchar@nospace{%
1673 \the
1674 \ifx\LTXcmds@LetToken\LTXcmds@CharToken
1675 \expandafter\ltx@LocToksA
1676 \else
1677 \expandafter\ltx@LocToksB
1678 \fi
1679 }
1680 % \end{macrocode}
1681 % \end{macro}
1682 % \subsection{\cs{ltx@leavevmode}, \cs{ltx@mbox}}
1683 %
1684 % \begin{macro}{\ltx@leavevmode}
1685 % \begin{macrocode}
1686 \ltx@IfUndefined{quitvmode}{%
1687 \ltx@IfUndefined{leavevmode}{%
1688 \ltx@IfUndefined{voidb@x}{%
1689 \ltx@IfUndefined{newbox}{%
1690 \def\ltx@leavevmode{%
1691 \begingroup
1692 \setbox\ltx@zero=\hbox{}%
1693 \begingroup
1694 \setbox\ltx@zero=\hbox{\box\ltx@zero}%
1695 \endgroup
1696 \unhbox\ltx@zero
1697 \endgroup
1698 }%
1699 }{%
1700 \csname newbox\endcsname\LTXcmds@VoidBox
1701 \ifvoid\LTXcmds@VoidBox
1702 \else
1703 \setbox\LTXcmds@VoidBox=\hbox{}%
1704 \begingroup
1705 \setbox\LTXcmds@VoidBox=\hbox{\box\LTXcmds@VoidBox}%
1706 \endgroup
1707 \fi
1708 \def\ltx@leavevmode{\unhbox\LTXcmds@VoidBox}%
1709 }%
1710 }{%
1711 \def\ltx@leavevmode{\unhbox\voidb@x}%
1712 }%
1713 }{%
1714 \let\ltx@leavevmode\leavevmode
1715 }%
1716 }{%
1717 \let\ltx@leavevmode\quitvmode
1718 }
1719 % \end{macrocode}
1720 % \end{macro}
1721 %
1722 % \begin{macro}{\ltx@mbox}
1723 % \begin{macrocode}
1724 \def\ltx@mbox{%
1725 \ltx@leavevmode
1726 \hbox
1727 }
1728 % \end{macrocode}
1729 % \end{macro}
1730 %
1731 % \subsection{Help macros}
1732 %
1733 % \begin{macro}{\LTXcmds@num}
1734 % \begin{macrocode}
1735 \ltx@IfUndefined{numexpr}{%
1736 \def\LTXcmds@num#1{%
1737 \expandafter\ltx@firstofone\expandafter{%
1738 \number#1%
1739 }%
1740 }%
1741 }{%
1742 \def\LTXcmds@num#1{%
1743 \expandafter\ltx@firstofone\expandafter{%
1744 \the\numexpr#1%
1745 }%
1746 }%
1747 }
1748 % \end{macrocode}
1749 % \end{macro}
1750 %
1751 % \subsection{Expandable test for emptiness}
1752 %
1753 % \begin{macrocode}
1754 \ltx@IfUndefined{detokenize}{%
1755 % \end{macrocode}
1756 %
1757 % \subsubsection{Vanilla \hologo{TeX}}
1758 %
1759 % \begin{macro}{\ltx@ifempty}
1760 % The macro is based on \cs{@ifempty} of Robert R. Schneck
1761 % \cite{ifempty:schneck}
1762 % and \cs{@ifnull} of Ulrich Diez \cite{ifnull:diez}.
1763 % There are three cases to consider:
1764 % \begin{compactenum}
1765 % \item |#1| is empty,
1766 % \item |#1| is not empty and the first token
1767 % is not a begingroup character,
1768 % \item |#1| starts with a begingroup character (catcode 1).
1769 % \end{compactenum}
1770 % \begin{macrocode}
1771 \def\LTXcmds@temp#1{%
1772 \long\def\ltx@ifempty##1{%
1773 \romannumeral0%
1774 \iffalse{\fi
1775 \expandafter\ltx@gobble\expandafter{%
1776 \expandafter{\string##1}%
1777 \expandafter\ltx@gobble\string
1778 }%
1779 \expandafter\ltx@firstofthree\expandafter
1780 {\iffalse}\fi
1781 \expandafter#1\ltx@secondoftwo
1782 }%
1783 \expandafter#1\ltx@firstoftwo
1784 }%
1785 % \end{macrocode}
1786 % \end{macro}
1787 % \begin{macro}{\ltx@ifblank}
1788 % \begin{macrocode}
1789 \long\def\ltx@ifblank##1{%
1790 \romannumeral0%
1791 \iffalse{\fi
1792 \expandafter\expandafter\expandafter\ltx@gobble
1793 \expandafter\expandafter\expandafter{%
1794 \expandafter\expandafter\expandafter{%
1795 \expandafter\string\ltx@gobble##1.%
1796 }%
1797 \expandafter\ltx@gobble\string
1798 }%
1799 \expandafter\ltx@firstofthree\expandafter
1800 {\iffalse}\fi
1801 \expandafter#1\ltx@secondoftwo
1802 }%
1803 \expandafter#1\ltx@firstoftwo
1804 }%
1805 }%
1806 \LTXcmds@temp{ }%
1807 % \end{macrocode}
1808 % \end{macro}
1809 % \begin{macrocode}
1810 }{%
1811 % \end{macrocode}
1812 %
1813 % \subsubsection{With \cs{detokenize}}
1814 %
1815 % Ahmed Musa provided \cs{ifstrempty} using \cs{detokenize}
1816 % and \cs{pdfstrcmp} \cite{ifstrempty:musa}. Ulrich Diez, GL,
1817 % Heiko Oberdiek
1818 % improved it further by removing \cs{pdfstrcmp} and
1819 % taking three arguments
1820 % \cite{ifstrempty:diez1,ifstrempty:diez2,ifstrempty:diez3,^^A
1821 % ifstrempty:gl,ifstrempty:ho}.
1822 %
1823 % \begin{macro}{\ltx@ifempty}
1824 % \begin{macrocode}
1825 \long\def\ltx@ifempty#1{%
1826 \romannumeral%
1827 \csname
1828 LTXcmds@ifempty%
1829 \ifcat$\detokenize{#1}$%
1830 @%
1831 \fi
1832 \endcsname
1833 }%
1834 % \end{macrocode}
1835 % \end{macro}
1836 % \begin{macro}{\LTXcmds@ifempty@}
1837 % \begin{macrocode}
1838 \long\def\LTXcmds@ifempty@#1#2{0 #1}%
1839 % \end{macrocode}
1840 % \end{macro}
1841 % \begin{macro}{\LTXcmds@ifempty}
1842 % \begin{macrocode}
1843 \long\def\LTXcmds@ifempty#1#2{0 #2}%
1844 % \end{macrocode}
1845 % \end{macro}
1846 %
1847 % \subsubsection{\cs{ltx@ifblank}}
1848 %
1849 % \begin{macro}{\ltx@ifblank}
1850 % \begin{macrocode}
1851 \long\def\ltx@ifblank#1{%
1852 \romannumeral%
1853 \csname
1854 LTXcmds@ifempty%
1855 \ifcat$\detokenize\expandafter{\ltx@gobble#1.}$%
1856 @%
1857 \fi
1858 \endcsname
1859 }%
1860 % \end{macrocode}
1861 % \end{macro}
1862 %
1863 % \begin{macrocode}
1864 }
1865 % \end{macrocode}
1866 %
1867 % \subsection{\cs{ltx@zapspace}}
1868 %
1869 % \begin{macro}{\ltx@zapspace}
1870 % \begin{macrocode}
1871 \long\def\ltx@zapspace#1{%
1872 \romannumeral
1873 \LTXcmds@zapspace\ltx@zero#1 \@nil
1874 }
1875 % \end{macrocode}
1876 % \end{macro}
1877 % \begin{macro}{\LTXcmds@zapspace}
1878 % \begin{macrocode}
1879 \long\def\LTXcmds@zapspace#1 #2\@nil{%
1880 \ltx@ifempty{#2}{%
1881 #1%
1882 }{%
1883 \LTXcmds@zapspace#1#2\@nil
1884 }%
1885 }
1886 % \end{macrocode}
1887 % \end{macro}
1888 %
1889 % \subsection{\cs{ltx@IfBoxEmpty}}
1890 %
1891 % In case of \hologo{eTeX} the test for an empty box
1892 % is done via \cs{lastnodetype} as suggested
1893 % by David Kastrup \cite{ifboxempty:dak}.
1894 % \begin{macrocode}
1895 \ltx@IfUndefined{lastnodetype}{%
1896 \catcode`\$=9 %
1897 \catcode`\&=14 %
1898 }{%
1899 \catcode`\$=14 %
1900 \catcode`\&=9 %
1901 }
1902 % \end{macrocode}
1903 % \begin{macro}{\ltx@IfBoxEmpty}
1904 % \begin{macrocode}
1905 \def\ltx@IfBoxEmpty#1{%
1906 \ifvoid#1\relax
1907 \expandafter\ltx@secondoftwo
1908 \else
1909 % \end{macrocode}
1910 % Implementation using \hologo{eTeX}'s \cs{lastnodetype}.
1911 % \begin{macrocode}
1912 & \begingroup
1913 & \setbox\ltx@zero=\ifhbox#1\hbox\else\vbox\fi{%
1914 & \ifhmode\unhcopy\else\unvcopy\fi#1\relax
1915 & \expandafter
1916 & }%
1917 & \expandafter\endgroup
1918 & \ifnum\lastnodetype<\ltx@zero
1919 & \expandafter\expandafter\expandafter\ltx@firstoftwo
1920 & \else
1921 & \expandafter\expandafter\expandafter\ltx@secondoftwo
1922 & \fi
1923 % \end{macrocode}
1924 % Implementation without \hologo{eTeX} using a signature
1925 % at the beginning of the test box.
1926 % \begin{macrocode}
1927 $ \begingroup
1928 $ \setbox\ltx@zero=\ifhbox#1\hbox\else\vbox\fi{%
1929 $ \penalty\ltx@one
1930 $ \ifhmode\unhcopy\else\unvcopy\fi#1\relax
1931 $ \expandafter
1932 $ }%
1933 $ \ifnum\lastpenalty=\ltx@one
1934 % \end{macrocode}
1935 % Box 0 has been changed and is restored by
1936 % closing the group.
1937 % \begin{macrocode}
1938 $ \endgroup
1939 $ \begingroup
1940 $ \setbox\ltx@zero=\ifhbox#1\hbox\else\vbox\fi{%
1941 $ \penalty\ltx@two
1942 $ \ifhmode\unhcopy\else\unvcopy\fi#1\relax
1943 $ \expandafter
1944 $ }%
1945 $ \ifnum\lastpenalty=\ltx@two
1946 $ \def\next{\endgroup\expandafter\ltx@firstoftwo}%
1947 $ \else
1948 $ \def\next{\endgroup\expandafter\ltx@secondoftwo}%
1949 $ \fi
1950 $ \else
1951 $ \def\next{\endgroup\expandafter\ltx@secondoftwo}%
1952 $ \fi
1953 $ \next
1954 \fi
1955 }
1956 % \end{macrocode}
1957 % \end{macro}
1958 %
1959 % \begin{macro}{\ltx@IfBoxVoidOrEmpty}
1960 % \begin{macrocode}
1961 \def\ltx@IfBoxVoidOrEmpty#1{%
1962 \ifvoid#1\relax
1963 \expandafter\ltx@thirdoffour
1964 \fi
1965 \ltx@IfBoxEmpty{#1}%
1966 }
1967 % \end{macrocode}
1968 % \end{macro}
1969 %
1970 % \begin{macrocode}
1971 \LTXcmds@AtEnd%
1972 %</package>
1973 % \end{macrocode}
1974 %% \section{Installation}
1975 %
1976 % \subsection{Download}
1977 %
1978 % \paragraph{Package.} This package is available on
1979 % CTAN\footnote{\CTANpkg{ltxcmds}}:
1980 % \begin{description}
1981 % \item[\CTAN{macros/latex/contrib/ltxcmds/ltxcmds.dtx}] The source file.
1982 % \item[\CTAN{macros/latex/contrib/ltxcmds/ltxcmds.pdf}] Documentation.
1983 % \end{description}
1984 %
1985 %
1986 % \subsection{Package installation}
1987 % The package is at best installed with the package manager of the \TeX~system.
1988 % Manual installation is possible too:
1989 % \paragraph{Unpacking.} The \xfile{.dtx} file is a self-extracting
1990 % \docstrip\ archive. The files are extracted by running the
1991 % \xfile{.dtx} through \plainTeX:
1992 % \begin{quote}
1993 % \verb|tex ltxcmds.dtx|
1994 % \end{quote}
1995 %
1996 % \paragraph{TDS.} Now the different files must be moved into
1997 % the different directories in your installation TDS tree
1998 % (also known as \xfile{texmf} tree):
1999 % \begin{quote}
2000 % \def\t{^^A
2001 % \begin{tabular}{@{}>{\ttfamily}l@{ $\rightarrow$ }>{\ttfamily}l@{}}
2002 % ltxcmds.sty & tex/generic/ltxcmds/ltxcmds.sty\\
2003 % ltxcmds.pdf & doc/latex/ltxcmds/ltxcmds.pdf\\
2004 % ltxcmds.dtx & source/latex/ltxcmds/ltxcmds.dtx\\
2005 % \end{tabular}^^A
2006 % }^^A
2007 % \sbox0{\t}^^A
2008 % \ifdim\wd0>\linewidth
2009 % \begingroup
2010 % \advance\linewidth by\leftmargin
2011 % \advance\linewidth by\rightmargin
2012 % \edef\x{\endgroup
2013 % \def\noexpand\lw{\the\linewidth}^^A
2014 % }\x
2015 % \def\lwbox{^^A
2016 % \leavevmode
2017 % \hbox to \linewidth{^^A
2018 % \kern-\leftmargin\relax
2019 % \hss
2020 % \usebox0
2021 % \hss
2022 % \kern-\rightmargin\relax
2023 % }^^A
2024 % }^^A
2025 % \ifdim\wd0>\lw
2026 % \sbox0{\small\t}^^A
2027 % \ifdim\wd0>\linewidth
2028 % \ifdim\wd0>\lw
2029 % \sbox0{\footnotesize\t}^^A
2030 % \ifdim\wd0>\linewidth
2031 % \ifdim\wd0>\lw
2032 % \sbox0{\scriptsize\t}^^A
2033 % \ifdim\wd0>\linewidth
2034 % \ifdim\wd0>\lw
2035 % \sbox0{\tiny\t}^^A
2036 % \ifdim\wd0>\linewidth
2037 % \lwbox
2038 % \else
2039 % \usebox0
2040 % \fi
2041 % \else
2042 % \lwbox
2043 % \fi
2044 % \else
2045 % \usebox0
2046 % \fi
2047 % \else
2048 % \lwbox
2049 % \fi
2050 % \else
2051 % \usebox0
2052 % \fi
2053 % \else
2054 % \lwbox
2055 % \fi
2056 % \else
2057 % \usebox0
2058 % \fi
2059 % \else
2060 % \lwbox
2061 % \fi
2062 % \else
2063 % \usebox0
2064 % \fi
2065 % \end{quote}
2066 % If you have a \xfile{docstrip.cfg} that configures and enables \docstrip's
2067 % TDS installing feature, then some files can already be in the right
2068 % place, see the documentation of \docstrip.
2069 %
2070 % \subsection{Refresh file name databases}
2071 %
2072 % If your \TeX~distribution
2073 % (\TeX\,Live, \mikTeX, \dots) relies on file name databases, you must refresh
2074 % these. For example, \TeX\,Live\ users run \verb|texhash| or
2075 % \verb|mktexlsr|.
2076 %
2077 % \subsection{Some details for the interested}
2078 %
2079 % \paragraph{Unpacking with \LaTeX.}
2080 % The \xfile{.dtx} chooses its action depending on the format:
2081 % \begin{description}
2082 % \item[\plainTeX:] Run \docstrip\ and extract the files.
2083 % \item[\LaTeX:] Generate the documentation.
2084 % \end{description}
2085 % If you insist on using \LaTeX\ for \docstrip\ (really,
2086 % \docstrip\ does not need \LaTeX), then inform the autodetect routine
2087 % about your intention:
2088 % \begin{quote}
2089 % \verb|latex \let\install=y\input{ltxcmds.dtx}|
2090 % \end{quote}
2091 % Do not forget to quote the argument according to the demands
2092 % of your shell.
2093 %
2094 % \paragraph{Generating the documentation.}
2095 % You can use both the \xfile{.dtx} or the \xfile{.drv} to generate
2096 % the documentation. The process can be configured by the
2097 % configuration file \xfile{ltxdoc.cfg}. For instance, put this
2098 % line into this file, if you want to have A4 as paper format:
2099 % \begin{quote}
2100 % \verb|\PassOptionsToClass{a4paper}{article}|
2101 % \end{quote}
2102 % An example follows how to generate the
2103 % documentation with pdf\LaTeX:
2104 % \begin{quote}
2105 %\begin{verbatim}
2106 %pdflatex ltxcmds.dtx
2107 %makeindex -s gind.ist ltxcmds.idx
2108 %pdflatex ltxcmds.dtx
2109 %makeindex -s gind.ist ltxcmds.idx
2110 %pdflatex ltxcmds.dtx
2111 %\end{verbatim}
2112 % \end{quote}
2113 %
2114 % \begin{thebibliography}{9}
2115 % \raggedright
2116 %
2117 % \bibitem{ifempty:schneck}
2118 % Robert R. Schneck:
2119 % \textit{Re: \cs{ifempty} solution %
2120 % (was Macro puzzle: maximally general \cs{ifempty})};
2121 % newsgroup \xnewsgroup{comp.text.tex},
2122 % \url{news:[email protected]},
2123 % 2003-06-17.\\
2124 % {\small
2125 % \url{https://groups.google.com/group/comp.text.tex/msg/be03a159ec374895}}
2126 %
2127 % \bibitem{ifnull:diez}
2128 % Ulrich Diez:
2129 % \textit{Re: TeX refuses to strip outer braces in argument};
2130 % newsgroup \xnewsgroup{comp.text.tex},
2131 % \url{news:[email protected]},
2132 % 2010-11-12.\\
2133 % {\small
2134 % \url{https://groups.google.com/group/comp.text.tex/msg/803bd57221a04996}}
2135 %
2136 % \bibitem{ifstrempty:musa}
2137 % Ahmed Musa:
2138 % \textit{Re: TeX refuses to strip outer braces in argument};
2139 % newsgroup \xnewsgroup{comp.text.tex},
2140 % \url{news:f5496afe-40ed-42bd-b629-a2419ecf7c0d@o14g2000prn.googlegroups.com},
2141 % 2010-12-03.\\
2142 % {\small
2143 % \url{https://groups.google.com/group/comp.text.tex/msg/fbf7d61a0c3a807d}}
2144 %
2145 % \bibitem{ifstrempty:diez1}
2146 % Ulrich Diez:
2147 % \textit{Re: TeX refuses to strip outer braces in argument};
2148 % newsgroup \xnewsgroup{comp.text.tex},
2149 % \url{news:[email protected]},
2150 % 2010-12-03.\\
2151 % {\small
2152 % \url{https://groups.google.com/group/comp.text.tex/msg/0c230ee479487962}}
2153 %
2154 % \bibitem{ifstrempty:diez2}
2155 % Ulrich Diez:
2156 % \textit{Re: TeX refuses to strip outer braces in argument};
2157 % newsgroup \xnewsgroup{comp.text.tex},
2158 % \url{news:[email protected]},
2159 % 2010-12-03.\\
2160 % {\small
2161 % \url{https://groups.google.com/group/comp.text.tex/msg/bbef4263390d647b}}
2162 %
2163 % \bibitem{ifstrempty:diez3}
2164 % Ulrich Diez:
2165 % \textit{Re: TeX refuses to strip outer braces in argument};
2166 % newsgroup \xnewsgroup{comp.text.tex},
2167 % \url{news:[email protected]},
2168 % 2010-12-04.\\
2169 % {\small
2170 % \url{https://groups.google.com/group/comp.text.tex/msg/00dfd1ec103cd272}}
2171 %
2172 % \bibitem{ifstrempty:gl}
2173 % GL:
2174 % \textit{Re: TeX refuses to strip outer braces in argument};
2175 % newsgroup \xnewsgroup{comp.text.tex},
2176 % \url{news:[email protected]},
2177 % 2010-12-04.\\
2178 % {\small
2179 % \url{https://groups.google.com/group/comp.text.tex/msg/d3a75995c1cf267e}}
2180 %
2181 % \bibitem{ifstrempty:ho}
2182 % Heiko Oberdiek:
2183 % \textit{Re: TeX refuses to strip outer braces in argument};
2184 % newsgroup \xnewsgroup{comp.text.tex},
2185 % \url{news:[email protected]},
2186 % 2010-12-04.\\
2187 % {\small
2188 % \url{https://groups.google.com/group/comp.text.tex/msg/5f7a23e3ab70e347}}
2189 %
2190 % \bibitem{ifboxempty:dak}
2191 % David Kastrup:
2192 % \textit{How to detect if \cs{vbox} is empty};
2193 % newsgroup \xnewsgroup{comp.text.tex},
2194 % 2011-02-04.\\
2195 % {\small
2196 % \url{https://groups.google.com/group/comp.text.tex/msg/8d3cb89496a4d86d}}
2197 %
2198 % \end{thebibliography}
2199 %
2200 % \begin{History}
2201 % \begin{Version}{2009/08/05 v1.0}
2202 % \item
2203 % First version.
2204 % \end{Version}
2205 % \begin{Version}{2009/12/12 v1.1}
2206 % \item
2207 % Short title shortened.
2208 % \item
2209 % \cs{ltx@IfUndefined} added.
2210 % \end{Version}
2211 % \begin{Version}{2010/01/28 v1.2}
2212 % \item
2213 % \cs{ltx@RemovePrefix} and \cs{ltx@StripPrefix} added.
2214 % \item
2215 % \cs{ltx@ifclassloaded}, \cs{ltx@ifpackageloaded},
2216 % \cs{ltx@iffileloaded},
2217 % \cs{ltx@ifclasslater}, \cs{ltx@ifpackagelater},
2218 % \cs{ltx@iffilelater},
2219 % \cs{ltx@clsextension}, \cs{ltx@pkgextension} added.
2220 % \item
2221 % \cs{ltx@GlobalAppendToMacro}, \cs{ltx@LocalAppendToMacro} added.
2222 % \end{Version}
2223 % \begin{Version}{2010/03/01 v1.3}
2224 % \item
2225 % \cs{ltx@newif} added.
2226 % \item
2227 % \cs{ltx@ifnextchar} added.
2228 % \item
2229 % Numbers \cs{ltx@zero}, \cs{ltx@one}, \cs{ltx@two}, \cs{ltx@cclv} added.
2230 % \end{Version}
2231 % \begin{Version}{2010/03/09 v1.4}
2232 % \item
2233 % \cs{ltx@pkgextension} and \cs{ltx@clsextension} are hardcoded to
2234 % avoid trouble with \cs{@onlypreamble}.
2235 % \end{Version}
2236 % \begin{Version}{2010/04/08 v1.5}
2237 % \item
2238 % \cs{ltx@cartwo}, \cs{ltx@cdrtwo},
2239 % \cs{ltx@carthree}, \cs{ltx@cdrthree},
2240 % \cs{ltx@carfour}, \cs{ltx@cdrfour} added.
2241 % \item
2242 % \cs{ltx@ReturnAfterFi} and \cs{ltx@ReturnAfterElseFi} fixed.
2243 % \end{Version}
2244 % \begin{Version}{2010/04/16 v1.6}
2245 % \item
2246 % \cs{ltx@leavevmode}, \cs{ltx@mbox} added.
2247 % \end{Version}
2248 % \begin{Version}{2010/04/26 v1.7}
2249 % \item
2250 % \cs{ltx@GobbleNum}, \cs{ltx@CdrNum}, \cs{ltx@CarNum} added.
2251 % \item
2252 % \cs{ltx@carzero}, \cs{ltx@cdrzero} added.
2253 % \item
2254 % \cs{ltx@hashchar} added.
2255 % \end{Version}
2256 % \begin{Version}{2010/09/11 v1.8}
2257 % \item
2258 % \cs{ltx@leftbracechar}, \cs{ltx@rightbracechar} added.
2259 % \end{Version}
2260 % \begin{Version}{2010/10/25 v1.9}
2261 % \item
2262 % \cs{ltx@LocalAppendToMacro} and \cs{ltx@GlobalAppendToMacro} are
2263 % now \cs{long}.
2264 % \end{Version}
2265 % \begin{Version}{2010/10/31 v1.10}
2266 % \item
2267 % \cs{ltx@newglobalif} added.
2268 % \end{Version}
2269 % \begin{Version}{2010/11/12 v1.11}
2270 % \item
2271 % \cs{ltx@ifempty} added.
2272 % \item
2273 % \cs{ltx@firstofthree}, \cs{ltx@secondofthree}, \cs{ltx@thirdofthree}
2274 % added.
2275 % \end{Version}
2276 % \begin{Version}{2010/12/02 v1.12}
2277 % \item
2278 % \cs{ltx@onelevel@sanitize} added.
2279 % \item
2280 % \cs{LTXcmds@num} fixed for the case with \cs{numexpr}
2281 % (bug found by GL).
2282 % \end{Version}
2283 % \begin{Version}{2010/12/04 v1.13}
2284 % \item
2285 % \cs{ltx@ifblank} added.
2286 % \item
2287 % Optimization for \cs{ltx@ifempty}.
2288 % \end{Version}
2289 % \begin{Version}{2010/12/07 v1.14}
2290 % \item
2291 % \cs{ltx@zapspace} added.
2292 % \end{Version}
2293 % \begin{Version}{2010/12/12 v1.15}
2294 % \item
2295 % \cs{ltx@minusone} added.
2296 % \end{Version}
2297 % \begin{Version}{2011/02/04 v1.16}
2298 % \item
2299 % \cs{ltx@IfBoxEmpty} and \cs{ltx@IfBoxVoidOrEmpty} added.
2300 % \item
2301 % \cs{ltx@firstoffour}, \dots, \cs{ltx@fourthoffour} added.
2302 % \end{Version}
2303 % \begin{Version}{2011/02/05 v1.17}
2304 % \item
2305 % \cs{ltx@IfBoxEmpty}: an empty box may have non-zero dimensions.
2306 % \end{Version}
2307 % \begin{Version}{2011/03/16 v1.18}
2308 % \item
2309 % \cs{ltx@ifclasslater} fixed.
2310 % \end{Version}
2311 % \begin{Version}{2011/04/14 v1.19}
2312 % \item
2313 % \cs{ltx@ifnextchar}: detection of optional spaces modified.
2314 % \item
2315 % \cs{ltx(Loc,Glob)(Toks,Dimen,Skip)(A,B,C,D,E)} added.
2316 % \end{Version}
2317 % \begin{Version}{2011/04/18 v1.20}
2318 % \item
2319 % \cs{ltx@ifnextchar} with conditional support (thanks GL for
2320 % bug report).
2321 % \end{Version}
2322 % \begin{Version}{2011/08/22 v1.21}
2323 % \item
2324 % \cs{ltx@GlobalPrependToMacro}, \cs{ltx@LocalPrependToMacro} added
2325 % (feature request of Martin M\"unch).
2326 % \end{Version}
2327 % \begin{Version}{2011/11/09 v1.22}
2328 % \item
2329 % \cs{ltx@carsecond}, \cs{ltx@carthird}, \cs{ltx@carfourth},
2330 % \cs{ltx@CarNumth} added.
2331 % \item
2332 % \cs{ltx@cdrzero}, \cs{ltx@cdr}, \cs{ltx@cdrtwo}, cs{ltx@cdrthree},
2333 % \cs{ltx@cdrfour}, \cs{ltx@CdrNum} modified to retain braces and spaces.
2334 % They are expandable in two expansion steps.
2335 % \end{Version}
2336 % \begin{Version}{2016/05/16 v1.23}
2337 % \item
2338 % Documentation updates.
2339 % \end{Version}
2340 % \begin{Version}{2019/12/15 v1.24}
2341 % \item
2342 % Documentation updates.
2343 % \end{Version}
2344 % \begin{Version}{2020-05-10 v1.25}
2345 % \item Changed the definitions of \cs{ltx@iffilelater}, \cs{ltx@ifpackagelater}
2346 % and \cs{ltx@ifclasslater} to support dates in ISO format in same way as the
2347 % LaTeX kernel does it since 2017. The commands now use the same test as the
2348 % LaTeX kernel. \cs{pdfmatch} is no longer used with pdftex, and the tests for dates before
2349 % 1994 have been removed
2350 % \end{Version}
2351 % \begin{Version}{2023-12-04 v1.26}
2352 % \item corrected \cs{ltx@ifl@t@r} for plain.
2353 % \end{Version}
2354 % \end{History}
2355 %
2356 % \PrintIndex
2357 %
2358 % \Finale
2359 \endinput