summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/tagpdf/tagpdfdocu-patches.sty
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/tagpdf/tagpdfdocu-patches.sty')
-rw-r--r--macros/latex/contrib/tagpdf/tagpdfdocu-patches.sty156
1 files changed, 4 insertions, 152 deletions
diff --git a/macros/latex/contrib/tagpdf/tagpdfdocu-patches.sty b/macros/latex/contrib/tagpdf/tagpdfdocu-patches.sty
index 527d7bec01..4f14e73b1a 100644
--- a/macros/latex/contrib/tagpdf/tagpdfdocu-patches.sty
+++ b/macros/latex/contrib/tagpdf/tagpdfdocu-patches.sty
@@ -1,25 +1,17 @@
%\RequirePackage[enable-debug]{expl3}[2018/06/14]
-\ProvidesExplPackage {tagpdfdocu-patches} {2023-05-16} {0.98g}
+\ProvidesExplPackage {tagpdfdocu-patches} {2023-06-06} {0.98h}
{patches/commands for the tagpdf documentation}
\RequirePackage{etoolbox,xpatch}
%Logos
-
+% only spacing changes:
\ExplSyntaxOn
\DeclareRobustCommand\TeX{
\leavevmode
- \tag_mc_end_push:
- \tag_struct_begin:n{tag=Span,actualtext=TeX}
- \tagmcbegin{}
T\kern-.1667em\lower.5ex\hbox{E}\kern-.05emX\@ %changed from -.125em
- \tagmcend
- \tag_struct_end:
- \tag_mc_begin_pop:n{}}
+ }
\DeclareRobustCommand{\LaTeX}{
\leavevmode
- \tag_mc_end_push:
- \tag_struct_begin:n{tag=Span,actualtext=LaTeX}
- \tagmcbegin{}
L\kern-.25em % %changed from -0.36em
\sbox\z@ T%
\vbox to\ht\z@{\hbox{\check@mathfonts
@@ -29,24 +21,7 @@
\vss}%
\kern-.1em % %changed from 0.15em
T\kern-.1667em\lower.5ex\hbox{E}\kern-.05emX\@ %changed from -0.125
- \tagmcend
- \tag_struct_end:
- \tag_mc_begin_pop:n{}
- }
-% textbf
-
-\AddToHook{cmd/textbf/before}
- {\leavevmode\tag_mc_end_push:\tag_struct_begin:n{tag=Strong}\tagmcbegin{}}
-
-\AddToHook{cmd/textbf/after}
- {\tag_mc_end:\tag_struct_end:\tag_mc_begin_pop:n{}}
-
-% emph
-\AddToHook{cmd/emph/before}
- {\leavevmode\tag_mc_end_push:\tag_struct_begin:n{tag=Em}\tagmcbegin{}}
-
-\AddToHook{cmd/emph/after}
- {\tag_mc_end:\tag_struct_end:\tag_mc_begin_pop:n{}}
+ }
% minisec, correct tagging is still unclear.
\newcommand\minisec[1]{%
@@ -173,128 +148,5 @@
%====== floats ========
-\tagpdfsetup{add-new-tag=float/Div}
-\makeatletter
-\def\@xfloat #1[#2]{%
- \@nodocument
- \def \@captype {#1}%
- \def \@fps {#2}%
- \@onelevel@sanitize \@fps
- \def \reserved@b {!}%
- \ifx \reserved@b \@fps
- \@fpsadddefault
- \else
- \ifx \@fps \@empty
- \@fpsadddefault
- \fi
- \fi
- \ifhmode
- \@bsphack
- \tagmcend%end P
- \@floatpenalty -\@Mii
- \else
- \@floatpenalty-\@Miii
- \fi
- \ifinner
- \@parmoderr\@floatpenalty\z@
- \else
- \@next\@currbox\@freelist
- {%
- \@tempcnta \sixt@@n
- \expandafter \@tfor \expandafter \reserved@a
- \expandafter :\expandafter =\@fps
- \do
- {%
- \if \reserved@a h%
- \ifodd \@tempcnta
- \else
- \advance \@tempcnta \@ne
- \fi
- \else\if \reserved@a t%
- \@setfpsbit \tw@
- \else\if \reserved@a b%
- \@setfpsbit 4%
- \else\if \reserved@a p%
- \@setfpsbit 8%
- \else\if \reserved@a !%
- \ifnum \@tempcnta>15
- \advance\@tempcnta -\sixt@@n\relax
- \fi
- \else
- \@latex@error{Unknown float option `\reserved@a'}%
- {Option `\reserved@a' ignored and `p' used.}%
- \@setfpsbit 8%
- \fi\fi\fi\fi\fi
- }%
- \@tempcntb \csname ftype@\@captype \endcsname
- \multiply \@tempcntb \@xxxii
- \advance \@tempcnta \@tempcntb
- \global \count\@currbox \@tempcnta
- }%
- \@fltovf
- \fi
- \tagstructbegin{tag=float}%float
- \edef\@current@float@struct{\csname tag_get:n\endcsname{struct_num}}%
- \typeout{Float structure: \@current@float@struct}
- \global \setbox\@currbox
- \color@vbox
- \normalcolor
- \vbox \bgroup
- \hsize\columnwidth
- \@parboxrestore
- \@floatboxreset
-}%
-
-\def\end@float{%
- \@endfloatbox
- \tagstructend %end div
- \ifnum\@floatpenalty <\z@
- \@largefloatcheck
- \@cons\@currlist\@currbox
- \ifnum\@floatpenalty <-\@Mii
- \penalty -\@Miv
- \@tempdima\prevdepth
- \vbox{}%
- \prevdepth\@tempdima
- \penalty\@floatpenalty
- \else
- \vadjust{\penalty -\@Miv \vbox{}\penalty\@floatpenalty}\@Esphack
- \tagmcbegin{tag=P}%restart P Safe here??
- \fi
- \fi
-}
-
-\ExplSyntaxOn
-\long\def\@makecaption#1#2{%
- \vskip\abovecaptionskip
- \tagtool{para=false}
- \sbox\@tempboxa{#1:~#2}%
- \tag_struct_begin:n{tag=Caption}
- \ifdim \wd\@tempboxa >\hsize
- \tag_struct_begin:n{tag=Lbl}
- \tag_mc_begin:n{}
- #1:~
- \tag_mc_end:
- \tag_struct_end:
- \tag_mc_begin:n{}
- #2\par
- \tag_mc_end:
- \else
- \global \@minipagefalse
- \hb@xt@\hsize{\hfil
- \tag_struct_begin:n{tag=Lbl}
- \tag_mc_begin:n{}
- #1:~
- \tag_mc_end:
- \tag_struct_end:
- \tag_mc_begin:n{}
- #2\par
- \tag_mc_end:\hfil}%
- \fi
- \tagstructend %caption
- \vskip\belowcaptionskip}
-\ExplSyntaxOff
-
-
\endinput