diff options
Diffstat (limited to 'Master/texmf-dist/source/latex/base/ltsect.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/base/ltsect.dtx | 42 |
1 files changed, 38 insertions, 4 deletions
diff --git a/Master/texmf-dist/source/latex/base/ltsect.dtx b/Master/texmf-dist/source/latex/base/ltsect.dtx index 29ea142ba6c..67974c73874 100644 --- a/Master/texmf-dist/source/latex/base/ltsect.dtx +++ b/Master/texmf-dist/source/latex/base/ltsect.dtx @@ -31,7 +31,7 @@ %%% From File: ltsect.dtx %<*driver> % \fi -\ProvidesFile{ltsect.dtx}[2020/12/05 v1.1e LaTeX Kernel (Sectioning)] +\ProvidesFile{ltsect.dtx}[2021/07/28 v1.1f LaTeX Kernel (Sectioning)] % \iffalse \documentclass{ltxdoc} \GetFileInfo{ltsect.dtx} @@ -765,7 +765,7 @@ % The |\addcontentsline{|\meta{table}|}{|\meta{type}|}{|% % \meta{entry}|}| command allows the user to add % his/her own entry to a table of contents, etc. The command adds the -% entry |\contentsline{|\meta{type}|}{|\meta{entry}|}{|\meta{page}|}| +% entry |\contentsline{|\meta{type}|}{|\meta{entry}|}{|\meta{page}|}{}| % to the |.|\meta{table} file. % % This macro is implemented as an application of |\addtocontents|. @@ -833,7 +833,7 @@ % \end{macro} % % \begin{macro}{\contentsline} -% The |\contentsline{|\meta{type}|}{|\meta{entry}|}{|\meta{page}|}| +% The |\contentsline{|\meta{type}|}{|\meta{entry}|}{|\meta{page}|}{}| % macro produces a \meta{type} entry in a table of contents, etc. % It will appear in the |.toc| or other file. For example, % The entry for subsection 1.4.3 in the table of contents for @@ -848,10 +848,44 @@ % without expanding them. % % \begin{macrocode} -\def\contentsline#1{\csname l@#1\endcsname} +%</2ekernel> +%<*2ekernel|latexrelease> +%<latexrelease>\IncludeInRelease{2021/11/15}% +%<latexrelease> {\contentsline}{Four arguments}% +% \end{macrocode} +% +% In the toc file \cs{contentsline} is followed by 4 arguments +% these days, but only the first 3 are used in the old +% interface. The fourth was by default empty and only used when +% \pkg{hyperref} was loaded. We now pick up all 4 arguments, save +% the last one away in \cs{@contentsline@destination} and then call +% the old interface. This is done to simplify the interface to +% \pkg{hyperref} and to prepare for future changes. +% \changes{v1.1f}{2021/07/28}{Pick up four arguments (gh/633)} +% \begin{macrocode} +\def\contentsline#1#2#3#4{\gdef\@contentsline@destination{#4}% + \csname l@#1\endcsname{#2}{#3}} +% \end{macrocode} +% Default definition. +% \begin{macrocode} +\let\@contentsline@destination\@empty +% \end{macrocode} +% +% \begin{macrocode} +%</2ekernel|latexrelease> +%<latexrelease>\EndIncludeInRelease +%<latexrelease>\IncludeInRelease{0000/00/00}% +%<latexrelease> {\contentsline}{Four arguments}% +%<latexrelease> +%<latexrelease>\def\contentsline#1{\csname l@#1\endcsname} +%<latexrelease>\let\@contentsline@destination\@undefined +%<latexrelease>\EndIncludeInRelease +%<*2ekernel> % \end{macrocode} % \end{macro} % +% +% % |\@dottedtocline{|\meta{level}|}{|\meta{indent}|}{|\meta{numwidth}% % |}{|\meta{title}|}{|\meta{page}|}|: % Macro to produce a table of contents line with the following |