[latex3-commits] [git/LaTeX3-latex3-pdfresources] develop: make destination name accessible (c749fe6)
Ulrike Fischer
fischer at troubleshooting-tex.de
Fri Jul 9 00:27:23 CEST 2021
Repository : https://github.com/latex3/pdfresources
On branch : develop
Link : https://github.com/latex3/pdfresources/commit/c749fe6d3586033e72884ba978148aaf3fd01453
>---------------------------------------------------------------
commit c749fe6d3586033e72884ba978148aaf3fd01453
Author: Ulrike Fischer <fischer at troubleshooting-tex.de>
Date: Fri Jul 9 00:27:23 2021 +0200
make destination name accessible
>---------------------------------------------------------------
c749fe6d3586033e72884ba978148aaf3fd01453
hyperref-generic.dtx | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/hyperref-generic.dtx b/hyperref-generic.dtx
index 8bd0e10..9c6f858 100644
--- a/hyperref-generic.dtx
+++ b/hyperref-generic.dtx
@@ -2070,7 +2070,9 @@
% \end{function}
% \pkg{hyperref} adds a group with \cs{Hy at colorlink}, we move this outside the link
-% so that it groups the context hook too.
+% so that it groups the context hook too. We store again the destination name in the
+% public tl |\l_hyp_current_dest_name_tl| so that the hook code can make use of
+% it
% \begin{macrocode}
\cs_new_protected:Npn \hyper at link #1 #2 #3 %#1 context, #2=destination name, #3 content
@@ -2079,6 +2081,7 @@
{
\Hy at VerboseLinkStart{#1}{#2}
\group_begin:
+ \tl_set:Nn \l_hyp_current_dest_name_tl {#2}
\hook_use:n {hyp/link/#1}
\@@_link_goto_begin:nw {#2}#3\Hy at xspace@end
\@@_link_goto_end:
@@ -2094,6 +2097,7 @@
{
\Hy at VerboseLinkStart{#1}{#2}% only for debug
\group_begin:
+ \tl_set:Nn \l_hyp_current_dest_name_tl {#2}
\hook_use:n {hyp/link/#1}
\@@_link_goto_begin:nw {#2}
}
More information about the latex3-commits
mailing list.