[latex3-commits] [git/LaTeX3-latex3-pdfresources] testlinkstuff: AF entry, part AcroForm, adapted testfiles (e7dd316)
Ulrike Fischer
fischer at troubleshooting-tex.de
Sat May 25 00:33:31 CEST 2019
Repository : https://github.com/latex3/pdfresources
On branch : testlinkstuff
Link : https://github.com/latex3/pdfresources/commit/e7dd3168988ecc8000267e35bc17c3e890cb465e
>---------------------------------------------------------------
commit e7dd3168988ecc8000267e35bc17c3e890cb465e
Author: Ulrike Fischer <fischer at troubleshooting-tex.de>
Date: Sat May 25 00:33:31 2019 +0200
AF entry, part AcroForm, adapted testfiles
>---------------------------------------------------------------
e7dd3168988ecc8000267e35bc17c3e890cb465e
pageresources.tex | 8 +-
pdfresources.dtx | 61 ++++++++--
testfiles/metadata.luatex.tpf | 6 +-
testfiles/metadata.tpf | 6 +-
testfiles/pgfpatches.luatex.tpf | 200 ++++++++++++++++----------------
testfiles/pgfpatches.tpf | 58 ++++-----
testfiles/viewerpreferences.luatex.tpf | 175 ++++++++++++++++++++++++++++
7 files changed, 364 insertions(+), 150 deletions(-)
diff --git a/pageresources.tex b/pageresources.tex
index 0561347..fe65f14 100644
--- a/pageresources.tex
+++ b/pageresources.tex
@@ -92,7 +92,9 @@ new values are stored in a prop, and at every change the register is updated. Th
\item TemplateInstantiated (name),
\item PresSteps (dict),
\item UserUnit (number),
- \item VP (dict).
+ \item VP (array of dict).
+ \item OutputIntents (pdf 2.0) (array of dictionaries)
+ \item AF (pdf 2.0) (array of dictionaries, associated files, important probably for accessibility)
\end{enumerate}
\end{itemize}
\begin{verbatim}
@@ -135,9 +137,13 @@ new values are stored in a prop, and at every change the register is updated. Th
Most values are simple and can be handled similar to pdfpagesattr. The content of Trans can be a rather complicated dict, but only one transition per page makes sense, so it is ok if one package \enquote{wins}. It is theoretically possible that the AA entry should combine content from two sources (e.g. two javascript commands) but imho it should be then the task of the packages/the users to coordinate this.
+The AF-entry needs probably a dedicated setter function. OutputIntents perhaps too.
+
It must be decided when to copy the property into pdfpageattr. Atbeginshipout?
\section{pdfpageresources}
+(perhaps should be handled as an instance for a resource dictionary, entries ExtGState,
+ColorSpace, Pattern, Shading, XObject, Font, ProcSet, Properties, see e.g. /DR entry in AcroForm).
\begin{itemize}
\item token register, is added to the Resources dictionary of all \emph{following} pages.
\item non-additive: A new call overwrites the content of the register (but not automatic entries like Font or XObject).
diff --git a/pdfresources.dtx b/pdfresources.dtx
index 4e5f498..899bcc7 100644
--- a/pdfresources.dtx
+++ b/pdfresources.dtx
@@ -294,7 +294,7 @@
% register at every change. This also allows to test for unwanted changes.
% through uses of the primitives.
% Open is the question if one need more shipout hooks to set e.g. Rotate on specific
-% pages.
+% pages. Open is the setter for /AF (and perhaps /OutputIntents).
% See also https://tex.stackexchange.com/questions/479812/extension-of-rotating-package-to-set-pdf-rotation
%
% \begin{macrocode}
@@ -758,6 +758,9 @@
% There is probably no way to test what has already been added to the catalog,
% so doublettes can only be avoided with ``don't do it''.
% \subsubsection{Simple values}
+% \enquote{Simple} values are values that can be sensibly set only once. When set a second time
+% the new value overwrites the first value. The value itself can be something simple like
+% a boolean but also a complicated dictionary.
% Simple values can be added with \cs{pdf_catalog_gput:nn}. This will add the value to
% a prop. The prop is then pushed to the catalog at the end of the document.
% Entries which can be added like this are
@@ -798,17 +801,52 @@
}
%</package>
% \end{macrocode}
-%% open: AcroForm, AF (array of dictionaries, pdf 2.0, associated files, important for accessibility),
-%% Threads, AA (dict, additional-actions),
-%% open but unclear: Names. Is created automatically (for the Dests subdict), but no
-%% other use found in the texmf tree. So perhaps later.
-%% open not so important: Dests (only pdf 1.1, later subdict of Names), SpiderInfo (dict),
-%% PieceInfo (dict), (dict, pdf 1.5, permissions), Legal (dict, pdf 1.5)
-%% Requirements (array, pdf 1.7), Extensions (dict, pdf 2.0), DSS (dict, pdf 2.0),
-%% DPartRoot, (dict, pdf 2.0)
-%% resolved: OutputIntents, OCProperties, ViewerPreferences,
+%^^A open: AcroForm, Threads, AA (dict, additional-actions),
+%^^A open but unclear: Names. Is created automatically (for the Dests subdict), but no
+%^^A other use found in the texmf tree. So perhaps later.
+%^^A open not so important: Dests (only pdf 1.1, later subdict of Names), SpiderInfo (dict),
+%^^A PieceInfo (dict), (dict, pdf 1.5, permissions), Legal (dict, pdf 1.5)
+%^^A Requirements (array, pdf 1.7), Extensions (dict, pdf 2.0), DSS (dict, pdf 2.0),
+%^^A DPartRoot, (dict, pdf 2.0)
+%^^A resolved: OutputIntents, OCProperties, ViewerPreferences, AF (array of dictionaries, pdf 2.0,
+%^^A associated files, important for accessibility)
% \subsubsection{catalog, special cases}
-%
+% \paragraph{AcroForm}
+% AcroForm is a rather complicated case: It is a dictionary with a number of fields.
+% \begin{itemize}
+% \item the majorary are field which count as \enquote{simple}:
+% /NeedAppearances (boolean), /SigFlags (integer), /DA (string), /Q (integer),
+% /XFA (stream). From these only /NeedAppearances is actually in use. In pdf 2.0
+% /NeedAppearances is deprecated, it is then required that every widget has
+% an appearance streams.
+% \item Two fields are arrays: /Fields and /CO. New values should be \emph{added}.
+% \item /DR is a resource dictionary.
+%^^A possible implementation: Prop for the general object, seq for /Fields, /CO
+%^^A with \pdf_catalog_AcroForm_Fields_append, \pdf_catalog_AcroForm_Fields_append.
+%^^A for /DR we perhaps need a general "resource dictionary" template, that can
+%^^A be reused in other places (pageresources).
+% \end{itemize}
+% \paragraph{AF (Associated files, pdf 2.0)}
+% This is simply an array of dictionaries / indirect references to file specification
+% dictionaries. The implementation is similar to the OutputIntents later. We will
+% decide later if tools to create the file specification dictionaries are needed.
+% \begin{macrocode}
+%<*package>
+\seq_new:N\g_@@_catalog_AF_seq
+
+\cs_new_protected:Npn\pdf_catalog_AF_gput:n #1
+ {
+ \tl_if_empty:nTF { #1 }
+ {
+ \msg_none:nnn { pdf }{ empty-value }{ AF }
+ }
+ {
+ \seq_gput_right:Nn \g_@@_catalog_AF_seq { #1 }
+ }
+ }
+
+%</package>
+% \end{macrocode}
% \paragraph{ViewerPreferences}
% This is a dictionary with various entries. So we setup a prop that can be filled and is pushed to
% the catalog / an object later.
@@ -948,6 +986,7 @@
\AtEndDocument
{
\@@_catalog_array_gpush:n {OutputIntents} %OutputIntents
+ \@@_catalog_array_gpush:n {AF} %AF
\@@_catalog_OCProperties_gpush: %OCProperties
\@@_catalog_ViewerPreferences_gpush: %ViewerPreferences
\prop_map_function:NN \g_@@_catalog_prop \driver_pdf_catalog_gput:nn
diff --git a/testfiles/metadata.luatex.tpf b/testfiles/metadata.luatex.tpf
index 0ccfa4a..0d20a56 100644
--- a/testfiles/metadata.luatex.tpf
+++ b/testfiles/metadata.luatex.tpf
@@ -351,7 +351,7 @@ endobj
<< /Dests 31 0 R >>
endobj
33 0 obj
-<< /Type /Catalog /Pages 18 0 R /Names 32 0 R /OCProperties 19 0 R/ViewerPreferences 20 0 R/Metadata 10 0 R/PageMode /UseOutlines/PageLayout /SinglePage/Lang () /OpenAction 11 0 R >>
+<< /Type /Catalog /Pages 18 0 R /Names 32 0 R /OCProperties 19 0 R/ViewerPreferences 20 0 R/Metadata 10 0 R/PageMode /UseOutlines/PageLayout /SinglePage /OpenAction 11 0 R >>
endobj
34 0 obj
<< /Producer (LuaTeX)/Author (Ulrike Fischer)/Title (A test of metadata)/Creator (LaTeX with hyperref) /Trapped /False >>
@@ -392,9 +392,9 @@ xref
0000038276 00000 n
0000038393 00000 n
0000038429 00000 n
-0000038628 00000 n
+0000038620 00000 n
trailer
<< /Size 35 /Root 33 0 R /Info 34 0 R >>
startxref
-38766
+38758
%%EOF
diff --git a/testfiles/metadata.tpf b/testfiles/metadata.tpf
index 5921e84..e0ac9c3 100644
--- a/testfiles/metadata.tpf
+++ b/testfiles/metadata.tpf
@@ -277,7 +277,7 @@ endobj
/Type /Catalog
/Pages 18 0 R
/Names 29 0 R
-/OCProperties 19 0 R/ViewerPreferences 20 0 R/Metadata 10 0 R/PageMode /UseOutlines/PageLayout /SinglePage/Lang ()
+/OCProperties 19 0 R/ViewerPreferences 20 0 R/Metadata 10 0 R/PageMode /UseOutlines/PageLayout /SinglePage
/OpenAction 11 0 R
>>
endobj
@@ -320,12 +320,12 @@ xref
0000036898 00000 n
0000037011 00000 n
0000037047 00000 n
-0000037246 00000 n
+0000037238 00000 n
trailer
<< /Size 32
/Root 30 0 R
/Info 31 0 R
>>
startxref
-37384
+37376
%%EOF
diff --git a/testfiles/pgfpatches.luatex.tpf b/testfiles/pgfpatches.luatex.tpf
index 40c28b8..f2f741b 100644
--- a/testfiles/pgfpatches.luatex.tpf
+++ b/testfiles/pgfpatches.luatex.tpf
@@ -7,32 +7,37 @@ endobj
<< /Type/OCG/Name(Print)/Usage<</Print<</PrintState/ON>> /View<</ViewState/OFF>> >> >>
endobj
12 0 obj
-<< /S /GoTo /D [ 13 0 R /Fit ] >>
+[ 9 0 R 10 0 R ]
endobj
-14 0 obj
+11 0 obj
+<< /OFF[10 0 R]/AS[<</Event/View/OCGs 12 0 R/Category[/View]>><</Event/Print/OCGs 12 0 R/Category[/Print]>><</Event/Export/OCGs 12 0 R/Category[/Print]>>] >>
+endobj
+13 0 obj
+<< /S /GoTo /D [ 14 0 R /Fit ] >>
+endobj
+15 0 obj
<< /Type /Pattern /PatternType 1 /PaintType 2 /TilingType 1 /BBox [-0.99628 -0.99628 3.9851 3.9851] /XStep 2.98883 /YStep 2.98883 /Resources << >> /Length 43 >>
stream
q 0.3985 w 0.0 0.0 m 3.08846 3.08846 l S Q
endstream
endobj
-15 0 obj
+16 0 obj
<< /Type /Pattern /PatternType 1 /PaintType 1 /TilingType 1 /BBox [0.0 0.0 11.33871 11.33871] /XStep 11.33871 /YStep 11.33871 /Resources << >> /Length 103 >>
stream
q 0.0 0.0 11.6222 11.6222 re f 0.8 g 0.0 0.0 5.66934 5.66934 re 5.66934 5.66934 5.66934 5.66934 re f Q
endstream
endobj
-17 0 obj
-<< /Length 1110 >>
+18 0 obj
+<< /Length 905 >>
stream
0 g 0 G
0 g 0 G
0 g 0 G
BT
/F25 9.96264 Tf
-1 0 0 1 148.712 657.235 Tm [<0048006E006E003F>28<00760054006E0051>-28<002B003B006E006000320037006E001C00600060001C>28<0076006E00510023>-28<0044004E>-333<0079>-333<005F>-333<00520079>-333<0079>-333<005F>]TJ
-1 0 0 1 148.712 645.28 Tm [<0023002300230023>]TJ
+1 0 0 1 148.712 657.235 Tm [<0023002300230023>]TJ
ET
-1 0 0 1 152.033 636.646 cm
+1 0 0 1 152.033 648.601 cm
q
0 G
0 g
@@ -58,7 +63,7 @@ Q
Q
n
Q
-1 0 0 1 0 -11.956 cm
+1 0 0 1 0 -11.955 cm
q
0 G
0 g
@@ -84,7 +89,7 @@ Q
Q
n
Q
-1 0 0 1 -3.321 -32.663 cm
+1 0 0 1 -3.321 -32.664 cm
q
0 G
0 g
@@ -108,7 +113,7 @@ Q
n
Q
0 g 0 G
-1 0 0 1 -148.712 -592.027 cm
+1 0 0 1 -148.712 -603.982 cm
BT
/F25 9.96264 Tf
1 0 0 1 303.133 89.365 Tm [<0052>]TJ
@@ -116,25 +121,28 @@ BT
ET
endstream
endobj
-13 0 obj
-<< /Type /Page /Contents 17 0 R /Resources 16 0 R /MediaBox [ 0 0 612 792 ] /Parent 21 0 R >>
+14 0 obj
+<< /Type /Page /Contents 18 0 R /Resources 17 0 R /MediaBox [ 0 0 612 792 ] /Parent 22 0 R >>
endobj
-18 0 obj
-<< /D [ 13 0 R /XYZ 132.768 705.06 null ] >>
+19 0 obj
+<< /D [ 14 0 R /XYZ 132.768 705.06 null ] >>
endobj
20 0 obj
-<< /D [ 13 0 R /XYZ 133.768 655.183 null ] >>
+<< /D [ 14 0 R /XYZ 133.768 667.198 null ] >>
endobj
-16 0 obj
-<< /ExtGState 1 0 R /ColorSpace 2 0 R /Pattern 3 0 R /Shading 4 0 R /Properties 5 0 R /Font << /F25 19 0 R >> /ProcSet [ /PDF /Text ] >>
+17 0 obj
+<< /ExtGState 1 0 R /ColorSpace 2 0 R /Pattern 3 0 R /Shading 4 0 R /Properties 5 0 R /Font << /F25 21 0 R >> /ProcSet [ /PDF /Text ] >>
endobj
-22 0 obj
+23 0 obj
<< /Type /Pattern /PatternType 1 /PaintType 1 /TilingType 1 /BBox [0.0 0.0 7.97021 7.97021] /XStep 7.97021 /YStep 7.97021 /Resources << >> /Length 1052 >>
stream
q 0.6875 0.76562 0.86718 rg 0.0 0.0 7.97021 7.97021 re f 0.93437 0.93828 0.94336 rg 2.98883 1.74348 m 2.98883 2.29372 2.54279 2.73976 1.99255 2.73976 c 1.4423 2.73976 0.99628 2.29372 0.99628 1.74348 c 0.99628 1.19324 1.4423 0.74721 1.99255 0.74721 c 2.54279 0.74721 2.98883 1.19324 2.98883 1.74348 c h 1.99255 1.74348 m 6.97394 5.72859 m 6.97394 6.27882 6.5279 6.72487 5.97766 6.72487 c 5.42741 6.72487 4.98138 6.27882 4.98138 5.72859 c 4.98138 5.17834 5.42741 4.73232 5.97766 4.73232 c 6.5279 4.73232 6.97394 5.17834 6.97394 5.72859 c h 5.97766 5.72859 m f 0.54062 0.56796 0.60352 rg 2.98883 2.24162 m 2.98883 2.79185 2.54279 3.2379 1.99255 3.2379 c 1.4423 3.2379 0.99628 2.79185 0.99628 2.24162 c 0.99628 1.69138 1.4423 1.24535 1.99255 1.24535 c 2.54279 1.24535 2.98883 1.69138 2.98883 2.24162 c h 1.99255 2.24162 m 6.97394 6.22673 m 6.97394 6.77696 6.5279 7.223 5.97766 7.223 c 5.42741 7.223 4.98138 6.77696 4.98138 6.22673 c 4.98138 5.67648 5.42741 5.23045 5.97766 5.23045 c 6.5279 5.23045 6.97394 5.67648 6.97394 6.22673 c h 5.97766 6.22673 m f Q
endstream
endobj
-25 0 obj
+24 0 obj
+<< /OCGs [9 0 R 10 0 R]/D 11 0 R >>
+endobj
+27 0 obj
<< /Length 550 >>
stream
0 g 0 G
@@ -182,14 +190,14 @@ BT
ET
endstream
endobj
-24 0 obj
-<< /Type /Page /Contents 25 0 R /Resources 23 0 R /MediaBox [ 0 0 612 792 ] /Parent 21 0 R >>
-endobj
26 0 obj
-<< /D [ 24 0 R /XYZ 132.768 705.06 null ] >>
+<< /Type /Page /Contents 27 0 R /Resources 25 0 R /MediaBox [ 0 0 612 792 ] /Parent 22 0 R >>
endobj
-23 0 obj
-<< /ExtGState 1 0 R /ColorSpace 2 0 R /Pattern 3 0 R /Shading 4 0 R /Properties 5 0 R /Font << /F25 19 0 R >> /ProcSet [ /PDF /Text ] >>
+28 0 obj
+<< /D [ 26 0 R /XYZ 132.768 705.06 null ] >>
+endobj
+25 0 obj
+<< /ExtGState 1 0 R /ColorSpace 2 0 R /Pattern 3 0 R /Shading 4 0 R /Properties 5 0 R /Font << /F25 21 0 R >> /ProcSet [ /PDF /Text ] >>
endobj
1 0 obj
<< /pgf at CA0.5 << /CA 0.5 >> /pgf at ca0.5 << /ca 0.5 >> >>
@@ -198,7 +206,7 @@ endobj
<< /pgfprgb [/Pattern /DeviceRGB] >>
endobj
3 0 obj
-<< /pgfpat3 14 0 R /pgfpat13 15 0 R /pgfpat20 22 0 R >>
+<< /pgfpat3 15 0 R /pgfpat13 16 0 R /pgfpat20 23 0 R >>
endobj
4 0 obj
<< >>
@@ -206,28 +214,28 @@ endobj
5 0 obj
<< /OCView 9 0 R /OCPrint 10 0 R >>
endobj
-27 0 obj
-[ 28 [ 500 ] 35 [ 556 ] 43 [ 444 ] 50 [ 444 ] 55 [ 306 ] 59 [ 500 ] 63 [ 556 ] 68 [ 306 ] 72 [ 278 ] 78 [ 500 ] 81 [ 500 500 ] 84 [ 556 ] 95 [ 736 392 ] 107 [ 500 ] 110 [ 750 ] 116 [ 528 ] 118 [ 528 ] 121 [ 500 ] ]
-endobj
29 0 obj
-<< /Length 16 >>
+[ 35 [ 556 ] 82 [ 500 ] 107 [ 500 ] 116 [ 528 ] ]
+endobj
+31 0 obj
+<< /Length 15 >>
[BINARY STREAM]
endobj
-30 0 obj
-<< /Subtype /CIDFontType0C /Length 3000 >>
+32 0 obj
+<< /Subtype /CIDFontType0C /Length 1029 >>
[BINARY STREAM]
endobj
-28 0 obj
-<< /Type /FontDescriptor /FontName /IOOKFT+LMRoman10-Regular /Flags 4 /FontBBox [ -430 -290 1417 1127 ] /Ascent 1127 /CapHeight 683 /Descent -290 /ItalicAngle 0 /StemV 93 /XHeight 431 /FontFile3 30 0 R /CIDSet 29 0 R >>
+30 0 obj
+<< /Type /FontDescriptor /FontName /AIBRIS+LMRoman10-Regular /Flags 4 /FontBBox [ -430 -290 1417 1127 ] /Ascent 1127 /CapHeight 683 /Descent -290 /ItalicAngle 0 /StemV 93 /XHeight 431 /FontFile3 32 0 R /CIDSet 31 0 R >>
endobj
-31 0 obj
-<< /Length 959 >>
+33 0 obj
+<< /Length 734 >>
stream
%!PS-Adobe-3.0 Resource-CMap
%%DocumentNeededResources: ProcSet (CIDInit)
%%IncludeResource: ProcSet (CIDInit)
-%%BeginResource: CMap (TeX-IOOKFT-LMRoman10-Regular-0)
-%%Title: (TeX-IOOKFT-LMRoman10-Regular-0 TeX IOOKFT-LMRoman10-Regular 0)
+%%BeginResource: CMap (TeX-AIBRIS-LMRoman10-Regular-0)
+%%Title: (TeX-AIBRIS-LMRoman10-Regular-0 TeX AIBRIS-LMRoman10-Regular 0)
%%Version: 1.000
%%EndComments
/CIDInit /ProcSet findresource begin
@@ -235,37 +243,21 @@ stream
begincmap
/CIDSystemInfo
<< /Registry (TeX)
-/Ordering (IOOKFT-LMRoman10-Regular)
+/Ordering (AIBRIS-LMRoman10-Regular)
/Supplement 0
>> def
-/CMapName /TeX-Identity-IOOKFT-LMRoman10-Regular def
+/CMapName /TeX-Identity-AIBRIS-LMRoman10-Regular def
/CMapType 2 def
1 begincodespacerange
<0000> <FFFF>
endcodespacerange
0 beginbfrange
endbfrange
-20 beginbfchar
-<001C> <0061>
+4 beginbfchar
<0023> <0062>
-<002B> <0063>
-<0032> <0065>
-<0037> <0066>
-<003B> <0067>
-<003F> <0068>
-<0044> <006A>
-<0048> <006C>
-<004E> <0039>
-<0051> <006F>
<0052> <0031>
-<0054> <0070>
-<005F> <0052>
-<0060> <0072>
<006B> <0032>
-<006E> <005F>
<0074> <0078>
-<0076> <0079>
-<0079> <0030>
endbfchar
endcmap
CMapName currentdict /CMap defineresource pop
@@ -275,68 +267,70 @@ end
%%EOF
endstream
endobj
-19 0 obj
-<< /Type /Font /Subtype /Type0 /Encoding /Identity-H /BaseFont /IOOKFT+LMRoman10-Regular /DescendantFonts [ 32 0 R ] /ToUnicode 31 0 R >>
-endobj
-32 0 obj
-<< /Type /Font /Subtype /CIDFontType0 /BaseFont /IOOKFT+LMRoman10-Regular /FontDescriptor 28 0 R /W 27 0 R /CIDSystemInfo << /Registry (Adobe) /Ordering (Identity) /Supplement 0 >> >>
-endobj
21 0 obj
-<< /Type /Pages /Count 2 /Kids [ 13 0 R 24 0 R ] >>
-endobj
-33 0 obj
-<< /Names [ (\376\377\000D\000o\000c\000-\000S\000t\000a\000r\000t) 20 0 R (\376\377\000p\000a\000g\000e\000.\0001) 18 0 R (\376\377\000p\000a\000g\000e\000.\0002) 26 0 R ] /Limits [ (\376\377\000D\000o\000c\000-\000S\000t\000a\000r\000t) (\376\377\000p\000a\000g\000e\000.\0002) ] >>
+<< /Type /Font /Subtype /Type0 /Encoding /Identity-H /BaseFont /AIBRIS+LMRoman10-Regular /DescendantFonts [ 34 0 R ] /ToUnicode 33 0 R >>
endobj
34 0 obj
-<< /Dests 33 0 R >>
+<< /Type /Font /Subtype /CIDFontType0 /BaseFont /AIBRIS+LMRoman10-Regular /FontDescriptor 30 0 R /W 29 0 R /CIDSystemInfo << /Registry (Adobe) /Ordering (Identity) /Supplement 0 >> >>
+endobj
+22 0 obj
+<< /Type /Pages /Count 2 /Kids [ 14 0 R 26 0 R ] >>
endobj
35 0 obj
-<< /Type /Catalog /Pages 21 0 R /Names 34 0 R /OCProperties <</OCGs 11 0 R/D<</OFF[10 0 R]/AS[<</Event/View/OCGs 11 0 R/Category[/View]>><</Event/Print/OCGs 11 0 R/Category[/Print]>><</Event/Export/OCGs 11 0 R/Category[/Print]>>]>>>> /OpenAction 12 0 R >>
+<< /Names [ (Doc-Start) 20 0 R (page.1) 19 0 R (page.2) 28 0 R ] /Limits [ (Doc-Start) (page.2) ] >>
endobj
36 0 obj
+<< /Dests 35 0 R >>
+endobj
+37 0 obj
+<< /Type /Catalog /Pages 22 0 R /Names 36 0 R /OCProperties 24 0 R/PageMode /UseOutlines /OpenAction 13 0 R >>
+endobj
+38 0 obj
<< /Producer (LuaTeX)/Creator (LaTeX with hyperref) /Trapped /False >>
endobj
xref
-0 37
+0 39
0000000006 65535 f
-0000004570 00000 n
-0000004644 00000 n
+0000004624 00000 n
0000004698 00000 n
-0000004770 00000 n
-0000004792 00000 n
+0000004752 00000 n
+0000004824 00000 n
+0000004846 00000 n
0000000007 00000 f
0000000008 00000 f
-0000000011 00000 f
+0000000000 00000 f
0000000020 00000 n
0000000121 00000 n
-0000000000 00000 f
+0000000257 00000 n
0000000224 00000 n
-0000001998 00000 n
-0000000274 00000 n
-0000000523 00000 n
-0000002231 00000 n
-0000000828 00000 n
-0000002108 00000 n
-0000009490 00000 n
-0000002169 00000 n
-0000009844 00000 n
-0000002385 00000 n
-0000004416 00000 n
-0000004245 00000 n
-0000003635 00000 n
-0000004355 00000 n
-0000004844 00000 n
-0000008235 00000 n
-0000005075 00000 n
-0000005151 00000 n
-0000008471 00000 n
-0000009644 00000 n
-0000009913 00000 n
-0000010214 00000 n
-0000010250 00000 n
-0000010522 00000 n
+0000000431 00000 n
+0000002000 00000 n
+0000000481 00000 n
+0000000730 00000 n
+0000002233 00000 n
+0000001035 00000 n
+0000002110 00000 n
+0000002171 00000 n
+0000007182 00000 n
+0000007536 00000 n
+0000002387 00000 n
+0000003637 00000 n
+0000004470 00000 n
+0000004299 00000 n
+0000003689 00000 n
+0000004409 00000 n
+0000004898 00000 n
+0000006152 00000 n
+0000004964 00000 n
+0000005039 00000 n
+0000006388 00000 n
+0000007336 00000 n
+0000007605 00000 n
+0000007722 00000 n
+0000007758 00000 n
+0000007885 00000 n
trailer
-<< /Size 37 /Root 35 0 R /Info 36 0 R >>
+<< /Size 39 /Root 37 0 R /Info 38 0 R >>
startxref
-10609
+7972
%%EOF
diff --git a/testfiles/pgfpatches.tpf b/testfiles/pgfpatches.tpf
index a133bb2..dc30fd3 100644
--- a/testfiles/pgfpatches.tpf
+++ b/testfiles/pgfpatches.tpf
@@ -16,9 +16,6 @@ endobj
<< /S /GoTo /D [14 0 R /Fit] >>
endobj
15 0 obj
-<< /OCGs [9 0 R 10 0 R]/D 11 0 R >>
-endobj
-16 0 obj
<<
/Type /Pattern /PatternType 1 /PaintType 2 /TilingType 1 /BBox [-0.99628 -0.99628 3.9851 3.9851] /XStep 2.98883 /YStep 2.98883 /Resources << >>
/Length 43
@@ -27,7 +24,7 @@ stream
q 0.3985 w 0.0 0.0 m 3.08846 3.08846 l S Q
endstream
endobj
-17 0 obj
+16 0 obj
<<
/Type /Pattern /PatternType 1 /PaintType 1 /TilingType 1 /BBox [0.0 0.0 11.33871 11.33871] /XStep 11.33871 /YStep 11.33871 /Resources << >>
/Length 103
@@ -36,7 +33,7 @@ stream
q 0.0 0.0 11.6222 11.6222 re f 0.8 g 0.0 0.0 5.66934 5.66934 re 5.66934 5.66934 5.66934 5.66934 re f Q
endstream
endobj
-19 0 obj
+18 0 obj
<<
/Length 870
>>
@@ -133,30 +130,30 @@ endobj
14 0 obj
<<
/Type /Page
-/Contents 19 0 R
-/Resources 18 0 R
+/Contents 18 0 R
+/Resources 17 0 R
/MediaBox [0 0 612 792]
-/Parent 23 0 R
+/Parent 22 0 R
>>
endobj
-20 0 obj
+19 0 obj
<<
/D [14 0 R /XYZ 132.768 705.06 null]
>>
endobj
-21 0 obj
+20 0 obj
<<
/D [14 0 R /XYZ 133.768 667.198 null]
>>
endobj
-18 0 obj
+17 0 obj
<<
/ExtGState 1 0 R /ColorSpace 2 0 R /Pattern 3 0 R /Shading 4 0 R /Properties 5 0 R
-/Font << /F8 22 0 R >>
+/Font << /F8 21 0 R >>
/ProcSet [ /PDF /Text ]
>>
endobj
-24 0 obj
+23 0 obj
<<
/Type /Pattern /PatternType 1 /PaintType 1 /TilingType 1 /BBox [0.0 0.0 7.97021 7.97021] /XStep 7.97021 /YStep 7.97021 /Resources << >>
/Length 1052
@@ -165,6 +162,9 @@ stream
q 0.6875 0.76562 0.86718 rg 0.0 0.0 7.97021 7.97021 re f 0.93437 0.93828 0.94336 rg 2.98883 1.74348 m 2.98883 2.29372 2.54279 2.73976 1.99255 2.73976 c 1.4423 2.73976 0.99628 2.29372 0.99628 1.74348 c 0.99628 1.19324 1.4423 0.74721 1.99255 0.74721 c 2.54279 0.74721 2.98883 1.19324 2.98883 1.74348 c h 1.99255 1.74348 m 6.97394 5.72859 m 6.97394 6.27882 6.5279 6.72487 5.97766 6.72487 c 5.42741 6.72487 4.98138 6.27882 4.98138 5.72859 c 4.98138 5.17834 5.42741 4.73232 5.97766 4.73232 c 6.5279 4.73232 6.97394 5.17834 6.97394 5.72859 c h 5.97766 5.72859 m f 0.54062 0.56796 0.60352 rg 2.98883 2.24162 m 2.98883 2.79185 2.54279 3.2379 1.99255 3.2379 c 1.4423 3.2379 0.99628 2.79185 0.99628 2.24162 c 0.99628 1.69138 1.4423 1.24535 1.99255 1.24535 c 2.54279 1.24535 2.98883 1.69138 2.98883 2.24162 c h 1.99255 2.24162 m 6.97394 6.22673 m 6.97394 6.77696 6.5279 7.223 5.97766 7.223 c 5.42741 7.223 4.98138 6.77696 4.98138 6.22673 c 4.98138 5.67648 5.42741 5.23045 5.97766 5.23045 c 6.5279 5.23045 6.97394 5.67648 6.97394 6.22673 c h 5.97766 6.22673 m f Q
endstream
endobj
+24 0 obj
+<< /OCGs [9 0 R 10 0 R]/D 11 0 R >>
+endobj
27 0 obj
<<
/Length 509
@@ -219,7 +219,7 @@ endobj
/Contents 27 0 R
/Resources 25 0 R
/MediaBox [0 0 612 792]
-/Parent 23 0 R
+/Parent 22 0 R
>>
endobj
28 0 obj
@@ -230,7 +230,7 @@ endobj
25 0 obj
<<
/ExtGState 1 0 R /ColorSpace 2 0 R /Pattern 3 0 R /Shading 4 0 R /Properties 5 0 R
-/Font << /F8 22 0 R >>
+/Font << /F8 21 0 R >>
/ProcSet [ /PDF /Text ]
>>
endobj
@@ -241,7 +241,7 @@ endobj
<< /pgfprgb [/Pattern /DeviceRGB] >>
endobj
3 0 obj
-<< /pgfpat3 16 0 R /pgfpat13 17 0 R /pgfpat20 24 0 R >>
+<< /pgfpat3 15 0 R /pgfpat13 16 0 R /pgfpat20 23 0 R >>
endobj
4 0 obj
<< >>
@@ -277,7 +277,7 @@ endobj
/FontFile 30 0 R
>>
endobj
-22 0 obj
+21 0 obj
<<
/Type /Font
/Subtype /Type1
@@ -288,7 +288,7 @@ endobj
/Widths 29 0 R
>>
endobj
-23 0 obj
+22 0 obj
<<
/Type /Pages
/Count 2
@@ -297,7 +297,7 @@ endobj
endobj
32 0 obj
<<
-/Names [(Doc-Start) 21 0 R (page.1) 20 0 R (page.2) 28 0 R]
+/Names [(Doc-Start) 20 0 R (page.1) 19 0 R (page.2) 28 0 R]
/Limits [(Doc-Start) (page.2)]
>>
endobj
@@ -309,9 +309,9 @@ endobj
34 0 obj
<<
/Type /Catalog
-/Pages 23 0 R
+/Pages 22 0 R
/Names 33 0 R
-/OCProperties 15 0 R/PageMode /UseOutlines
+/OCProperties 24 0 R/PageMode /UseOutlines
/OpenAction 13 0 R
>>
endobj
@@ -337,17 +337,17 @@ xref
0000000252 00000 n
0000000219 00000 n
0000000426 00000 n
-0000002007 00000 n
+0000001955 00000 n
0000000474 00000 n
-0000000526 00000 n
-0000000774 00000 n
-0000002234 00000 n
-0000001078 00000 n
-0000002115 00000 n
-0000002174 00000 n
+0000000722 00000 n
+0000002182 00000 n
+0000001026 00000 n
+0000002063 00000 n
+0000002122 00000 n
0000014832 00000 n
0000014972 00000 n
-0000002387 00000 n
+0000002335 00000 n
+0000003584 00000 n
0000004371 00000 n
0000004204 00000 n
0000003636 00000 n
diff --git a/testfiles/viewerpreferences.luatex.tpf b/testfiles/viewerpreferences.luatex.tpf
new file mode 100644
index 0000000..be00f53
--- /dev/null
+++ b/testfiles/viewerpreferences.luatex.tpf
@@ -0,0 +1,175 @@
+%PDF-1.5
+%ÌÕÁÔÅØÐÄÆ
+6 0 obj
+<< /Type/OCG/Name(View)/Usage<</Print<</PrintState/OFF>> /View<</ViewState/ON>> >> >>
+endobj
+7 0 obj
+<< /Type/OCG/Name(Print)/Usage<</Print<</PrintState/ON>> /View<</ViewState/OFF>> >> >>
+endobj
+9 0 obj
+[ 6 0 R 7 0 R ]
+endobj
+8 0 obj
+<< /OFF[7 0 R]/AS[<</Event/View/OCGs 9 0 R/Category[/View]>><</Event/Print/OCGs 9 0 R/Category[/Print]>><</Event/Export/OCGs 9 0 R/Category[/Print]>>] >>
+endobj
+10 0 obj
+<< /S /GoTo /D [ 11 0 R /Fit ] >>
+endobj
+12 0 obj
+<< /OCGs [6 0 R 7 0 R]/D 8 0 R >>
+endobj
+13 0 obj
+<< /HideToolbar true /NonFullScreenPageMode /UseNone /NumCopies 4 >>
+endobj
+15 0 obj
+<< /Length 142 >>
+stream
+0 g 0 G
+0 g 0 G
+BT
+/F15 9.96264 Tf
+1 0 0 1 148.712 657.235 Tm [<001C0023>-28<002B>]TJ
+0 g 0 G
+1 0 0 1 303.133 89.365 Tm [<0052>]TJ
+0 g 0 G
+ET
+endstream
+endobj
+11 0 obj
+<< /Type /Page /Contents 15 0 R /Resources 14 0 R /MediaBox [ 0 0 612 792 ] /Parent 19 0 R >>
+endobj
+16 0 obj
+<< /D [ 11 0 R /XYZ 132.768 705.06 null ] >>
+endobj
+17 0 obj
+<< /D [ 11 0 R /XYZ 133.768 667.198 null ] >>
+endobj
+14 0 obj
+<< /ExtGState 1 0 R /ColorSpace 2 0 R /Pattern 3 0 R /Shading 4 0 R /Properties 5 0 R /Font << /F15 18 0 R >> /ProcSet [ /PDF /Text ] >>
+endobj
+1 0 obj
+<< >>
+endobj
+2 0 obj
+<< >>
+endobj
+3 0 obj
+<< >>
+endobj
+4 0 obj
+<< >>
+endobj
+5 0 obj
+<< /OCView 6 0 R /OCPrint 7 0 R >>
+endobj
+20 0 obj
+[ 28 [ 500 ] 35 [ 556 ] 43 [ 444 ] 82 [ 500 ] ]
+endobj
+22 0 obj
+<< /Length 11 >>
+[BINARY STREAM]
+endobj
+23 0 obj
+<< /Subtype /CIDFontType0C /Length 955 >>
+[BINARY STREAM]
+endobj
+21 0 obj
+<< /Type /FontDescriptor /FontName /NSMWQI+LMRoman10-Regular /Flags 4 /FontBBox [ -430 -290 1417 1127 ] /Ascent 1127 /CapHeight 683 /Descent -290 /ItalicAngle 0 /StemV 93 /XHeight 431 /FontFile3 23 0 R /CIDSet 22 0 R >>
+endobj
+24 0 obj
+<< /Length 734 >>
+stream
+%!PS-Adobe-3.0 Resource-CMap
+%%DocumentNeededResources: ProcSet (CIDInit)
+%%IncludeResource: ProcSet (CIDInit)
+%%BeginResource: CMap (TeX-NSMWQI-LMRoman10-Regular-0)
+%%Title: (TeX-NSMWQI-LMRoman10-Regular-0 TeX NSMWQI-LMRoman10-Regular 0)
+%%Version: 1.000
+%%EndComments
+/CIDInit /ProcSet findresource begin
+12 dict begin
+begincmap
+/CIDSystemInfo
+<< /Registry (TeX)
+/Ordering (NSMWQI-LMRoman10-Regular)
+/Supplement 0
+>> def
+/CMapName /TeX-Identity-NSMWQI-LMRoman10-Regular def
+/CMapType 2 def
+1 begincodespacerange
+<0000> <FFFF>
+endcodespacerange
+0 beginbfrange
+endbfrange
+4 beginbfchar
+<001C> <0061>
+<0023> <0062>
+<002B> <0063>
+<0052> <0031>
+endbfchar
+endcmap
+CMapName currentdict /CMap defineresource pop
+end
+end
+%%EndResource
+%%EOF
+endstream
+endobj
+18 0 obj
+<< /Type /Font /Subtype /Type0 /Encoding /Identity-H /BaseFont /NSMWQI+LMRoman10-Regular /DescendantFonts [ 25 0 R ] /ToUnicode 24 0 R >>
+endobj
+25 0 obj
+<< /Type /Font /Subtype /CIDFontType0 /BaseFont /NSMWQI+LMRoman10-Regular /FontDescriptor 21 0 R /W 20 0 R /CIDSystemInfo << /Registry (Adobe) /Ordering (Identity) /Supplement 0 >> >>
+endobj
+19 0 obj
+<< /Type /Pages /Count 1 /Kids [ 11 0 R ] >>
+endobj
+26 0 obj
+<< /Names [ (Doc-Start) 17 0 R (page.1) 16 0 R ] /Limits [ (Doc-Start) (page.1) ] >>
+endobj
+27 0 obj
+<< /Dests 26 0 R >>
+endobj
+28 0 obj
+<< /Type /Catalog /Pages 19 0 R /Names 27 0 R /OCProperties 12 0 R/ViewerPreferences 13 0 R/PageMode /UseOutlines/PageLayout /SinglePage /OpenAction 10 0 R >>
+endobj
+29 0 obj
+<< /Producer (LuaTeX)/Creator (LaTeX with hyperref) /Trapped /False >>
+endobj
+xref
+0 30
+0000000000 65535 f
+0000001198 00000 n
+0000001220 00000 n
+0000001242 00000 n
+0000001264 00000 n
+0000001286 00000 n
+0000000020 00000 n
+0000000121 00000 n
+0000000254 00000 n
+0000000223 00000 n
+0000000423 00000 n
+0000000811 00000 n
+0000000473 00000 n
+0000000523 00000 n
+0000001044 00000 n
+0000000609 00000 n
+0000000921 00000 n
+0000000982 00000 n
+0000003541 00000 n
+0000003895 00000 n
+0000001337 00000 n
+0000002511 00000 n
+0000001401 00000 n
+0000001472 00000 n
+0000002747 00000 n
+0000003695 00000 n
+0000003957 00000 n
+0000004058 00000 n
+0000004094 00000 n
+0000004269 00000 n
+trailer
+<< /Size 30 /Root 28 0 R /Info 29 0 R >>
+startxref
+4356
+%%EOF
More information about the latex3-commits
mailing list