Skip to content

Commit

Permalink
guard against fancyhdr patch
Browse files Browse the repository at this point in the history
  • Loading branch information
u-fischer committed Jan 1, 2025
1 parent ad67b97 commit 783ed19
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 6 deletions.
6 changes: 4 additions & 2 deletions testfiles-luatex/test-struct-user.lvt
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,15 @@
\usepackage{fancyhdr}
\pagestyle{fancy}
\fancyhf{}

\makeatletter
\ExplSyntaxOn
%Avoid killing of para hooks:
\def\f@nch@clear@par@hook:n#1{}
\cfoot{\leavevmode\tag_mc_end_push:\tagmcbegin{artifact=pagination}\thepage\tagmcend\tag_mc_begin_pop:n{artifact}}

\pdfmanagement_add:nnn {Catalog}{Lang}{(en-UK)}
\pdfmanagement_add:nnn {Info}{Title}{(Title)}
\ExplSyntaxOff
\ExplSyntaxOff\makeatletter
\begin{document}\showoutput
\START

Expand Down
6 changes: 5 additions & 1 deletion testfiles-luatex/testauxtree.lvt
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,13 @@
\fancyhf{}

\ExplSyntaxOn
\makeatletter
%Avoid killing of para hooks:
\def\f@nch@clear@par@hook:n#1{}

\cfoot{\leavevmode\tag_mc_end_push:\tagmcbegin{artifact=pagination}\thepage\tagmcend\tag_mc_begin_pop:n{artifact}}
\pdfmanagement_add:nnn{Info}{Title}{(title)}
\ExplSyntaxOff
\ExplSyntaxOff\makeatother

\begin{document}\showoutput
\START
Expand Down
5 changes: 4 additions & 1 deletion testfiles-pdftex/test-mc-manual-para-split.lvt
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,15 @@
\fancyhf{}

\ExplSyntaxOn
\makeatletter
%Avoid killing of para hooks:
\def\f@nch@clear@par@hook:n#1{}
\pdfmanagement_add:nnn {Catalog} {Lang}{(en-UK)}
\pdfmanagement_add:nnn {Info} {Title}{(Title)}

\cfoot{\leavevmode\tag_mc_end_push:\tagmcbegin{artifact=pagination}\thepage\tagmcend\tag_mc_begin_pop:n{artifact}}

\ExplSyntaxOff
\ExplSyntaxOff\makeatother
\textheight=3cm
\begin{document}\showoutput
\START
Expand Down
5 changes: 4 additions & 1 deletion testfiles-pdftex/test-struct-user.lvt
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,14 @@
\fancyhf{}

\ExplSyntaxOn
\makeatletter
%Avoid killing of para hooks:
\def\f@nch@clear@par@hook:n#1{}
\cfoot{\leavevmode\tag_mc_end_push:\tagmcbegin{artifact=pagination}\thepage\tagmcend\tag_mc_begin_pop:n{artifact}}

\pdfmanagement_add:nnn {Catalog}{Lang}{(en-UK)}
\pdfmanagement_add:nnn {Info}{Title}{(Title)}
\ExplSyntaxOff
\ExplSyntaxOff\makeatother
\begin{document}\showoutput
\START
\tagstructbegin{tag=Sect}
Expand Down
5 changes: 4 additions & 1 deletion testfiles-pdftex/testauxtree.lvt
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,12 @@
\fancyhf{}

\ExplSyntaxOn
\makeatletter
%Avoid killing of para hooks:
\def\f@nch@clear@par@hook:n#1{}
\cfoot{\leavevmode\tag_mc_end_push:\tagmcbegin{artifact=pagination}\thepage\tagmcend\tag_mc_begin_pop:n{artifact}}
\pdfmanagement_add:nnn{Info}{Title}{(title)}
\ExplSyntaxOff
\ExplSyntaxOff\makeatother

\begin{document}\showoutput
\START
Expand Down
4 changes: 4 additions & 0 deletions testfiles/test-fancyhdr.lvt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
\input{regression-test}
\documentclass{article}
\usepackage{fancyhdr}
\makeatletter\ExplSyntaxOn
%Avoid fancyhdr killing of para hooks:
\def\f@nch@clear@par@hook:n#1{}
\makeatother\ExplSyntaxOff
\pagestyle{fancy}
\lhead{some \emph{text} }
\lfoot{some \emph{text} }
Expand Down

0 comments on commit 783ed19

Please sign in to comment.