From 57831804ee8e7fcaeb03975ab9b5a6daa8ba04e8 Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Tue, 22 Jun 2021 13:50:37 +0900 Subject: docassembly (new) --- .../latex/docassembly/examples/attach-files.tex | 31 ++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 texmf-dist/doc/latex/docassembly/examples/attach-files.tex (limited to 'texmf-dist/doc/latex/docassembly/examples/attach-files.tex') diff --git a/texmf-dist/doc/latex/docassembly/examples/attach-files.tex b/texmf-dist/doc/latex/docassembly/examples/attach-files.tex new file mode 100644 index 00000000..6bec57ab --- /dev/null +++ b/texmf-dist/doc/latex/docassembly/examples/attach-files.tex @@ -0,0 +1,31 @@ +\documentclass{article} +\usepackage{docassembly} +\usepackage{lipsum} + +\hypersetup{pdfpagemode=UseAttachments} + +% Look in the Adobe Acrobat JavaScript manual under the doc.importDataObject to see all the possible parameters. +\begin{docassembly} +% Or use \attachFile instead of \importDataObject +var retn = \importDataObject({ + cName: "job", + cDIPath: "\jobname.tex" +}); +% The next line creates a meaningful description of the attachment +if (retn) this.getDataObject("job").description="Source file for this PDF"; +% You can have more than one file attachments +var retn = \attachFile({ + cName: "AdobeDon", + cDIPath: "graphics/AdobeDon.pdf" +}); +% The next line creates a meaningful description of the attachment +if (retn) this.getDataObject("AdobeDon").description="The one and only AdobeDon"; +% ... +\executeSave(); +\end{docassembly} + +\begin{document} + +\lipsum[1-30] + +\end{document} \ No newline at end of file -- cgit v1.2.3