[latex3-commits] [git/LaTeX3-latex3-hyperref] gh118: add testfiles for xr-hyper fix (ffa8392)

Ulrike Fischer fischer at troubleshooting-tex.de
Tue Apr 28 12:32:54 CEST 2020


Repository : https://github.com/latex3/hyperref
On branch  : gh118
Link       : https://github.com/latex3/hyperref/commit/ffa83922ec7dca212f61010d68d3aa5352ff5437

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

commit ffa83922ec7dca212f61010d68d3aa5352ff5437
Author: Ulrike Fischer <fischer at troubleshooting-tex.de>
Date:   Tue Apr 28 11:44:58 2020 +0200

    add testfiles for xr-hyper fix


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

ffa83922ec7dca212f61010d68d3aa5352ff5437
 ...norversion.etex.tlg => gh118-xr-hyper.etex.tlg} | 57 ++++++++++-----
 ...ersion.luatex.tlg => gh118-xr-hyper.luatex.tlg} | 62 +++++++++++------
 testfiles/gh118-xr-hyper.lvt                       | 15 ++++
 .../{38-pdfminorversion.tlg => gh118-xr-hyper.tlg} | 54 ++++++++++-----
 testfiles/gh118-xr-hyper.xetex.tlg                 | 80 ++++++++++++++++++++++
 testfiles/support/test-xr-hyper.aux                | 20 ++++++
 testfiles/support/test-xr-nohyper.aux              |  3 +
 7 files changed, 239 insertions(+), 52 deletions(-)

diff --git a/testfiles/38-pdfminorversion.etex.tlg b/testfiles/gh118-xr-hyper.etex.tlg
similarity index 62%
copy from testfiles/38-pdfminorversion.etex.tlg
copy to testfiles/gh118-xr-hyper.etex.tlg
index 746b898..e5308d9 100644
--- a/testfiles/38-pdfminorversion.etex.tlg
+++ b/testfiles/gh118-xr-hyper.etex.tlg
@@ -1,5 +1,14 @@
 This is a generated file for the l3build validation system.
 Don't change this file in any respect.
+Package hyperref Warning: Suppressing link with empty target on input line ....
+> \r at sec-no-hyper=macro:
+->{1}{1}{}{}{}.
+<recently read> \r at sec-no-hyper 
+l. ......after\show\csname r at sec-no-hyper\endcsname
+> \r at sec-hyper=macro:
+->{1}{1}{Section hyper}{section.1}{test-xr-hyper.pdf}.
+<recently read> \r at sec-hyper 
+l. ......andafter\show\csname r at sec-hyper\endcsname
 Package atveryend Info: Empty hook `BeforeClearDocument' on input line ....
 Completed box being shipped out [1]
 \vbox(633.0+0.0)x407.0
@@ -31,28 +40,44 @@ Completed box being shipped out [1]
 ....\hbox(0.0+0.0)x345.0
 ...\glue 25.0
 ...\glue(\lineskip) 0.0
-...\vbox(550.0+0.0)x345.0, glue set 527.9436fil
+...\vbox(550.0+0.0)x345.0, glue set 539.94232fil
 ....\write-{}
 ....\special{ps:SDict begin [/PageMode /UseOutlines/Page 1/View [/Fit] /DOCVIEW pd\ETC.}
 ....\special{ps:SDict begin [ {Catalog}<<>> /PUT pdfmark end}
 ....\special{ps:SDict begin H.S end}
 ....\special{ps:SDict begin 12 H.A end}
 ....\special{ps:SDict begin [/View [/XYZ H.V]/Dest (Doc-Start) cvn /DEST pdfmark e\ETC.}
-....\glue(\topskip) 3.55556
-....\hbox(6.44444+0.0)x345.0, glue set 324.99998fil
+....\glue(\topskip) 3.32141
+....\hbox(6.67859+0.0)x345.0, glue set 249.88878fil
 .....\hbox(0.0+0.0)x15.0
-.....\OT1/cmr/m/n/10 5
+.....\OT1/cmr/m/n/10 s
+.....\OT1/cmr/m/n/10 e
+.....\OT1/cmr/m/n/10 c
+.....\OT1/cmr/m/n/10 t
+.....\OT1/cmr/m/n/10 i
+.....\OT1/cmr/m/n/10 o
+.....\OT1/cmr/m/n/10 n
 .....\penalty 10000
-.....\glue(\parfillskip) 0.0 plus 1.0fil
-.....\glue(\rightskip) 0.0
-....\glue(\parskip) 0.0 plus 1.0
-....\glue(\baselineskip) 5.05556
-....\hbox(6.94444+0.0)x345.0, glue set 310.5555fil
-.....\hbox(0.0+0.0)x15.0
-.....\OT1/cmr/m/n/10 b
-.....\OT1/cmr/m/n/10 l
-.....\OT1/cmr/m/n/10 u
-.....\OT1/cmr/m/n/10 b
+.....\glue 3.33333 plus 1.66666 minus 1.11111
+.....\OT1/cmr/m/n/10 1
+.....\hbox(0.0+0.0)x0.0
+.....\glue 3.33333 plus 1.66666 minus 1.11111
+.....\special{ps:SDict begin H.S end}
+.....\hbox(6.67859+0.0)x38.38895
+......\OT1/cmr/m/n/10 s
+......\OT1/cmr/m/n/10 e
+......\OT1/cmr/m/n/10 c
+......\OT1/cmr/m/n/10 t
+......\OT1/cmr/m/n/10 i
+......\OT1/cmr/m/n/10 o
+......\OT1/cmr/m/n/10 n
+......\penalty 10000
+......\glue 3.33333 plus 1.66666 minus 1.11111
+......\OT1/cmr/m/n/10 1
+......\hbox(0.0+0.0)x0.0
+.....\hbox(0.0+0.0)x0.0, shifted -6.67859
+......\special{ps:SDict begin H.R end}
+.....\special{ps:SDict begin [/Subtype /Link/H /I/Border [0 0 1]BorderArrayPatch/Co\ETC.}
 .....\penalty 10000
 .....\glue(\parfillskip) 0.0 plus 1.0fil
 .....\glue(\rightskip) 0.0
@@ -66,9 +91,9 @@ Completed box being shipped out [1]
 ....\glue 0.0 plus 1.0fil
 .\kern 0.0
 Package atveryend Info: Empty hook `AfterLastShipout' on input line ....
-(38-pdfminorversion.aux)
+(gh118-xr-hyper.aux)
 Package atveryend Info: Empty hook `AtVeryEndDocument' on input line ....
 Package atveryend Info: Executing hook `AtEndAfterFileList' on input line ...
-Package rerunfilecheck Info: File `38-pdfminorversion.out' has not changed.
+Package rerunfilecheck Info: File `gh118-xr-hyper.out' has not changed.
 (rerunfilecheck)             Checksum: D41D8CD98F00B204E9800998ECF8427E;0.
 Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line ....
diff --git a/testfiles/38-pdfminorversion.luatex.tlg b/testfiles/gh118-xr-hyper.luatex.tlg
similarity index 56%
copy from testfiles/38-pdfminorversion.luatex.tlg
copy to testfiles/gh118-xr-hyper.luatex.tlg
index 7f4e754..13d5971 100644
--- a/testfiles/38-pdfminorversion.luatex.tlg
+++ b/testfiles/gh118-xr-hyper.luatex.tlg
@@ -1,5 +1,14 @@
 This is a generated file for the l3build validation system.
 Don't change this file in any respect.
+Package hyperref Warning: Suppressing link with empty target on input line ....
+> \r at sec-no-hyper=macro:
+->{1}{1}{}{}{}.
+<recently read> \r at sec-no-hyper 
+l. ......ndafter\show\csname r at sec-no-hyper\endcsname
+> \r at sec-hyper=macro:
+->{1}{1}{Section hyper}{section.1}{test-xr-hyper.pdf}.
+<recently read> \r at sec-hyper 
+l. ...\expandafter\show\csname r at sec-hyper\endcsname
 Package atveryend Info: Empty hook `BeforeClearDocument' on input line ....
 Completed box being shipped out [1]
 \vbox(633.0+0.0)x407.0, direction TLT
@@ -25,34 +34,47 @@ Completed box being shipped out [1]
 ....\hbox(0.0+0.0)x345.0, direction TLT
 ...\glue 25.0
 ...\glue(\lineskip) 0.0
-...\vbox(550.0+0.0)x345.0, glue set 527.9436fil, direction TLT
+...\vbox(550.0+0.0)x345.0, glue set 539.94232fil, direction TLT
 ....\write-{}
 ....\pdfdest name{Doc-Start} xyz
 ....\glue(\topskip) 3.34
-....\hbox(6.66+0.22)x345.0, glue set 325.0fil, direction TLT
+....\hbox(6.66+0.11)x345.0, glue set 249.90999fil, direction TLT
 .....\localpar
 ......\localinterlinepenalty=0
 ......\localbrokenpenalty=0
 ......\localleftbox=null
 ......\localrightbox=null
 .....\hbox(0.0+0.0)x15.0, direction TLT
-.....\TU/lmr/m/n/10 6
+.....\TU/lmr/m/n/10 s
+.....\TU/lmr/m/n/10 e
+.....\TU/lmr/m/n/10 c
+.....\discretionary (penalty 50)
+......< \TU/lmr/m/n/10 -
+.....\TU/lmr/m/n/10 t
+.....\TU/lmr/m/n/10 i
+.....\TU/lmr/m/n/10 o
+.....\TU/lmr/m/n/10 n
 .....\penalty 10000
-.....\glue(\parfillskip) 0.0 plus 1.0fil
-.....\glue(\rightskip) 0.0
-....\glue(\parskip) 0.0 plus 1.0
-....\glue(\baselineskip) 4.84
-....\hbox(6.94+0.11)x345.0, glue set 310.54001fil, direction TLT
-.....\localpar
-......\localinterlinepenalty=0
-......\localbrokenpenalty=0
-......\localleftbox=null
-......\localrightbox=null
-.....\hbox(0.0+0.0)x15.0, direction TLT
-.....\TU/lmr/m/n/10 b
-.....\TU/lmr/m/n/10 l
-.....\TU/lmr/m/n/10 u
-.....\TU/lmr/m/n/10 b
+.....\glue(\spaceskip) 3.33 plus 1.665 minus 1.11
+.....\TU/lmr/m/n/10 1
+.....\hbox(0.0+0.0)x0.0, direction TLT
+.....\glue(\spaceskip) 3.33 plus 1.665 minus 1.11
+.....\pdfstartlink(*+*)x* attr{/Border[0 0 1]/H/I/C[0 .5 .5]} action user{/Subt
+ype/Link/A<</F(test-xr-hyper.pdf)/S/GoToR/D(section.1)>>}
+.....\TU/lmr/m/n/10 s
+.....\TU/lmr/m/n/10 e
+.....\TU/lmr/m/n/10 c
+.....\discretionary (penalty 50)
+......< \TU/lmr/m/n/10 -
+.....\TU/lmr/m/n/10 t
+.....\TU/lmr/m/n/10 i
+.....\TU/lmr/m/n/10 o
+.....\TU/lmr/m/n/10 n
+.....\penalty 10000
+.....\glue(\spaceskip) 3.33 plus 1.665 minus 1.11
+.....\TU/lmr/m/n/10 1
+.....\hbox(0.0+0.0)x0.0, direction TLT
+.....\pdfendlink
 .....\penalty 10000
 .....\glue(\parfillskip) 0.0 plus 1.0fil
 .....\glue(\rightskip) 0.0
@@ -67,9 +89,9 @@ Completed box being shipped out [1]
 ....\glue 0.0 plus 1.0fil
 .\kern0.0
 Package atveryend Info: Empty hook `AfterLastShipout' on input line ....
-(38-pdfminorversion.aux)
+(gh118-xr-hyper.aux)
 Package atveryend Info: Executing hook `AtVeryEndDocument' on input line ...
 Package atveryend Info: Executing hook `AtEndAfterFileList' on input line ...
-Package rerunfilecheck Info: File `38-pdfminorversion.out' has not changed.
+Package rerunfilecheck Info: File `gh118-xr-hyper.out' has not changed.
 (rerunfilecheck)             Checksum: D41D8CD98F00B204E9800998ECF8427E;0.
 Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line ....
diff --git a/testfiles/gh118-xr-hyper.lvt b/testfiles/gh118-xr-hyper.lvt
new file mode 100644
index 0000000..68fb2ab
--- /dev/null
+++ b/testfiles/gh118-xr-hyper.lvt
@@ -0,0 +1,15 @@
+\input{regression-test}
+\documentclass{article}
+\usepackage{xr-hyper}
+\usepackage{hyperref}
+\externaldocument{test-xr-hyper}
+\externaldocument{test-xr-nohyper}
+\begin{document}
+\START
+\showoutput
+\hyperref[sec-no-hyper]{section~\ref*{sec-no-hyper}}
+\hyperref[sec-hyper]{section~\ref*{sec-hyper}}
+
+\expandafter\show\csname r at sec-no-hyper\endcsname
+\expandafter\show\csname r at sec-hyper\endcsname
+\end{document} 
\ No newline at end of file
diff --git a/testfiles/38-pdfminorversion.tlg b/testfiles/gh118-xr-hyper.tlg
similarity index 54%
copy from testfiles/38-pdfminorversion.tlg
copy to testfiles/gh118-xr-hyper.tlg
index 4680948..4d731fb 100644
--- a/testfiles/38-pdfminorversion.tlg
+++ b/testfiles/gh118-xr-hyper.tlg
@@ -1,5 +1,14 @@
 This is a generated file for the l3build validation system.
 Don't change this file in any respect.
+Package hyperref Warning: Suppressing link with empty target on input line ....
+> \r at sec-no-hyper=macro:
+->{1}{1}{}{}{}.
+<recently read> \r at sec-no-hyper 
+l. ......after\show\csname r at sec-no-hyper\endcsname
+> \r at sec-hyper=macro:
+->{1}{1}{Section hyper}{section.1}{test-xr-hyper.pdf}.
+<recently read> \r at sec-hyper 
+l. ......andafter\show\csname r at sec-hyper\endcsname
 Package atveryend Info: Empty hook `BeforeClearDocument' on input line ....
 Completed box being shipped out [1]
 \vbox(633.0+0.0)x407.0
@@ -25,24 +34,37 @@ Completed box being shipped out [1]
 ....\hbox(0.0+0.0)x345.0
 ...\glue 25.0
 ...\glue(\lineskip) 0.0
-...\vbox(550.0+0.0)x345.0, glue set 527.9436fil
+...\vbox(550.0+0.0)x345.0, glue set 539.94232fil
 ....\write-{}
 ....\pdfdest name{Doc-Start} xyz
-....\glue(\topskip) 3.55556
-....\hbox(6.44444+0.0)x345.0, glue set 324.99998fil
+....\glue(\topskip) 3.32141
+....\hbox(6.67859+0.0)x345.0, glue set 249.88878fil
 .....\hbox(0.0+0.0)x15.0
-.....\OT1/cmr/m/n/10 6
+.....\OT1/cmr/m/n/10 s
+.....\OT1/cmr/m/n/10 e
+.....\OT1/cmr/m/n/10 c
+.....\OT1/cmr/m/n/10 t
+.....\OT1/cmr/m/n/10 i
+.....\OT1/cmr/m/n/10 o
+.....\OT1/cmr/m/n/10 n
 .....\penalty 10000
-.....\glue(\parfillskip) 0.0 plus 1.0fil
-.....\glue(\rightskip) 0.0
-....\glue(\parskip) 0.0 plus 1.0
-....\glue(\baselineskip) 5.05556
-....\hbox(6.94444+0.0)x345.0, glue set 310.5555fil
-.....\hbox(0.0+0.0)x15.0
-.....\OT1/cmr/m/n/10 b
-.....\OT1/cmr/m/n/10 l
-.....\OT1/cmr/m/n/10 u
-.....\OT1/cmr/m/n/10 b
+.....\glue 3.33333 plus 1.66666 minus 1.11111
+.....\OT1/cmr/m/n/10 1
+.....\hbox(0.0+0.0)x0.0
+.....\glue 3.33333 plus 1.66666 minus 1.11111
+.....\pdfstartlink(*+*)x* attr{/Border[0 0 1]/H/I/C[0 .5 .5]} action user{/Subtype/Link/A<</F(test-xr-hyper.pdf)/S/GoToR/D(section.1)>>}
+.....\OT1/cmr/m/n/10 s
+.....\OT1/cmr/m/n/10 e
+.....\OT1/cmr/m/n/10 c
+.....\OT1/cmr/m/n/10 t
+.....\OT1/cmr/m/n/10 i
+.....\OT1/cmr/m/n/10 o
+.....\OT1/cmr/m/n/10 n
+.....\penalty 10000
+.....\glue 3.33333 plus 1.66666 minus 1.11111
+.....\OT1/cmr/m/n/10 1
+.....\hbox(0.0+0.0)x0.0
+.....\pdfendlink
 .....\penalty 10000
 .....\glue(\parfillskip) 0.0 plus 1.0fil
 .....\glue(\rightskip) 0.0
@@ -56,9 +78,9 @@ Completed box being shipped out [1]
 ....\glue 0.0 plus 1.0fil
 .\kern 0.0
 Package atveryend Info: Empty hook `AfterLastShipout' on input line ....
-(38-pdfminorversion.aux)
+(gh118-xr-hyper.aux)
 Package atveryend Info: Executing hook `AtVeryEndDocument' on input line ...
 Package atveryend Info: Executing hook `AtEndAfterFileList' on input line ...
-Package rerunfilecheck Info: File `38-pdfminorversion.out' has not changed.
+Package rerunfilecheck Info: File `gh118-xr-hyper.out' has not changed.
 (rerunfilecheck)             Checksum: D41D8CD98F00B204E9800998ECF8427E;0.
 Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line ....
diff --git a/testfiles/gh118-xr-hyper.xetex.tlg b/testfiles/gh118-xr-hyper.xetex.tlg
new file mode 100644
index 0000000..cbe1fff
--- /dev/null
+++ b/testfiles/gh118-xr-hyper.xetex.tlg
@@ -0,0 +1,80 @@
+This is a generated file for the l3build validation system.
+Don't change this file in any respect.
+Package hyperref Warning: Suppressing link with empty target on input line ....
+> \r at sec-no-hyper=macro:
+->{1}{1}{}{}{}.
+<recently read> \r at sec-no-hyper 
+l. ......after\show\csname r at sec-no-hyper\endcsname
+> \r at sec-hyper=macro:
+->{1}{1}{Section hyper}{section.1}{test-xr-hyper.pdf}.
+<recently read> \r at sec-hyper 
+l. ......andafter\show\csname r at sec-hyper\endcsname
+Package atveryend Info: Empty hook `BeforeClearDocument' on input line ....
+(../se-ascii-print.def
+File: se-ascii-print.def ....-..-.. v... stringenc: Printable ASCII characters
+)
+Completed box being shipped out [1]
+\vbox(633.0+0.0)x407.0
+.\hbox(0.0+0.0)x0.0
+..\special{pdf:docinfo<</Title()/Subject()/Creator(LaTeX with hyperref)/Author()\ETC.}
+.\vbox(0.0+0.0)x0.0, glue set - 14.99626fil
+..\kern 0.0
+..\kern 16.0
+..\kern -1.00374
+..\hbox(0.0+0.0)x0.0, glue set - 60.99626fil
+...\kern 0.0
+...\kern 62.0
+...\kern -1.00374
+...\special{pdf:dest (page.1) [@thispage /XYZ @xpos @ypos null]}
+...\penalty 10000
+...\glue 0.0 plus 1.0fil minus 1.0fil
+..\glue 0.0 plus 1.0fil minus 1.0fil
+.\glue(\lineskip) 0.0
+.\vbox(633.0+0.0)x407.0
+..\glue 16.0
+..\vbox(617.0+0.0)x345.0, shifted 62.0
+...\vbox(12.0+0.0)x345.0, glue set 12.0fil
+....\glue 0.0 plus 1.0fil
+....\hbox(0.0+0.0)x345.0
+...\glue 25.0
+...\glue(\lineskip) 0.0
+...\vbox(550.0+0.0)x345.0, glue set 539.94232fil
+....\write-{}
+....\special{pdf:docview<</OpenAction[@page1/Fit]/PageMode/UseOutlines>>}
+....\special{pdf:dest (Doc-Start) [@thispage /XYZ @xpos @ypos null]}
+....\glue(\topskip) 3.34
+....\hbox(6.66+0.10999)x345.0, glue set 249.90999fil
+.....\hbox(0.0+0.0)x15.0
+.....\TU/lmr/m/n/10 section
+.....\penalty 10000
+.....\glue 3.33 plus 1.665 minus 1.11
+.....\TU/lmr/m/n/10 1
+.....\hbox(0.0+0.0)x0.0
+.....\glue 3.33 plus 1.665 minus 1.11
+.....\special{pdf:bann<</Type/Annot/Subtype/Link/Border[0 0 1]/H/I/C[0 .5 .5]/A<</S\ETC.}
+.....\TU/lmr/m/n/10 section
+.....\penalty 10000
+.....\glue 3.33 plus 1.665 minus 1.11
+.....\TU/lmr/m/n/10 1
+.....\hbox(0.0+0.0)x0.0
+.....\special{pdf:eann}
+.....\penalty 10000
+.....\glue(\parfillskip) 0.0 plus 1.0fil
+.....\glue(\rightskip) 0.0
+....\glue -0.10999
+....\glue 0.0 plus 1.0fil
+....\glue 0.0
+....\glue 0.0 plus 0.0001fil
+...\glue(\baselineskip) 23.34
+...\hbox(6.66+0.0)x345.0, glue set 170.0fil
+....\glue 0.0 plus 1.0fil
+....\TU/lmr/m/n/10 1
+....\glue 0.0 plus 1.0fil
+.\kern 0.0
+Package atveryend Info: Empty hook `AfterLastShipout' on input line ....
+(gh118-xr-hyper.aux)
+Package atveryend Info: Empty hook `AtVeryEndDocument' on input line ....
+Package atveryend Info: Executing hook `AtEndAfterFileList' on input line ...
+Package rerunfilecheck Info: File `gh118-xr-hyper.out' has not changed.
+(rerunfilecheck)             Checksum: D41D8CD98F00B204E9800998ECF8427E;0.
+Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line ....
diff --git a/testfiles/support/test-xr-hyper.aux b/testfiles/support/test-xr-hyper.aux
new file mode 100644
index 0000000..2804033
--- /dev/null
+++ b/testfiles/support/test-xr-hyper.aux
@@ -0,0 +1,20 @@
+\relax 
+\providecommand\hyper at newdestlabel[2]{}
+\providecommand\HyperFirstAtBeginDocument{\AtBeginDocument}
+\HyperFirstAtBeginDocument{\ifx\hyper at anchor\@undefined
+\global\let\oldcontentsline\contentsline
+\gdef\contentsline#1#2#3#4{\oldcontentsline{#1}{#2}{#3}}
+\global\let\oldnewlabel\newlabel
+\gdef\newlabel#1#2{\newlabelxx{#1}#2}
+\gdef\newlabelxx#1#2#3#4#5#6{\oldnewlabel{#1}{{#2}{#3}}}
+\AtEndDocument{\ifx\hyper at anchor\@undefined
+\let\contentsline\oldcontentsline
+\let\newlabel\oldnewlabel
+\fi}
+\fi}
+\global\let\hyper at last\relax 
+\gdef\HyperFirstAtBeginDocument#1{#1}
+\providecommand\HyField at AuxAddToFields[1]{}
+\providecommand\HyField at AuxAddToCoFields[2]{}
+\@writefile{toc}{\contentsline {section}{\numberline {1}Section hyper}{1}{section.1}\protected at file@percent }
+\newlabel{sec-hyper}{{1}{1}{Section hyper}{section.1}{}}
diff --git a/testfiles/support/test-xr-nohyper.aux b/testfiles/support/test-xr-nohyper.aux
new file mode 100644
index 0000000..7779b9d
--- /dev/null
+++ b/testfiles/support/test-xr-nohyper.aux
@@ -0,0 +1,3 @@
+\relax 
+\@writefile{toc}{\contentsline {section}{\numberline {1}Section no hyper}{1}\protected at file@percent }
+\newlabel{sec-no-hyper}{{1}{1}}





More information about the latex3-commits mailing list.