summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/acrotex/insdljs.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/acrotex/insdljs.dtx')
-rw-r--r--macros/latex/contrib/acrotex/insdljs.dtx23
1 files changed, 13 insertions, 10 deletions
diff --git a/macros/latex/contrib/acrotex/insdljs.dtx b/macros/latex/contrib/acrotex/insdljs.dtx
index b32a727083..dc756a1ed2 100644
--- a/macros/latex/contrib/acrotex/insdljs.dtx
+++ b/macros/latex/contrib/acrotex/insdljs.dtx
@@ -608,7 +608,10 @@
% \changes{v2.3a}{2016/07/31}{Added luatex85 definition of \string\cs{pdfpageref}}
% \begin{macrocode}
\ifpdf\ifx\pdfextension\@undefined\else
+ \protected\def\pdfcatalog{\pdfextension catalog } % l3
\protected\def\pdfnames{\pdfextension names }
+ \protected\def\pdfobj{\pdfextension obj } % l3
+ \protected\def\pdflastobj{\numexpr\pdffeedback lastobj\relax} % l3
\def\pdfpageref{\pdffeedback pageref}\fi\fi
% \end{macrocode}
% The critical JavaScript files are no longer distributed with this package,
@@ -700,10 +703,10 @@
\def\AEB@psMrk{[%]
\space}
\ifx\dl@reqJS\dl@YES
- \def\dl@@reqJS{/Type/Requirement/S/EnableJavaScripts}
+ \def\dl@@reqJS{/Requirements[<</Type/Requirement/S/EnableJavaScripts>>]}
\ifpdf\pdfcatalog{\dl@@reqJS}\else
- \ifxetex\immediate\@pdfm@mark{put @catalog <<\dl@@reqJS>>}\else
- \literalps@out{\AEB@psMrk{Catalog} <<\dl@@reqJS>> /PUT pdfmark}\fi\fi
+ \ifxetex\immediate\special{pdf:put @catalog <<\dl@@reqJS>>}\else
+ \literalps@out{\AEB@psMrk{Catalog} <<\dl@@reqJS>> /PUT\space pdfmark}\fi\fi
\fi
% \end{macrocode}
% Added switch to mark whether djs is inserted
@@ -1324,7 +1327,7 @@
\edef\addActionObj{\the\pdflastobj\space 0 R}}%
\else\ifxetex
\def\aeb@addActionCode{\immediate
- \@pdfm@mark{obj @objAddActionObj
+ \special{pdf:obj @objAddActionObj
<< \aebpopentoks\aebp@rightDelimiters >> }}%
\def\addActionObj{@objAddActionObj}%
\else % postscript
@@ -1348,7 +1351,7 @@
\aeb@addActionCode
\ifpdf\pdfcatalog{\dljs@OpenActions}\else
\ifxetex\immediate
- \@pdfm@mark{put @catalog <<\dljs@OpenActions>>}\else
+ \special{pdf:put @catalog <<\dljs@OpenActions>>}\else
\literalps@out{\AEB@psMrk
{Catalog} <<\dljs@OpenActions>> /PUT pdfmark}\fi\fi\egroup}
% \end{macrocode}
@@ -1398,11 +1401,11 @@
% For \textsf{dvipdfm}
% \begin{macrocode}
\def\@OAction@dvipdfm{\ifx\isOpenAction\dl@YES
- \@pdfm@mark{put @thispage << /AA << /O << \theFirstAction\space
+ \special{pdf:put @thispage << /AA << /O << \theFirstAction\space
\opentoks\@rightDelimiters >> \@CloseAction >> >>}\fi
}
\def\@POAction@dvipdfm{%
- \@pdfm@mark{put @thispage << /AA << \@thisOpenAction
+ \special{pdf:put @thispage << /AA << \@thisOpenAction
\@thisCloseAction >> >>}%
}
% \end{macrocode}
@@ -2227,7 +2230,7 @@
% \begin{macrocode}
\ifpdf\pdfcatalog{\dljs@willDidActions}\else
\ifxetex\immediate
- \@pdfm@mark{put @catalog <<\dljs@willDidActions>>}\else
+ \special{pdf:put @catalog <<\dljs@willDidActions>>}\else
\literalps@out{\AEB@psMrk
{Catalog} <<\dljs@willDidActions>> /PUT pdfmark}\fi\fi
}
@@ -2539,9 +2542,9 @@ if(typeof \detectdljs\space == "undefined")\jsR\jsT
% \begin{macrocode}
\def\setDLJSRef@dvipdfm
{%
- \immediate\@pdfm@mark{obj @objnames %
+ \immediate\special{pdf:obj @objnames %
<< /Names [\the\importfdftoks] >> }%
- \@pdfm@mark{put @names %
+ \special{pdf:put @names %
<< /JavaScript @objnames >> }%
}
% \end{macrocode}