diff options
author | Karl Berry <karl@freefriends.org> | 2024-06-04 20:04:32 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2024-06-04 20:04:32 +0000 |
commit | 719c0852409803b7f2ca5c56a00fb9f7a71ec849 (patch) | |
tree | e19a5dae1068513a64095030019c0ff5fac7f77f /Master/texmf-dist/source/latex-dev/tools | |
parent | bde8e15257ba37627e88088426e19138ec236e41 (diff) |
latex2e-dev (3jun24)
git-svn-id: svn://tug.org/texlive/trunk@71433 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex-dev/tools')
7 files changed, 234 insertions, 50 deletions
diff --git a/Master/texmf-dist/source/latex-dev/tools/array.dtx b/Master/texmf-dist/source/latex-dev/tools/array.dtx index 66c40a52675..e77ef0a3bf1 100644 --- a/Master/texmf-dist/source/latex-dev/tools/array.dtx +++ b/Master/texmf-dist/source/latex-dev/tools/array.dtx @@ -25,9 +25,10 @@ %% Package `array' to use with LaTeX 2e %% Copyright (C) 1989-1998 Frank Mittelbach, all rights reserved. %<+package>\NeedsTeXFormat{LaTeX2e}[1995/06/01] -%<+package>\providecommand\DeclareRelease[3]{} -%<+package>\providecommand\DeclareCurrentRelease[2]{} %<+package> +% For anything before 2016-10-06 we load the 2016 version and hope for the best: +%<+package>\DeclareRelease{}{1994-06-01}{array-2016-10-06.sty} +% %<+package>\DeclareRelease{}{2016-10-06}{array-2016-10-06.sty} %<+package>\DeclareRelease{v2.4}{2020-02-10}{array-2020-02-10.sty} %<+package>\DeclareRelease{v2.5}{2023-11-01}{array-2023-11-01.sty} @@ -38,7 +39,7 @@ % \begin{macrocode} %<+package>\NeedsTeXFormat{LaTeX2e}[2024/06/01] %<+package>\ProvidesPackage{array} -%<+package> [2023/12/11 v2.6a Tabular extension package (FMi)] +%<+package> [2024/05/23 v2.6c Tabular extension package (FMi)] % % \fi % @@ -1371,6 +1372,7 @@ Bug reports can be opened (category \texttt{#1}) at\\% % % \begin{macro}{\insert@column} % \begin{macro}{\@sharp} +% \begin{macro}{\textonly@unskip} % We now define the macro =\insert@column= which will do % this work for us. % \begin{macrocode} @@ -1399,8 +1401,9 @@ Bug reports can be opened (category \texttt{#1}) at\\% % \changes{v2.0e}{1991/02/07}{Added \{\} around \cs{@sharp} for new ftsel} % \changes{v2.0h}{1992/06/22}{Removed \{\} again in favour of % \cs{d@llarbegin}} +% \changes{v2.6b}{2024/04/08}{Do not \cs{unskip} if in math mode (gh/1323)} % \begin{macrocode} - \ignorespaces \@sharp \unskip + \ignorespaces \@sharp \textonly@unskip % \end{macrocode} % Then the second \textsf{token} register follows whose number should % be saved in =\count@=. @@ -1420,6 +1423,12 @@ Bug reports can be opened (category \texttt{#1}) at\\% \UseTaggingSocket{tbl/cell/end}% } % \end{macrocode} +% Do the unskip only if we are in hmode: +% \changes{v2.6b}{2024/04/08}{Do not \cs{unskip} if in math mode (gh/1323)} +% \begin{macrocode} +\protected\def\textonly@unskip{\ifhmode\unskip\fi} +% \end{macrocode} +% \end{macro} % \end{macro} % \end{macro} % diff --git a/Master/texmf-dist/source/latex-dev/tools/l3sys-query.dtx b/Master/texmf-dist/source/latex-dev/tools/l3sys-query.dtx index d8c92adac1d..3cba5da4a62 100644 --- a/Master/texmf-dist/source/latex-dev/tools/l3sys-query.dtx +++ b/Master/texmf-dist/source/latex-dev/tools/l3sys-query.dtx @@ -15,7 +15,7 @@ %<driver> \ProvidesFile{l3sys-query.drv} % \fi % \ProvidesFile{l3sys-query.dtx} - [2024-03-13 v1.0a LaTeX2e interface for l3sys file queries] + [2024-03-28 v1.0a LaTeX2e interface for l3sys file queries] % % \iffalse %<*driver> @@ -122,7 +122,7 @@ % programming interface described in the following section, which allows % the sequence to be manipulated before being used. % -% The defined keys map vey closely to the options of the +% The defined keys map very closely to the options of the % \texttt{l3sys-query} command which is described in % section~\ref{sec:lua}. % @@ -138,7 +138,7 @@ % The key \texttt{type} accepts \texttt{d} or \texttt{f}. % % \item -% The key \texttt{exclude} accepts a glob (or Lua pattern) mathing +% The key \texttt{exclude} accepts a glob (or Lua pattern) matching % files to be excluded. The package arranges that the quoting of the % argument is automatically added if unrestricted shell escape is % enabled. diff --git a/Master/texmf-dist/source/latex-dev/tools/longtable.dtx b/Master/texmf-dist/source/latex-dev/tools/longtable.dtx index 5a23f3ecb39..cc3a939e7ad 100644 --- a/Master/texmf-dist/source/latex-dev/tools/longtable.dtx +++ b/Master/texmf-dist/source/latex-dev/tools/longtable.dtx @@ -27,8 +27,9 @@ \ProvidesFile{longtable.dtx} %</dtx> %<package>\NeedsTeXFormat{LaTeX2e}[1995/06/01] -%<package>\providecommand\DeclareRelease[3]{} -%<package>\providecommand\DeclareCurrentRelease[2]{} +%<package> +% Try the 2020 version for any rollback before that date: +%<package>\DeclareRelease{}{1994-06-01}{longtable-2020-01-07.sty} %<package> %<package>\DeclareRelease{v4.13}{2020-01-02}{longtable-2020-01-07.sty} %<package>\DeclareCurrentRelease{}{2020-02-07} @@ -37,7 +38,7 @@ %<driver> \ProvidesFile{longtable.drv} % \fi % \ProvidesFile{longtable.dtx} - [2023-12-16 v4.19 Multi-page Table package (DPC)] + [2024-04-26 v4.20 Multi-page Table package (DPC)] % % \iffalse %<*driver> diff --git a/Master/texmf-dist/source/latex-dev/tools/multicol.dtx b/Master/texmf-dist/source/latex-dev/tools/multicol.dtx index 9c680ab5639..4d864480029 100644 --- a/Master/texmf-dist/source/latex-dev/tools/multicol.dtx +++ b/Master/texmf-dist/source/latex-dev/tools/multicol.dtx @@ -86,11 +86,10 @@ %<*dtx> \ProvidesFile{multicol.dtx} %</dtx> -%<package>\NeedsTeXFormat{LaTeX2e}[2018-04-01] -%<package> -%<package>\providecommand\DeclareRelease[3]{} -%<package>\providecommand\DeclareCurrentRelease[2]{} %<package> +% For any rollback before 2017 load the 2017 version and hope for the best: +%<package>\DeclareRelease{}{1994-06-01}{multicol-2017-04-11.sty} +% %<package>\DeclareRelease{}{2017-04-11}{multicol-2017-04-11.sty} %<package>\DeclareRelease{v1.8}{2019-10-01}{multicol-2019-10-01.sty} %<package>\DeclareCurrentRelease{}{2021-11-15} @@ -99,7 +98,7 @@ %<driver> \ProvidesFile{multicol.drv} % \fi % \ProvidesFile{multicol.dtx} - [2024/01/29 v1.9g multicolumn formatting (FMi)] + [2024/05/23 v1.9h multicolumn formatting (FMi)] % % % diff --git a/Master/texmf-dist/source/latex-dev/tools/showkeys.dtx b/Master/texmf-dist/source/latex-dev/tools/showkeys.dtx index aba96a7eabe..b6717950a77 100644 --- a/Master/texmf-dist/source/latex-dev/tools/showkeys.dtx +++ b/Master/texmf-dist/source/latex-dev/tools/showkeys.dtx @@ -22,16 +22,15 @@ % \fi % \iffalse %% File: showkeys.dtx Copyright (C) 1992-1997 David Carlisle -%% File: showkeys.dtx Copyright (C) 2006-2023 David Carlisle, LaTeX Project +%% File: showkeys.dtx Copyright (C) 2006-2024 David Carlisle, LaTeX Project % %<*dtx> \ProvidesFile{showkeys.dtx} %</dtx> %<package>\NeedsTeXFormat{LaTeX2e} %<package> -%<package>\providecommand\DeclareRelease[3]{} -%<package>\providecommand\DeclareCurrentRelease[2]{} -%<package> +% For every rollback request before 2022 use the 2014 version: +%<package>\DeclareRelease{}{1994-06-01}{showkeys-2014-10-28.sty} %<package>\DeclareRelease{}{2014-10-28}{showkeys-2014-10-28.sty} %<package>\DeclareCurrentRelease{}{2022-06-01} %<package> @@ -39,7 +38,7 @@ %<driver> \ProvidesFile{showkeys.drv} % \fi % \ProvidesFile{showkeys.dtx} - [2023/12/16 v3.20 Show cite and label keys (DPC, MH)] + [2024/05/23 v3.21 Show cite and label keys (DPC, MH)] % % \iffalse %<*driver> diff --git a/Master/texmf-dist/source/latex-dev/tools/varioref.dtx b/Master/texmf-dist/source/latex-dev/tools/varioref.dtx index f25c5241887..40b3038074f 100644 --- a/Master/texmf-dist/source/latex-dev/tools/varioref.dtx +++ b/Master/texmf-dist/source/latex-dev/tools/varioref.dtx @@ -33,14 +33,15 @@ %% % %<package>\NeedsTeXFormat{LaTeX2e}[1995/05/16] -%<package>\providecommand\DeclareRelease[3]{} -%<package>\providecommand\DeclareCurrentRelease[2]{} %<package> +% +% For any rollback before 2019 load the 2016 version and hope for the best: +%<package>\DeclareRelease{}{1994-06-01}{varioref-2016-02-16.sty} %<package>\DeclareRelease{}{2016-02-16}{varioref-2016-02-16.sty} %<package>\DeclareCurrentRelease{}{2019-10-01} %<package> %<package>\ProvidesPackage{varioref} -%<package> [2024/01/15 v1.6f package for extended references (FMi)] +%<package> [2024/05/23 v1.6g package for extended references (FMi)] % \fi % %% diff --git a/Master/texmf-dist/source/latex-dev/tools/xr.dtx b/Master/texmf-dist/source/latex-dev/tools/xr.dtx index 3914cebcd98..daa0778b363 100644 --- a/Master/texmf-dist/source/latex-dev/tools/xr.dtx +++ b/Master/texmf-dist/source/latex-dev/tools/xr.dtx @@ -21,14 +21,49 @@ % % \fi % \iffalse -%% File: xr.dtx Copyright (C) 1993-2019 David Carlisle +%% File: xr.dtx Copyright (C) 1993-2024 David Carlisle % %<package>\NeedsTeXFormat{LaTeX2e} +%<package>\DeclareRelease{v5}{2023-07-04}{xr-2023-07-04.sty} +%<package>\DeclareCurrentRelease{}{2024-04-10} %<package>\ProvidesPackage{xr} -%<package> [2023-07-04 v5.06 eXternal References (DPC)] +%<package> [2024-04-10 v6.00 eXternal References (DPC)] % %<*driver> -\documentclass{ltxdoc} +\documentclass{l3doc} +% currently missing in l3doc, copied from array.dtx +\makeatletter +\def\MaintainedBy#1{\gdef\@maintainedby{#1}} +\let\@maintainedby\@empty +\def\MaintainedByLaTeXTeam#1{% +{\gdef\@maintainedby{% +This file is maintained by the \LaTeX{} Project team.\\% +Bug reports can be opened (category \texttt{#1}) at\\% +\url{https://latex-project.org/bugs.html}.}}} +\def\@maketitle{% + \newpage + \null + \vskip 2em% + \begin{center}% + \let \footnote \thanks + {\LARGE \@title \par}% + \vskip 1.5em% + {\large + \lineskip .5em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1em% + {\large \@date}% + \ifx\@maintainedby\@empty + \else + \vskip 1em% + \fbox{\fbox{\begin{tabular}{@{}l@{}}\@maintainedby\end{tabular}}}% + \fi + \end{center}% + \par + \vskip 1.5em} +\makeatother \usepackage{xr} \GetFileInfo{xr.sty} \begin{document} @@ -50,44 +85,113 @@ % % \changes{v5.00}{1993/07/07} % {First DPC version (by agreement with J-PD). New mechanism -% (\cmd{\read} instead of \cmd\input).} +% (\cs{read} instead of \cs{input}).} % % \changes{v5.01}{1993/07/20}{Fix bug added by DPC, v5.00 did not import -% aux files of \cmd\include'ed files. (Reported by J-PD)} +% aux files of \cs{include}'ed files. (Reported by J-PD)} % % \changes{v5.02}{1994/05/28}{Update for LaTeX2e} % \changes{v5.03}{2018/10/01}{Fix for conditionals in aux file} % \changes{v5.05}{2019/07/20}{include xcite} +% \changes{v6.00}{2024/04/10}{merge with xr-hyper} % % % This package implements a system for eXternal References. -% +% Version 6.00 merges the \pkg{xr} package and the \pkg{xr-hyper} package. +% \pkg{xr-hyper} was developed to support the +% extended label syntax of the \pkg{hyperref} package and to enable active links +% to the external documents. +% In the \LaTeX{} release 2023-06-01 the label syntax of \pkg{hyperref} +% and the \LaTeX{} kernel have been synchronized and there is no longer +% a need for two packages. The package \pkg{xr-hyper} will be +% deprecated. +% +% The previous version before the merge can be accessed with +% \begin{verbatim} +% \usepackage{xr}[=v5] +% \end{verbatim} +% or with a rollback date between 2023-07-04 and 2024-04-09 +% \begin{verbatim} +% \usepackage{xr}[=2024-04-09] +% \end{verbatim} +% +% \section{Usage} +% +% \begin{syntax} +% \cs{externaldocument}\oarg{prefix}\texttt[nocite\texttt]\marg{document}\oarg{url} +% \end{syntax} +% % If one document needs to refer to sections of another, say |aaa.tex|, % then this package may be loaded in the main file, and the command\\ % |\externaldocument{aaa}|\\ % given in the preamble. % -% Then you may use |\ref| and |\pageref| to refer to anything which has +% Then you may use |\ref| and |\pageref| (or |\nameref| if the +% package \pkg{nameref} has been loaded to refer to anything which has % been given a |\label| in either |aaa.tex| or the main document. +% It is also possible to refer to properties stored with \cs{RecordProperties}. % You may declare any number of such external documents. % % If any of the external documents, or the main document, use the same % |\label| then an error will occur as the label will be multiply % defined. To overcome this problem |\externaldocument| has an optional -% argument. If you declare |\externaldocument[A-]{aaa}|, then all +% argument \meta{prefix}. +% If you declare |\externaldocument[A-]{aaa}|, then all % references from |aaa| are prefixed by |A-|. So for instance, if a % section of |aaa| had |\label{intro}|, then this could be referenced % with |\ref{A-intro}|. The prefix need not be |A-|, it can be any % string chosen to ensure that all the labels imported from external -% files are unique. Note however that if your style declares certain -% active characters (|:| in French, |"| in German) then these -% characters can not usually be used in |\label|, and similarly may not -% be used in the optional argument to |\externaldocument|. +% files are unique. Note however that the prefix is expanded and +% so should not contain commands that are not safe in this context. % % As first suggested in Enrico Gregorio's |xcite| package, the current version % also allows |\cite| to reference |\bibitem| in the external document. % For compatibility with |xcite|, |\externalcitedocument| is made available % as an alias for |\externaldocument| +% +% Many packages have variant citation commands (natbib, +% biblatex,....) and the external document may or may not have used +% hyperref. Because of these differences the citation linking may not +% always work, it can be disabled by specifying \texttt{[nocite]} after the +% \meta{prefix}: +% \begin{verbatim} +% \externaldocument[][nocite]{aaa} +% \end{verbatim} +% +% The `document' referred to by the main argument \meta{document} is the file +% \file{document.aux} which must be somewhere on TeX's input path. +% Some packages (eg hyperref) really need to know the location of the +% final document rather than the aux file. By default this is assumed +% to be \file{document.pdf}. A package may redefine the command \cs{XR@ext} to +% change this default extension. However sometimes the final +% document may be in a position unrelated to the aux file, or the +% browser may not be able to find files at an arbitrary point in +% TeX's input path, so the final optional argument \meta{url} allows a full +% URL to the final document to be specified. +% \begin{verbatim} +% \externaldocument{aaa}[https://example.com/this/path/to/aaa.pdf] +% \end{verbatim} +% +% The package stores the url of the external document in the label data. It can +% e.g. be retrieved with the \pkg{refcount} package +% +% \begin{verbatim} +% \usepackage{refcount,xr} +% \externaldocument{aaa} +% ... +% \getrefbykeydefault{intro}{url}{??} %prints aaa.pdf or ?? +% \end{verbatim} +% +% \pkg{xr} supports also the properties introduced in \LaTeX{} 2023-11-01. +% Here the url of the external document is stored in the \texttt{xr-url} property. +% +% \begin{verbatim} +% \usepackage{xr} +% \externaldocument{aaa} %aaa contains \RecordProperties{intro}{page} +% ... +% \RefProperty{intro}{page} %gives page number +% \RefProperty{intro}{xr-url} %gives aaa.pdf +% \end{verbatim} % % \MaybeStop{} % @@ -98,20 +202,74 @@ % \end{macrocode} % % Check for the optional argument. +% \changes{v6.00}{2024-04-10}{Copied over extended definition of xr-hyper} % \begin{macrocode} -\def\externaldocument{\@ifnextchar[\XR@{\XR@[]}} +\def\externaldocument{\@testopt\XR@cite{}} \let\externalcitedocument\externaldocument +\def\XR@cite[#1]{\@testopt{\XR@[#1]}{}} +\def\XR@[#1][#2]#3{\@testopt{\XR@@{#1}{#2}{#3}}{#3.\XR@ext}} +% \end{macrocode} +% +% \subsection{helper definitions} +% \changes{v6.00}{2024-04-10}{new, copied over from xr-hyper} +% To test the second optional argument +% \begin{macrocode} +\def\XR@@nocite{nocite} +% \end{macrocode} +% Needed in the processing +% \begin{macrocode} +\long\def\@gobblefour #1#2#3#4{} +\long\def\@firstoffour #1#2#3#4{#1} +\long\def\@secondoffour#1#2#3#4{#2} +\long\def\@thirdoffour #1#2#3#4{#3} +\long\def\@fourthoffour #1#2#3#4{#4} +% \end{macrocode} +% The url is added as fifth argument. The command used here is +% \cs{XR@addURL}. The command is more complicated as needed +% as it tries to handle also older documents with +% \cs{newlabel}'s with two arguments. +% \begin{macrocode} +\def\XR@addURL#1{\XR@@dURL#1{}{}{}{}\\} +\def\XR@@dURL#1#2#3#4#5\\{% + \unexpanded{{#1}{#2}{#3}{#4}}{\XR@URL}% + }% +% \end{macrocode} +% +% \subsection{Variables} +% \changes{v6.00}{2024-04-10}{new, copied over from xr-hyper} +% Default file extension: +% \begin{macrocode} +\providecommand\XR@ext{pdf} % \end{macrocode} % -% Save the optional prefix. Start processing the first |aux| file. -% \changes{v5.06}{2020-05-10}{Remove leading and trailing sapces from +% Save the optional prefix. Start processing the first |aux| file. +% \changes{v6.00}{2024-04-10}{copied over the new extended internal command from xr-hyper. +% It prepends the directory name.} +% Olivier Michel pointed out that +% if the aux file was not on texinputs you could not always go +% \cs{externaldocument}{/some/path/to/file} +% specifically that worked if file.aux was a `simple' document with +% one aux file, but if \cs{include} had been used, the `sub' aux files +% would not be found by xr in the remote directory. +% This version calls \cs{filename@parse} to get the directory name of the +% remote directory, which is then explicitly prepended to the names of +% any included aux files. +% \changes{v5.06}{2020-05-10}{Remove leading and trailing spaces from % the filename (gh/2223)} % \begin{macrocode} -\def\XR@[#1]#2{{% +\def\XR@@#1#2#3[#4]{{% \makeatletter \def\XR@prefix{#1}% - \set@curr@file{#2}% - \expandafter\XR@next\@curr@file.aux\relax\\}} + \def\XR@nocite{#2}% + \ifx\XR@nocite\XR@@nocite + \let\XR@bibcite\vadjust + \else + \let\XR@bibcite\bibcite + \fi + \def\XR@URL{#4}% + \set@curr@file{#3}% + \filename@parse\@curr@file + \XR@next\@curr@file.aux\relax\\}} % \end{macrocode} % % Process the next |aux| file in the list and remove it from the head of @@ -161,23 +319,40 @@ % \end{macrocode} % % Look at the first token of the line. -% If it is |\newlabel|, do the |\newlabel|. If it is |\@input|, add the -% filename to the list of files to process. Otherwise ignore. +% If it is |\newlabel|, define \cs{r@}\meta{label}, ensure that it has +% five label data argument and add the url as the last one. +% If it is |\@input|, add the +% filename to the list of files to process. +% If it is |\bibcite|, call a |\bibcite|. +% If it is |\new@label@record| add the url and then call it. +% Otherwise ignore. % Go around the loop if not at end of file. Finally process the next % file in the list. % % 2018 update: make sure the arguments are handled outside the |\ifx| test, +% \changes{v6.00}{2024-04-10}{copied over extended definition from xr-hyper} % \begin{macrocode} \long\def\XR@test#1#2#3#4\XR@{% - \let\XR@tempa\@gobbletwo + \let\XR@tempa\@gobblefour \ifx#1\newlabel - \let\XR@tempa\@firstoftwo - \else\ifx#1\bibcite - \let\XR@tempa\@firstoftwo + \let\XR@tempa\@firstoffour + \else\ifx#1\XR@bibcite + \let\XR@tempa\@secondoffour \else\ifx#1\@input - \let\XR@tempa\@secondoftwo - \fi\fi\fi - \XR@tempa{#1{\XR@prefix#2}{#3}}{\edef\XR@list{\XR@list#2\relax}}% + \let\XR@tempa\@thirdoffour + \else\ifx#1\new@label@record + \let\XR@tempa\@fourthoffour + \fi\fi\fi\fi + \XR@tempa + {% + \expandafter\protected@xdef\csname r@\XR@prefix#2\endcsname{\XR@addURL{#3}}% + }% + {\expandafter\bibcite\expandafter{\XR@prefix#2}{#3}}% + {\edef\XR@list{\XR@list\filename@area#2\relax}}% + {% + \edef\next{\noexpand\new@label@record{\XR@prefix#2}{\unexpanded{#3}{xr-url}{\XR@URL}}}% + \next + } \ifeof\@inputcheck\expandafter\XR@aux \else\expandafter\XR@read\fi} % \end{macrocode} |