summaryrefslogtreecommitdiff
path: root/macros/latex/base/ltmeta.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/base/ltmeta.dtx')
-rw-r--r--macros/latex/base/ltmeta.dtx34
1 files changed, 31 insertions, 3 deletions
diff --git a/macros/latex/base/ltmeta.dtx b/macros/latex/base/ltmeta.dtx
index cc3e62811d..410f6459f5 100644
--- a/macros/latex/base/ltmeta.dtx
+++ b/macros/latex/base/ltmeta.dtx
@@ -16,7 +16,7 @@
%<*driver>
% \fi
\ProvidesFile{ltmeta.dtx}
- [2024/05/16 v1.0b LaTeX Kernel (Document Metadata)]
+ [2024/09/21 v1.0c LaTeX Kernel (Document Metadata)]
% \iffalse
%
\documentclass{l3doc}
@@ -152,11 +152,16 @@
% we provide also the new interface commands of the hyperref package
% for the creation of targets.
% \changes{v1.0b}{2022/05/17}{Default definition for targets added}
+% \changes{v1.0c}{2024/09/21}{Added tagging support}
% \begin{macro}{\MakeLinkTarget}
% \begin{macro}{\LinkTargetOn}
% \begin{macro}{\LinkTargetOff}
% \begin{macro}{\NextLinkTarget}
% \begin{macrocode}
+%<latexrelease>\IncludeInRelease{2024/11/01}%
+%<latexrelease> {\MakeLinkTarget}{Record target name for tagging support}%
+\ExplSyntaxOn
+\int_new:N\g__kernel_target_int
\NewDocumentCommand\MakeLinkTarget{sO{}m}{%
\ifvmode
\special{}%
@@ -164,8 +169,31 @@
\@savsf\spacefactor
\smash{}%
\spacefactor\@savsf
- \fi}
-\NewDocumentCommand\LinkTargetOn{}{}
+ \fi
+ \IfBooleanTF {#1}
+ {
+ \tl_gset:Ne \@currentHref {#3}
+ }
+ {
+ \int_gincr:N\g__kernel_target_int
+ \tl_gset:Ne \@currentHref {target*.\int_use:N\g__kernel_target_int}
+ }
+ \UseTaggingSocket{recordtarget}
+ }
+\ExplSyntaxOff
+%<latexrelease>\EndIncludeInRelease
+%<latexrelease>\IncludeInRelease{2022/06/01}%
+%<latexrelease> {\MakeLinkTarget}{Record target name for tagging support}%
+%<latexrelease>\NewDocumentCommand\MakeLinkTarget{sO{}m}{%
+%<latexrelease> \ifvmode
+%<latexrelease> \special{}%
+%<latexrelease> \else
+%<latexrelease> \@savsf\spacefactor
+%<latexrelease> \smash{}%
+%<latexrelease> \spacefactor\@savsf
+%<latexrelease> \fi}
+%<latexrelease>\EndIncludeInRelease
+ \NewDocumentCommand\LinkTargetOn{}{}
\NewDocumentCommand\LinkTargetOff{}{}
\NewDocumentCommand\NextLinkTarget{m}{}
% \end{macrocode}