summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/latex')
-rw-r--r--Master/texmf-dist/source/latex/caption/caption.dtx11
-rw-r--r--Master/texmf-dist/source/latex/caption/caption3.dtx55
-rw-r--r--Master/texmf-dist/source/latex/caption/captiondoc.cls121
3 files changed, 157 insertions, 30 deletions
diff --git a/Master/texmf-dist/source/latex/caption/caption.dtx b/Master/texmf-dist/source/latex/caption/caption.dtx
index 7f48c88b5a3..8315f780b3c 100644
--- a/Master/texmf-dist/source/latex/caption/caption.dtx
+++ b/Master/texmf-dist/source/latex/caption/caption.dtx
@@ -31,7 +31,7 @@
%
% \fi
%
-% \CheckSum{2922}
+% \CheckSum{2923}
%
% \iffalse
%<*driver>
@@ -4521,14 +4521,14 @@
%
% Identify the current version of the package.
% \begin{macrocode}
-\ProvidesPackage{caption}[2023/07/28 v3.6m Customizing captions (AR)]
+\ProvidesPackage{caption}[2023/07/31 v3.6n Customizing captions (AR)]
% \end{macrocode}
%
% \subsection{Loading the kernel}
%
% Load a matching version of the \pkg{caption} kernel.
% \begin{macrocode}
-\RequirePackage{caption3}[2023/07/28] % needs v2.4c or newer
+\RequirePackage{caption3}[2023/07/31] % needs v2.4d or newer
% \end{macrocode}
%
% \subsection{Check against unknown document classes}
@@ -6082,6 +6082,7 @@
% \begin{macro}{\caption@dblarg}
% \changes{v3.1}{2007/02/05}{This macro added}
% \changes{v3.3}{2012/03/25}{Support of option \opt{list-entry} added}
+% \changes{v3.6n}{2023/07/31}{Only an empty list-entry will expand to \cs{relax}, otherwise it remains unchanged}
% A |\relax| was added compared to |\@dblarg| so |\caption{}| will be
% expanded to |\caption[\relax]{}| (and not to |\caption[]{}|).
% Furthermore support for option \opt{list-entry} was added.
@@ -6093,12 +6094,14 @@
% \end{macrocode}
% \begin{macrocode}
\newcommand\caption@xdblarg[2]{%
- #1[{#2\relax}]{#2}}
+ \caption@iftokens{#2}{#1[{#2}]{#2}}{#1[\relax]{}}}
% \end{macrocode}
% \begin{macrocode}
\long\def\caption@ydblarg#1[#2]#3{%
\caption@iflistheading{#1[{#3}]{#3}}{#1[{#2}]{#3}}}
% \end{macrocode}
+% \begin{macrocode}
+% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\caption@begin}
diff --git a/Master/texmf-dist/source/latex/caption/caption3.dtx b/Master/texmf-dist/source/latex/caption/caption3.dtx
index 9f3e21b2967..be2a46ec676 100644
--- a/Master/texmf-dist/source/latex/caption/caption3.dtx
+++ b/Master/texmf-dist/source/latex/caption/caption3.dtx
@@ -31,7 +31,7 @@
%
% \fi
%
-% \CheckSum{3865}
+% \CheckSum{3853}
%
% \iffalse
%<*driver>
@@ -232,7 +232,7 @@
%
% Identify the current version of the package.
% \begin{macrocode}
-\ProvidesPackage{caption3}[2023/07/28 v2.4c caption3 kernel (AR)]
+\ProvidesPackage{caption3}[2023/07/31 v2.4d caption3 kernel (AR)]
% \end{macrocode}
%
% \section{Generic helpers}
@@ -586,6 +586,20 @@
% \end{macrocode}
% \end{macro}
%
+% \begin{macro}{\caption@iftokens}
+% \changes{v2.4d}{2023/07/31}{This macro added}
+% |\caption@iftokens|\marg{arg}\marg{yes-code}\marg{no-code}\\
+% This helper command checks if the given argument contains one or more tokens, i.e. is not empty.
+% \begin{macrocode}
+\newcommand\caption@iftokens[1]{%
+ \if\relax\detokenize{#1}\relax
+ \expandafter\@secondoftwo
+ \else
+ \expandafter\@firstoftwo
+ \fi}
+% \end{macrocode}
+% \end{macro}
+%
% \begin{macro}{\caption@AtBeginDocument}
% \changes{v1.1}{2007/04/13}{This macro and its usage added}
% \changes{v1.2e}{2010/01/09}{Adapted to the combine document class}
@@ -1553,6 +1567,7 @@
% \changes{v1.3}{2010/11/07}{Support for option \opt{calcmargin} added}
% \changes{v2.3}{2021/01/17}{Renamed from \cs{setcaptionmargin} to \cs{caption@setmargin}; sets \cs{caption@width} or \cs{caption@leftmargin} and \cs{caption@rightmargin} now}
% \changes{v2.3}{2021/01/19}{Only the left or right margin can be set by leaving the other value blank}
+% \changes{v2.4d}{2023/07/31}{Check for \cs{@empty} argument replaced by \cs{caption@iftokens}}
% |\caption@setmargin*|\marg{amount}\\
% sets the caption margin to the given \meta{amount}.
% \begin{macrocode}
@@ -1571,20 +1586,14 @@
% \end{macrocode}
% \begin{macrocode}
\def\caption@@@@setmargin#1,#2,#3\@nil{%
- \def\caption@tempa{#1#2}%
- \ifx\caption@tempa\@empty
- \caption@Error{Missing number}%
- \else
- \caption@@@@@setmargin{left}{#1}%
- \caption@@@@@setmargin{right}{#2}%
- \fi}
+ \caption@iftokens{#1#2}%
+ {\caption@@@@@setmargin{left}{#1}%
+ \caption@@@@@setmargin{right}{#2}}%
+ {\caption@Error{Missing number}}}
% \end{macrocode}
% \begin{macrocode}
\newcommand*\caption@@@@@setmargin[2]{%
- \def\caption@tempa{#2}%
- \ifx\caption@tempa\@empty \else
- \caption@setlength{#1margin}{#2}%
- \fi}
+ \caption@iftokens{#2}{\caption@setlength{#1margin}{#2}}{}}
% \end{macrocode}
% \end{macro}
%
@@ -2307,17 +2316,13 @@
% \changes{v1.4}{2011/10/05}{Pre-defined text format `empty' added}
% \changes{v1.7}{2015/09/16}{The text format `empty' now takes care of the \cs{label}}
% \changes{v2.3}{2020/12/26}{Clearance of \cs{caption@thelabel} replaced by \cs{caption@clrlabel}}
+% \changes{v2.4d}{2023/07/31}{Check for \cs{@empty} argument replaced by \cs{caption@iftokens}}
% \begin{macrocode}
\DeclareCaptionTextFormat{empty}{%
\caption@get@label#1\caption@makeanchor{}\@nil
\caption@thelabel\caption@clrlabel}
\long\def\caption@get@label#1\caption@makeanchor#2#3\@nil{%
- \def\caption@tempa{#2}%
- \ifx\caption@tempa\@empty
- \caption@getlabel{#1}%
- \else
- \caption@getlabel{#2}%
- \fi}
+ \caption@iftokens{#2}{\caption@getlabel{#2}}{\caption@getlabel{#1}}}
% \end{macrocode}
% \begin{macrocode}
\DeclareCaptionTextFormat{simple}{#1}
@@ -4757,6 +4762,7 @@
% \changes{v1.13}{2020/07/29}{We don't re-use existing counters anymore (This was a bad idea anyway)}
% \changes{v1.13b}{2022/04/06}{We don't re-use existing counters anymore (Part 2)}
% \changes{v2.4}{2022/04/06}{If a counter is already defined the counter source will be included in the resulting error message}
+% \changes{v2.4d}{2023/07/31}{Check for \cs{@empty} argument replaced by \cs{caption@iftokens}}
% |\DeclareCaptionSubType*|\oarg{numbering scheme}\marg{type}\\
% The starred variant provides the numbering format
% \meta{type}|.|\meta{subtype} while the non-starred variant simply uses
@@ -4839,15 +4845,12 @@
% \end{macrocode}
% \begin{macrocode}
\long\def\caption@@@declaresublistentry#1\@dottedtocline#2\caption@nil#3{%
- \def\@tempa{#1}%
% Does \l@(sub)subsection start with \@dottedtocline?
- \ifx\@tempa\@empty
-% Yes
- \caption@@@@declaresublistentry{#3}#2\caption@nil
- \else
+ \caption@iftokens{#1}%
% No
- \caption@@@@declaresublistentry{#3}@{3.8em}{3.2em}\caption@nil
- \fi}
+ {\caption@@@@declaresublistentry{#3}@{3.8em}{3.2em}\caption@nil}%
+% Yes
+ {\caption@@@@declaresublistentry{#3}#2\caption@nil}}
\@onlypreamble\caption@@@declaresublistentry
% \end{macrocode}
% \begin{macrocode}
diff --git a/Master/texmf-dist/source/latex/caption/captiondoc.cls b/Master/texmf-dist/source/latex/caption/captiondoc.cls
new file mode 100644
index 00000000000..39340af5fd5
--- /dev/null
+++ b/Master/texmf-dist/source/latex/caption/captiondoc.cls
@@ -0,0 +1,121 @@
+%%
+%% This is file `captiondoc.cls',
+%% a common document class for all caption package bundle documentations.
+%%
+%% There is no need to distribute this file in tex/latex/caption since
+%% it's of no use for the end-user, it's only needed to compile the package
+%% documentations.
+%%
+%% Copyright (C) 2023 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm)
+%%
+%% https://gitlab.com/axelsommerfeldt/caption
+%%
+%% --------------------------------------------------------------------------
+%%
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
+%% http://www.latex-project.org/lppl.txt
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2003/12/01 or later.
+%%
+%% This work has the LPPL maintenance status "maintained".
+%%
+%% This Current Maintainer of this work is Axel Sommerfeldt.
+%%
+%% This work consists of the files
+%% caption.ins, caption.dtx, caption-light.dtx, caption2.dtx, caption3.dtx,
+%% caption-ams-smf.dtx, caption-beamer.dtx, caption-elsarticle.dtx,
+%% caption-koma.dtx, caption-memoir.dtx, caption-ntg.dtx,
+%% caption-thesis.dtx, bicaption.dtx, ltcaption.dtx, subcaption.dtx,
+%% the derived files
+%% caption.sty, caption-light.sty, caption2.sty, caption3.sty,
+%% caption-ams-smf.sto, caption-beamer.sto, caption-elsarticle.sto,
+%% caption-koma.sto, caption-memoir.sto, caption-ntg.sto,
+%% caption-thesis.sto, bicaption.sty, ltcaption.sty, subcaption.sty.
+
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesClass{captiondoc}[2022/12/27 Document class used by caption documentation]
+
+\hbadness=9999 \newcount\hbadness \hfuzz=100pt % Make TeX shut up.
+
+\PassOptionsToPackage{breaklinks=true}{hyperref}
+
+\LoadClassWithOptions{ltxdoc}
+\setlength\parindent{0pt}
+\setlength\parskip{\smallskipamount}
+\addtolength\marginparwidth{15pt}
+\setlength\leftmargini{2em}% default = 2.5em
+
+\renewcommand\partname{Part}
+
+\RequirePackage{ifpdf}
+\ifpdf
+ \RequirePackage{mathptmx,courier}
+ \RequirePackage[scaled=0.90]{helvet}
+\fi
+
+\RequirePackage{hypdoc}
+\ifpdf\RequirePackage{hypdestopt}\fi
+\hypersetup{pdfstartpage={},pdfstartview={}}
+\hypersetup{breaklinks=true}
+\let\subsectionautorefname\sectionautorefname
+\let\subsubsectionautorefname\sectionautorefname
+
+\DeclareRobustCommand*\eTeX{\leavevmode\hbox{$\varepsilon$}-\TeX}
+
+\DeclareRobustCommand*\AmS{\texorpdfstring
+ {{\protect\usefont{OMS}{cmsy}{m}{n}A\kern-.1667em\lower.5ex\hbox{M}\kern-.125emS}}%
+ {AMS}}
+\DeclareRobustCommand*\KOMAScript{\textsf{K\kern.05em O\kern.05em M\kern.05em A\kern.1em-\kern.1em Script}}
+\DeclareRobustCommand*\NTG{NTG}
+\DeclareRobustCommand*\SmF{SMF}
+
+\newcommand*\NEWfeature{\NEW{New feature}}
+\newcommand*\NEWdescription{\NEW{New description}}
+\newcommand*\NEW[1]{\@ifstar{\@NEW{#1}{\vskip2pt}}{\@NEW{#1}{}}}
+\newcommand*\@NEW[3]{\MARGINSYM{#2\footnotesize#1\\#3}}
+\newcommand*\MARGINSYM[1]{\hskip 1sp \marginpar{\raggedleft\textcolor{blue}{{#1}}}}
+
+\newcommand*\LineBreak{\linebreak[3]}
+\newcommand*\PageBreak{\pagebreak[3]}
+
+\newcommand*\longref{\@ifstar{\@longref\ref}{\@longref\autoref}}
+\newcommand*\Longref{\@ifstar{\@longref\Ref}{\@longref\Autoref}}
+\def\@longref#1#2{#1{#2}: \textit{\nameref{#2}}}
+
+\newcommand*\See[1]{\nopagebreak{\small (See #1)}}
+
+\newenvironment{Options}[1]%
+ {\list{}{\renewcommand\makelabel[1]{\texttt{##1}\hfil}%
+ \settowidth\labelwidth{\texttt{#1\space}}%
+ \setlength\leftmargin{10pt}%
+ \addtolength\leftmargin{\labelwidth}%
+ \addtolength\leftmargin{\labelsep}}}%
+ {\endlist}
+
+\newcommand*\purerm[1]{{\upshape\mdseries\rmfamily #1}}
+\newcommand*\puresf[1]{{\upshape\mdseries\sffamily #1}}
+\newcommand*\purett[1]{{\upshape\mdseries\ttfamily #1}}
+\let\cls\puresf \let\pkg\puresf
+\let\env\purett \let\opt\purett
+
+\newcommand*\csmarg[1]{\texttt{\char`\{#1\char`\}}}
+\newcommand*\csoarg[1]{\texttt{\char`\[#1\char`\]}}
+\newcommand*\issue[2][GitLab]{#1 issue~\##2}
+\newcommand*\version[2][]{v$#2$}
+\newcommand*\changenote[1]{}
+
+\RequirePackage{marvosym}
+\newcommand*\INFO{\@ifstar{\@INFO{}}{\@INFO{\vbox to \ht\strutbox}}}
+\newcommand*\@INFO[1]{\MARGINSYM{#1{\LARGE\Info}}}
+
+\RequirePackage[alpine]{ifsym}
+\newenvironment{background}{\par\bigskip\csname background*\endcsname}{\csname endbackground*\endcsname}
+\newenvironment{background*}{\small\MARGINSYM{\Mountain}\ignorespaces}{\par}
+
+\RequirePackage[bottom]{footmisc}
+
+\endinput
+