summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/pdfmanagement-testphase/output-patches-tmp-ltx.sty
blob: a6ef100742d5b3500d54d42a89fcd3b704a47bae (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
%%
%% This is file `output-patches-tmp-ltx.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% output-patches-tmp-ltx.dtx  (with options: `package')
%% 
%% Copyright (C) 2019-2021 The LaTeX Project
%% 
%% It may be distributed and/or modified under the conditions of
%% the LaTeX Project Public License (LPPL), either version 1.3c of
%% this license or (at your option) any later version.  The latest
%% version of this license is in the file:
%% 
%%    https://www.latex-project.org/lppl.txt
%% 
%% This file is part of the "LaTeX PDF management testphase bundle" (The Work in LPPL)
%% and all files in that bundle must be distributed together.
%% 
%% File: output-patches.dtx (C) Copyright 2020-2021 Frank Mittelbach
\ProvidesPackage{output-patches-tmp-ltx}
        [2021-08-20 v0.95 Temporary patches of output commands]
\RequirePackage{etoolbox}
\newcommand\@kernel@before@head{}
\newcommand\@kernel@before@foot{}
\newcommand\@kernel@after@head{}
\newcommand\@kernel@after@foot{}
\newcommand\@kernel@before@footins{}
\newcommand\@kernel@before@cclv{}
\newcommand\@mult@ptagging@hook{}

\patchcmd\@outputpage
 {\vfil\color@hbox\normalcolor\hb@xt@\textwidth{\@thehead}\color@endbox}
 {\vfil\@kernel@before@head\color@hbox\normalcolor\hb@xt@\textwidth{\@thehead}\color@endbox\@kernel@after@head}
 {\typeout{Patching header in \string\@outputpage}}{\PATCHerror }

\patchcmd\@outputpage
 {\color@hbox\normalcolor\hb@xt@\textwidth{\@thefoot}\color@endbox}
 {\@kernel@before@foot\color@hbox\normalcolor\hb@xt@\textwidth{\@thefoot}\color@endbox\@kernel@after@foot}
 {\typeout{Patching footer in \string\@outputpage}}{\PATCHerror }

\patchcmd\@makecol
    {\vskip\skip\footins}
    {\vskip\skip\footins\@kernel@before@footins}
  {\typeout{Patching \string\@makecol\space for tagging}}{\PATCHerror }


\pretocmd\@makecol{\@kernel@before@cclv}
  {\typeout{Patching \string\@makecol\space for tagging}}{\PATCHerror }
\AddToHook{package/after/multicol}{% multicol needs later loading
  \patchcmd\page@sofar
      {\setbox\z@\hbox{p}\global\dimen\tw@\dp\z@}%
      {%
        \setbox\z@\hbox{p}\global\dimen\tw@\dp\z@
        \@mult@ptagging@hook
      }%
      {\typeout{Patching \string\page@sofar\space for tagging}}{\PATCHerror}%
}
\ExplSyntaxOn
\def\@kernel@before@head{\pdfannot_link_off:}
\def\@kernel@before@foot{\pdfannot_link_off:}
\def\@kernel@after@head {\pdfannot_link_on:}
\def\@kernel@after@foot {\pdfannot_link_on:}
\ExplSyntaxOff
%% 
%%
%% End of file `output-patches-tmp-ltx.sty'.