[latex3-commits] [git/LaTeX3-latex3-pdfresources] testlinkstuff: storing ... (60f95d9)

Ulrike Fischer fischer at troubleshooting-tex.de
Mon Mar 11 23:54:14 CET 2019


Repository : https://github.com/latex3/pdfresources
On branch  : testlinkstuff
Link       : https://github.com/latex3/pdfresources/commit/60f95d914daf1f7e255f11a5811632a8855e1def

>---------------------------------------------------------------

commit 60f95d914daf1f7e255f11a5811632a8855e1def
Author: Ulrike Fischer <fischer at troubleshooting-tex.de>
Date:   Mon Mar 11 23:54:14 2019 +0100

    storing ...


>---------------------------------------------------------------

60f95d914daf1f7e255f11a5811632a8855e1def
 pdfresources.dtx |   29 ++++++++++++++++++++++++++++-
 1 file changed, 28 insertions(+), 1 deletion(-)

diff --git a/pdfresources.dtx b/pdfresources.dtx
index 5f06aeb..266b65e 100644
--- a/pdfresources.dtx
+++ b/pdfresources.dtx
@@ -72,8 +72,10 @@
 % \texttt{user}, \texttt{goto} and \texttt{thread}. To be able to translate this to
 % other drivers, three startlink variant are defined.
 % Variants which allow also to set the rule spec are perhaps needed too.
-% Currently only pdftex, luatex and xetex are setup.
+% Currently only pdftex, luatex and xetex are setup. Some commands can probably not be
+% implemented in all drivers.
 %    \begin{macrocode}
+
 \sys_if_engine_pdftex:T
 {
  \cs_new_protected:Nn \driver_pdf_startlink_user:nn
@@ -89,6 +91,12 @@
  {
   \pdfendlink
  }
+
+ \cs_new_protected:Nn \driver_pdf_lastlink:
+ {
+  \pdflastlink
+ }
+
 }
 
 \sys_if_engine_luatex:T
@@ -107,6 +115,11 @@
   \pdfextension endlink
  }
 
+ \cs_new_protected:Nn \driver_pdf_lastlink:
+ {
+  \numexpr\pdffeedback lastlink\relax
+ }
+
 }
 
 \sys_if_engine_xetex:T
@@ -131,6 +144,7 @@
 %    \end{macrocode}
 %
 % \subsection{Higher-level link management}
+% \subsubsection{Startlink}
 % packages like ocgx2 and tagpdf wants to add code to links/annotation created by hyperref.
 % So we need a generic command to start a pdflink which allows packages to add
 % their code to the \texttt{attr} argument through hooks.
@@ -172,4 +186,17 @@
 }
 %    \end{macrocode}
 %
+% \subsubsection{Endlink}
+% tagpdf needs to execute code at the end of the link to store the object reference etc.
+% So we need a hook. Is a hook a tl or a cs??
+%    \begin{macrocode}
+\cs_new_protected:Nn \pdf_endlink:
+ {
+  \driver_pdf_endlink:
+  \g__pdf_endlink_hook_tl % or \__pdf_endlink_hook: ???
+ }
+
+
+
+%    \end{macrocode}
 % \PrintIndex





More information about the latex3-commits mailing list