summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Master/texmf-dist/doc/latex/tagpdf/README.md2
-rw-r--r--Master/texmf-dist/doc/latex/tagpdf/acrobat.pngbin0 -> 23311 bytes
-rw-r--r--Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.pdfbin1523569 -> 1532339 bytes
-rw-r--r--Master/texmf-dist/doc/latex/tagpdf/tagpdf.pdfbin738728 -> 757067 bytes
-rw-r--r--Master/texmf-dist/doc/latex/tagpdf/tagpdf.tex54
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-backend.dtx6
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-checks.dtx7
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-data.dtx227
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-generic.dtx6
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-luacode.dtx4
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-shared.dtx4
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx83
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-space.dtx4
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-struct.dtx20
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-tree.dtx15
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf-user.dtx4
-rw-r--r--Master/texmf-dist/source/latex/tagpdf/tagpdf.dtx6
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-base.sty2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-generic.sty2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug.sty12
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-luatex.def2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-generic.sty2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-lua.sty2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex-book.def2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex-inline.def2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex.def2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-mathml.def2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-pdf.def113
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-pdf2.def100
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-parent-child-2.csv (renamed from Master/texmf-dist/doc/latex/tagpdf/tagpdf-parent-child-2.csv)2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf-parent-child.csv (renamed from Master/texmf-dist/doc/latex/tagpdf/tagpdf-parent-child.csv)2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf.lua2
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty79
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdfdocu-patches.sty27
34 files changed, 479 insertions, 318 deletions
diff --git a/Master/texmf-dist/doc/latex/tagpdf/README.md b/Master/texmf-dist/doc/latex/tagpdf/README.md
index dc8ac843f8a..8f562a87168 100644
--- a/Master/texmf-dist/doc/latex/tagpdf/README.md
+++ b/Master/texmf-dist/doc/latex/tagpdf/README.md
@@ -1,5 +1,5 @@
#tagpdf — A package to create tagged pdf
-Packageversion: 0.98
+Packageversion: 0.98a
Packagedate: 2022/12/22
Author: Ulrike Fischer
diff --git a/Master/texmf-dist/doc/latex/tagpdf/acrobat.png b/Master/texmf-dist/doc/latex/tagpdf/acrobat.png
new file mode 100644
index 00000000000..6ffe1ba29da
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/tagpdf/acrobat.png
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.pdf b/Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.pdf
index 6dfd5b74a43..b0bb3a8290c 100644
--- a/Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.pdf
+++ b/Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/tagpdf/tagpdf.pdf b/Master/texmf-dist/doc/latex/tagpdf/tagpdf.pdf
index a04314fa715..08ec9e590c7 100644
--- a/Master/texmf-dist/doc/latex/tagpdf/tagpdf.pdf
+++ b/Master/texmf-dist/doc/latex/tagpdf/tagpdf.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/tagpdf/tagpdf.tex b/Master/texmf-dist/doc/latex/tagpdf/tagpdf.tex
index c1fe9d2d350..fc096c338d8 100644
--- a/Master/texmf-dist/doc/latex/tagpdf/tagpdf.tex
+++ b/Master/texmf-dist/doc/latex/tagpdf/tagpdf.tex
@@ -4,7 +4,7 @@
\DocumentMetadata{pdfversion=2.0,lang=en-UK,testphase=phase-II,testphase=toc-tagging,testphase=sec-tagging,pdfstandard=a-2b}
\makeatletter
-\def\UlrikeFischer@package@version{0.98}
+\def\UlrikeFischer@package@version{0.98a}
\def\UlrikeFischer@package@date{2022-12-22}
\makeatother
@@ -203,7 +203,9 @@ support \PDF{} 2.0. One example is the support for associated files, another the
The package doesn't try to suppress all 2.0 features if an older \PDF{} version is produced. It normally doesn't harm if a \PDF{} contains keys unknown in its version and it makes the code faster and easier to maintain if there aren't too many tests and code pathes; so for example associated files will always be added. But tests could be added in case this leads to incompabilities.
-It should be noted that some tools don't like \PDF{}~2.0. PAC3 for example simply crashes, and pdftk will create a \PDF{}~1.0 from it. This makes testing \PDF{}~2.0 files a bit of a challenge.
+It should be noted that some tools don't like \PDF{}~2.0. PAC~3 for example
+simply crashes, and pdftk will create a \PDF{}~1.0 from it. This makes
+testing \PDF{}~2.0 files a bit of a challenge.
\subsection{Validation}
@@ -223,10 +225,13 @@ One must check how good the accessibility is \emph{practically}.
\end{itemize}
-Syntax validation and formal standard validation can be done with preflight of the (non-free) adobe acrobat.
-It can also be done also with the free \PDF{} Accessibility Checker (PAC~3) \parencite{pac3}.
-There is also the validator veraPDF \parencite{verapdf}.
-A rather new and quite useful tool is \enquote{Next Generation PDF} \parencite{ngpdf}, a browser application which converts a tagged PDF to html, allows to inspect its structure and also to edit the structure.
+Syntax validation and formal standard validation can be done with preflight
+of the (non-free) adobe acrobat. It can also be done also with the free
+\PDF{} Accessibility Checker (PAC~3) \parencite{pac3}. There is also the
+validator veraPDF \parencite{verapdf}. A rather new and quite useful tool is
+\enquote{Next Generation PDF} \parencite{ngpdf}, a browser application which
+converts a tagged PDF to html, allows to inspect its structure and also to
+edit the structure.
Practical validation is naturally the more complicated part. It needs screen reader, users which actually knows how to handle them, can test documents and can report where a \PDF{} has real accessibility problems.
@@ -459,9 +464,23 @@ can improve the html export.
\subsection{Proof of concept: the tagging of the documentation itself}
-Starting with version 0.6 the documentation itself has been tagged. The tagging wasn't (and isn't) in no way perfect. The validator from Adobe didn't complain, but PAX3 wanted alternative text for all links (no idea why) and so I put everywhere simple text like \enquote{link} and \enquote{ref}. The links to footnotes gave warnings, so I disabled them. I used types from the \PDF{} version 1.7, mostly as I have no idea what should be used for code in 2.0. Margin notes were simply wrong \ldots
+Starting with version 0.6 the documentation itself has been tagged. The
+tagging wasn't (and isn't) in no way perfect. The validator from Adobe didn't
+complain, but PAC~3 wanted alternative text for all links (no idea why) and
+so I put everywhere simple text like \enquote{link} and \enquote{ref}. The
+links to footnotes gave warnings, so I disabled them. I used types from the
+\PDF{} version 1.7, mostly as I had no idea what should be used for code in
+2.0. Margin notes were simply wrong \ldots
+
+The tagging has been improved and automated over time in sync with
+improvements and new features in the LaTeX kernel and the \PDF\ management
+code and is now much better. Sadly the output of the validators don't quite
+reflect the improvements. The documentation uses now \PDF~2.0 and PAC~3
+can't handle this, it claims that the file is damaged. The Adobe validator
+has a bug and doesn't like the (valid) use of the \texttt{Lbl} tag for the
+section numbers (see figure~\ref{fig:adobe}).
+
-The tagging has been improved and automated over time in sync with improvements and new features in the LaTeX kernel and the \PDF\ management code.
But even if the documentation passed the tests of the validators: as mentioned above passing a formal test doesn't mean that the content is really good and usable. I have a lot doubts that the code parts are really readable. The bibliography and the references must be improved. The user commands used for the tagging and also some of the patches used are still rather crude. So there is lot space for improvement.
@@ -471,12 +490,29 @@ Be aware that to create the tagged version a current lualatex-dev and a current
\tagpdfparaOff
-\tagstructbegin{tag=Figure,alt=PAC3 report,attribute=bbox}\tagmcbegin{tag=Figure}
+\tagstructbegin{tag=Figure,alt=PAC 3
+report,attribute=bbox}\tagmcbegin{tag=Figure}
\includegraphics{pac3}
\tagmcend\tagstructend
\tagpdfparaOn
+\begin{figure}
+\tagpdfparaOff
+
+\tagstructbegin{tag=Figure,alt={Adobe report},attribute=bbox}%
+\tagmcbegin{}%
+\includegraphics{acrobat}
+\tagmcend
+
+\tagstructbegin{tag=Caption}\tagmcbegin{}\caption{Adobe Acrobat complaining
+about the \texttt{Lbl} use}\label{fig:adobe} \tagmcend\tagstructend
+\tagstructend
+
+\tagpdfparaOn
+\end{figure}
+
+
\section{Loading}
The package requires the new PDF management. With a current \LaTeX{} (2022-06-01 or newer)
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-backend.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-backend.dtx
index 47369b519b3..e8fac1f6ecf 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-backend.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-backend.dtx
@@ -47,13 +47,13 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{implementation}
% \begin{macrocode}
%<@@=tag>
%<*luatex>
-\ProvidesExplFile {tagpdf-luatex.def} {2022-12-22} {0.98}
+\ProvidesExplFile {tagpdf-luatex.def} {2022-12-22} {0.98a}
{tagpdf~driver~for~luatex}
% \end{macrocode}
% \section{Loading the lua}
@@ -158,7 +158,7 @@
local ProvidesLuaModule = {
name = "tagpdf",
- version = "0.98", --TAGVERSION
+ version = "0.98a", --TAGVERSION
date = "2022-12-22", --TAGDATE
description = "tagpdf lua code",
license = "The LATEX Project Public License 1.3c"
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-checks.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-checks.dtx
index 52113f348f2..6ec0e6aadc9 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-checks.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-checks.dtx
@@ -48,7 +48,7 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{documentation}
% \section{Commands}
@@ -295,7 +295,7 @@
% \begin{macrocode}
%<@@=tag>
%<*header>
-\ProvidesExplPackage {tagpdf-checks-code} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-checks-code} {2022-12-22} {0.98a}
{part of tagpdf - code related to checks, conditionals, debugging and messages}
%</header>
% \end{macrocode}
@@ -546,8 +546,7 @@
%
% \subsection{checks for active tagging}
% \begin{macro}[TF]{\@@_check_if_active_mc:,\@@_check_if_active_struct:}
-% Structures must have a tag, so we check if the S entry is in the property.
-% It is an error if this is missing. The argument is a number.
+% This checks if mc are active.
% \begin{macrocode}
\prg_new_conditional:Npnn \@@_check_if_active_mc: {T,F,TF}
{
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-data.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-data.dtx
index 560856bf28b..379c2114d76 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-data.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-data.dtx
@@ -47,7 +47,7 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{documentation}
% This files contains a various data files which are read in
@@ -60,7 +60,7 @@
% It lists the new tag, the rolemap and the namespace of the rolemap.
% \begin{macrocode}
%<*ns-latex>
-%% \ProvidesExplFile {tagpdf-ns-latex.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-latex.def} {2022-12-22} {0.98a}
%% {latex} {https://www.latex-project.org/ns/dflt/2022}{}
title, Title, pdf2,
part, Title, pdf2,
@@ -86,7 +86,7 @@ footnotelabel,Lbl, pdf2,
% It is bound to change
% \begin{macrocode}
%<*ns-latex-book>
-%% \ProvidesExplFile {tagpdf-ns-latex-book.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-latex-book.def} {2022-12-22} {0.98a}
%% {latex-book} {https://www.latex-project.org/ns/book/2022}{}
chapter, H1,pdf2,
section, H2,pdf2,
@@ -102,7 +102,7 @@ subparagraph, H6,pdf2,
% It is bound to change a lot!
% \begin{macrocode}
%<*ns-latex-inline>
-%% \ProvidesExplFile {tagpdf-ns-latex-inline.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-latex-inline.def} {2022-12-22} {0.98a}
%% {latex-inline} {https://www.latex-project.org/ns/inline/2022}{}
chapter, Span, pdf2,
section, Span, pdf2,
@@ -116,120 +116,131 @@ P, Span, pdf2,
% \section{The pdf namespace data}
% \begin{macrocode}
%<*ns-pdf>
-%% \ProvidesExplFile {tagpdf-ns-pdf.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-pdf.def} {2022-12-22} {0.98a}
%% {pdf} {http://iso.org/pdf/ssn}{}
-StructTreeRoot,,,D,
-Document,,,D,
-Part,,,G,
-Sect,,,G,
-Div,,,G,
-Caption,,,GB,
-NonStruct,,,G,
-H,,,B,
-H1,,,B,
-H2,,,B,
-H3,,,B,
-H4,,,B,
-H5,,,B,
-H6,,,B,
-P,,,B,
-L,,,BI,
-LI,,,L,
-Lbl,,,I,
-LBody,,,L,
-Table,,,B,
-TR,,,T,
-TH,,,T,
-TD,,,T,
-THead,,,T,
-TBody,,,T,
-TFoot,,,T,
-Span,,,I,
-Link,,,GBI,
-Annot,,,GBI,
-Figure,,,GBI,
-Formula,,,GBI,
-Form,,,GBI,
-Ruby,,,I,
-RB,,,I,
-RT,,,I,
-Warichu,,,I,
-WT,,,I,
-WP,,,I,
-Artifact,,,GBI,
-Art,,,,G, % only pdf, types unclear, needs correction later
-BlockQuote,,,G, %or GB?
-TOC,,,G,
-TOCI,,,G,
-Index,,,G,
-Private,,,G,
-Quote,,,I,
-Note,,,GBI, % I in reference, but
-Reference,,,B, %
-BibEntry,,,B, %
-Code,,,I, %
+StructTreeRoot,StructTreeRoot,pdf,D,
+Document,Document,pdf,D,
+Part,Part,pdf,G,
+Sect,Sect,pdf,G,
+Div,Div,pdf,G,
+Caption,Caption,pdf,GB,
+NonStruct,NonStruct,pdf,G,
+H,H,pdf,B,
+H1,H1,pdf,B,
+H2,H2,pdf,B,
+H3,H3,pdf,B,
+H4,H4,pdf,B,
+H5,H5,pdf,B,
+H6,H6,pdf,B,
+P,P,pdf,B,
+L,L,pdf,BI,
+LI,LI,pdf,L,
+Lbl,Lbl,pdf,I,
+LBody,LBody,pdf,L,
+Table,Table,pdf,B,
+TR,TR,pdf,T,
+TH,TH,pdf,T,
+TD,TD,pdf,T,
+THead,THead,pdf,T,
+TBody,TBody,pdf,T,
+TFoot,TFoot,pdf,T,
+Span,Span,pdf,I,
+Link,Link,pdf,GBI,
+Annot,Annot,pdf,GBI,
+Figure,Figure,pdf,GBI,
+Formula,Formula,pdf,GBI,
+Form,Form,pdf,GBI,
+Ruby,Ruby,pdf,I,
+RB,RB,pdf,I,
+RT,RT,pdf,I,
+Warichu,Warichu,pdf,I,
+WT,WT,pdf,I,
+WP,WP,pdf,I,
+Artifact,Artifact,pdf,GBI,
+Art,Art,pdf,,G, % only pdf, types unclear, needs correction later
+BlockQuote,BlockQuote,pdf,G, %or GB?
+TOC,TOC,pdf,G,
+TOCI,TOCI,pdf,G,
+Index,Index,pdf,G,
+Private,Private,pdf,G,
+Quote,Quote,pdf,I,
+Note,Note,pdf,GBI, % I in reference, but
+Reference,Reference,pdf,B, %
+BibEntry,BibEntry,pdf,B, %
+Code,Code,pdf,I, %
+DocumentFragment,Art,pdf,D, %from pdf2
+Aside,Note,pdf,G,
+H7,H6,pdf,B,
+H8,H6,pdf,B,
+H9,H6,pdf,B,
+H10,H6,pdf,B,
+Title,P,pdf,GB,
+FENote,Note,pdf,GBI,
+Sub,Span,pdf,I,
+Em,Span,pdf,I,
+Strong,Span,pdf,I,
%</ns-pdf>
% \end{macrocode}
% \section{The pdf 2.0 namespace data}
% \begin{macrocode}
%<*ns-pdf2>
-%% \ProvidesExplFile {tagpdf-ns-pdf2.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-pdf2.def} {2022-12-22} {0.98a}
%% {pdf2} {http://iso.org/pdf2/ssn}{}
-Document,,,D,
-Part,,,G,
-Sect,,,G,
-Div,,,G,
-Caption,,,GB,
-NonStruct,,,G,
-H,,,B,
-H1,,,B,
-H2,,,B,
-H3,,,B,
-H4,,,B,
-H5,,,B,
-H6,,,B,
-P,,,B,
-L,,,BI,
-LI,,,L,
-Lbl,,,I,
-LBody,,,L,
-Table,,,B,
-TR,,,T,
-TH,,,T,
-TD,,,T,
-THead,,,T,
-TBody,,,T,
-TFoot,,,T,
-Span,,,I,
-Link,,,GBI,
-Annot,,,GBI,
-Figure,,,GBI,
-Formula,,,GBI,
-Form,,,GBI,
-Ruby,,,I,
-RB,,,I,
-RT,,,I,
-Warichu,,,I,
-WT,,,I,
-WP,,,I,
-Artifact,,,GBI,
-DocumentFragment,Art, pdf,D, %rest only pdf2
-Aside, Note, pdf,G,
-H7, H6, pdf,B,
-H8, H6, pdf,B,
-H9, H6, pdf,B,
-H10, H6, pdf,B,
-Title, P, pdf,GB,
-FENote, Note, pdf,GBI,
-Sub, Span, pdf,I,
-Em, Span, pdf,I,
-Strong, Span, pdf,I,
+Document,Document,pdf2,D,
+Part,Part,pdf2,G,
+Sect,Sect,pdf2,G,
+Div,Div,pdf2,G,
+Caption,Caption,pdf2,GB,
+NonStruct,NonStruct,pdf2,G,
+H,H,pdf2,B,
+H1,H1,pdf2,B,
+H2,H2,pdf2,B,
+H3,H3,pdf2,B,
+H4,H4,pdf2,B,
+H5,H5,pdf2,B,
+H6,H6,pdf2,B,
+P,P,pdf2,B,
+L,L,pdf2,BI,
+LI,LI,pdf2,L,
+Lbl,Lbl,pdf2,I,
+LBody,LBody,pdf2,L,
+Table,Table,pdf2,B,
+TR,TR,pdf2,T,
+TH,TH,pdf2,T,
+TD,TD,pdf2,T,
+THead,THead,pdf2,T,
+TBody,TBody,pdf2,T,
+TFoot,TFoot,pdf2,T,
+Span,Span,pdf2,I,
+Link,Link,pdf2,GBI,
+Annot,Annot,pdf2,GBI,
+Figure,Figure,pdf2,GBI,
+Formula,Formula,pdf2,GBI,
+Form,Form,pdf2,GBI,
+Ruby,Ruby,pdf2,I,
+RB,RB,pdf2,I,
+RT,RT,pdf2,I,
+Warichu,Warichu,pdf2,I,
+WT,WT,pdf2,I,
+WP,WP,pdf2,I,
+Artifact,Artifact,pdf2,GBI,
+DocumentFragment,DocumentFragment,pdf2,D, %rest only pdf2
+Aside,Aside,pdf2,G,
+H7,H7,pdf2,B,
+H8,H8,pdf2,B,
+H9,H9,pdf2,B,
+H10,H10,pdf2,B,
+Title,Title,pdf2,GB,
+FENote,FENote,pdf2,GBI,
+Sub,Sub,pdf2,I,
+Em,Em,pdf2,I,
+Strong,Strong,pdf2,I,
%</ns-pdf2>
% \end{macrocode}
% \section{The mathml namespace data}
% \begin{macrocode}
%<*ns-mathml>
-%% \ProvidesExplFile {tagpdf-ns-mathml.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-mathml.def} {2022-12-22} {0.98a}
% {mathml}{http://www.w3.org/1998/Math/MathML}{}
abs,,,
and,,,
@@ -464,7 +475,7 @@ xor,,,
% This will perhaps change in future.
% \begin{macrocode}
%<*parent-child>
-%% \ProvidesExplFile {tagpdf-parent-child.csv} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-parent-child.csv} {2022-12-22} {0.98a}
,,,StructTreeRoot,Document,Art,Part,Div,Sect,BlockQuote,NonStruct,TOC,TOCI,Index,Private,Quote,Note,Reference,BibEntry,P,Hn,H,Lbl,Code,Span,Link,Annot,Form,Ruby,RB,RT,RP,Warichu,WT,WP,L,LI,LBody,Table,TR,TH,TD,THead,TBody,TFoot,Caption,Figure,Formula,MC
Document,both,document level,1,0..n,∅,‡,‡,∅,0..n,‡,∅,∅,∅,0..n,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅
Art,1.7,grouping,∅,0..n,∅,‡,‡,0..n,0..n,‡,∅,∅,∅,0..n,∅,0..n,∅,∅,∅,0..1,0..1,∅,∅,∅,0..n,0..n,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,0..n,∅,∅,0..n,0..n,∅,∅,∅,0..n,0..n,∅,∅
@@ -519,7 +530,7 @@ MC,both,---,∅,∅,∅,∅,∅,∅,0..n,‡,∅,∅,∅,0..n,0..n,0..n,0..n,0..
% This will perhaps change in future.
% \begin{macrocode}
%<*parent-child-2>
-%% \ProvidesExplFile {tagpdf-parent-child-2.csv} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-parent-child-2.csv} {2022-12-22} {0.98a}
,,,StructTreeRoot,Document,DocumentFragment,Art,Part,Div,Sect,Aside,BlockQuote,NonStruct,TOC,TOCI,Index,Private,Title,Sub,Quote,Note,Reference,BibEntry,P,Hn,H,Lbl,Code,Em,Strong,Span,Link,Annot,Form,Ruby,RB,RT,RP,Warichu,WT,WP,FENote,L,LI,LBody,Table,TR,TH,TD,THead,TBody,TFoot,Caption,Figure,Formula,math,mathml,Artifact,MC
Document,both,document level,1,0..n,0..n,∅,‡,‡,∅,0..n,0..n,‡,∅,∅,∅,0..n,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,0..n,∅
DocumentFragment,2.0,document level,∅,0..n,0..n,0..n,‡,‡,0..n,0..n,0..n,‡,∅,∅,∅,0..n,∅,∅,∅,∅*,∅,∅,∅,∅,∅,∅,∅*,∅,∅,∅,∅*,∅*,∅,∅,∅,∅,∅,∅,∅,∅,∅*,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅*,∅,∅,∅,∅,0..n,∅
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-generic.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-generic.dtx
index ea460e01042..573604fa874 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-generic.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-generic.dtx
@@ -46,7 +46,7 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{documentation}
% \end{documentation}
@@ -55,11 +55,11 @@
% \begin{macrocode}
%<@@=tag>
%<*generic>
-\ProvidesExplPackage {tagpdf-mc-code-generic} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-mc-code-generic} {2022-12-22} {0.98a}
{part of tagpdf - code related to marking chunks - generic mode}
%</generic>
%<*debug>
-\ProvidesExplPackage {tagpdf-debug-generic} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-debug-generic} {2022-12-22} {0.98a}
{part of tagpdf - debugging code related to marking chunks - generic mode}
%</debug>
% \end{macrocode}
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-luacode.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-luacode.dtx
index ca8645e76ca..6195218abf3 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-luacode.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-luacode.dtx
@@ -46,7 +46,7 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{implementation}
% The code is splitted into three parts: code shared by all engines,
@@ -86,7 +86,7 @@
% \begin{macrocode}
%<@@=tag>
%<*luamode>
-\ProvidesExplPackage {tagpdf-mc-code-lua} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-mc-code-lua} {2022-12-22} {0.98a}
{tagpdf - mc code only for the luamode }
%</luamode>
% \end{macrocode}
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-shared.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-shared.dtx
index 2e49c84725a..66ad8a922ce 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-shared.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-shared.dtx
@@ -46,7 +46,7 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{documentation}
% \section{Public Commands}
@@ -174,7 +174,7 @@
% \begin{macrocode}
%<@@=tag>
%<*header>
-\ProvidesExplPackage {tagpdf-mc-code-shared} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-mc-code-shared} {2022-12-22} {0.98a}
{part of tagpdf - code related to marking chunks -
code shared by generic and luamode }
%</header>
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx
index b17515882eb..d24fae960e3 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx
@@ -46,7 +46,7 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{documentation}
% \begin{function}
@@ -90,7 +90,7 @@
% \begin{macrocode}
%<@@=tag>
%<*header>
-\ProvidesExplPackage {tagpdf-roles-code} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-roles-code} {2022-12-22} {0.98a}
{part of tagpdf - code related to roles and structure names}
%</header>
% \end{macrocode}
@@ -464,6 +464,26 @@
\cs_generate_variant:Nn \@@_role_add_tag:nn {VV,ne}
% \end{macrocode}
% \end{macro}
+%
+% For the parent-child test we must be able to get the role.
+% We use the same number of arguments as for the 2.0 command.
+% If there is no role, we assume a standard tag.
+% \begin{macro}{\@@_role_get:nnN}
+% \begin{macrocode}
+\pdf_version_compare:NnT < {2.0}
+ {
+ \cs_new:Npn \@@_role_get:nnN #1#2#3
+ {
+ \prop_get:NnNF \g_@@_role_rolemap_prop {#1}#3
+ {
+ \tl_set:Nn #3 {#1}
+ }
+ }
+ \cs_generate_variant:Nn \@@_role_get:nnN {VVN}
+ }
+
+% \end{macrocode}
+% \end{macro}
% \subsubsection{The pdf 2.0 version}
% \begin{macro}{\@@_role_add_tag:nnnn}
% The pdf 2.0 version takes four arguments:
@@ -481,15 +501,21 @@
{
\tl_set:Nn\l_@@_tmpa_tl{--UNKNOWN--}
}
- \@@_role_alloctag:nnV {#1}{#2}\l_@@_tmpa_tl
- \pdfdict_gput:nnx {g_@@_role/RoleMapNS_#2_dict}{#1}
- {
- [
- \pdf_name_from_unicode_e:n{#3}
- \c_space_tl
- \pdf_object_ref:n {tag/NS/#4}
- ]
- }
+ \@@_role_alloctag:nnV {#1}{#2}\l_@@_tmpa_tl
+% \end{macrocode}
+% Do not remap standard tags. TODO add warning?
+% \begin{macrocode}
+ \tl_if_in:nnF {-pdf-pdf2-mathml-}{-#2-}
+ {
+ \pdfdict_gput:nnx {g_@@_role/RoleMapNS_#2_dict}{#1}
+ {
+ [
+ \pdf_name_from_unicode_e:n{#3}
+ \c_space_tl
+ \pdf_object_ref:n {tag/NS/#4}
+ ]
+ }
+ }
% \end{macrocode}
% We resolve rolemapping recursively so that all targets are stored as standard
% tags for the tests.
@@ -511,6 +537,28 @@
% \end{macrocode}
% \end{macro}
%
+% For the parent-child test we must be able to get the role.
+% We use the same number of arguments as for the <2.0 command (and assume
+% that we don't need a name space)%
+% \begin{macro}{\@@_role_get:nnN}
+% \begin{macrocode}
+\pdf_version_compare:NnF < {2.0}
+ {
+ \cs_new:Npn \@@_role_get:nnN #1#2#3
+ {
+ \prop_get:cnNTF {g_@@_role_NS_#2_prop} {#1}\l_@@_get_tmpc_tl
+ {
+ \tl_set:Nx #3 {\exp_last_unbraced:NV\use_i:nn \l_@@_get_tmpc_tl}
+ }
+ {
+ \tl_set:Nn #3 {#1}
+ }
+ }
+ \cs_generate_variant:Nn \@@_role_get:nnN {VVN}
+ }
+% \end{macrocode}
+% \end{macro}
+%
% \subsection{Helper command to read the data from files}
% In this section we setup the helper command to read namespace files.
@@ -547,7 +595,7 @@
\tl_set:Nn \l_@@_tmpa_tl {#5}
}
\@@_role_alloctag:nnV {#2}{#1}\l_@@_tmpa_tl
- \tl_if_empty:nF {#3}
+ \tl_if_eq:nnF {#2}{#3}
{
\@@_role_add_tag:nn {#2}{#3}
}
@@ -581,9 +629,9 @@
\bool_lazy_and:nnT
{ ! \tl_if_empty_p:n {#3} }{! \str_if_eq_p:nn {#1}{pdf2}}
{
- \@@_role_add_tag:nnnn {#2}{#1}{#3}{#4}
- \prop_gput:cnn {g_@@_role_NS_#1_prop} {#2}{{#3}{#4}}
+ \@@_role_add_tag:nnnn {#2}{#1}{#3}{#4}
}
+ \prop_gput:cnn {g_@@_role_NS_#1_prop} {#2}{{#3}{#4}}
}
}
}
@@ -855,11 +903,14 @@
\seq_pop_left:NN \l_@@_role_tmpa_seq\l_@@_get_tmpc_tl
\seq_map_inline:Nn\l_@@_role_tmpa_seq
{
- \tl_if_in:nnF {-Part-Div-NonStruct-}{-##1-}
+ \tl_set:Nx\l_@@_tmpa_tl { \use_ii:nn ##1 }
+ \exp_args:Nne
+ \tl_if_in:nnF {-Part-Div-NonStruct-}{-\l_@@_tmpa_tl-}
{
\tl_set:Nn\l_@@_role_real_parent_tl {##1}
\int_zero:N\l_@@_tmpa_int
- \@@_role_get_parent_child_rule:nnN {##1}{#2}#3
+ \exp_args:NV
+ \@@_role_get_parent_child_rule:nnN \l_@@_tmpa_tl{#2}#3
\int_set:Nn\l_@@_tmpa_int{1}
\seq_map_break:
}
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-space.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-space.dtx
index ad5e17ff5b1..26602a96b01 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-space.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-space.dtx
@@ -46,7 +46,7 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{documentation}
% \begin{function}{interwordspace (setup-key)}
@@ -64,7 +64,7 @@
% \begin{macrocode}
%<@@=tag>
%<*header>
-\ProvidesExplPackage {tagpdf-space-code} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-space-code} {2022-12-22} {0.98a}
{part of tagpdf - code related to real space chars}
%</header>
% \end{macrocode}
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-struct.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-struct.dtx
index 6f6d60ba4b9..1299cc10e99 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-struct.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-struct.dtx
@@ -46,7 +46,7 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{documentation}
% \section{Public Commands}
@@ -242,7 +242,7 @@
% \begin{macrocode}
%<@@=tag>
%<*header>
-\ProvidesExplPackage {tagpdf-struct-code} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-struct-code} {2022-12-22} {0.98a}
{part of tagpdf - code related to storing structure}
%</header>
% \end{macrocode}
@@ -294,7 +294,7 @@
% numbered stack, lets build a tag stack too.
% \begin{macrocode}
\seq_new:N \g_@@_struct_tag_stack_seq
-\seq_gpush:Nn \g_@@_struct_tag_stack_seq {Root}
+\seq_gpush:Nn \g_@@_struct_tag_stack_seq {{Root}{StructTreeRoot}}
% \end{macrocode}
% \end{variable}
%
@@ -546,7 +546,7 @@
% \end{macrocode}
% \end{macro}
%
-% \begin{macro}{\cc}
+% \begin{macro}{\@@_struct_get_tag_info:nNN}
% We also need a way to get the tag info back from parent structures.
% \begin{macrocode}
\cs_new_protected:Npn \@@_struct_get_tag_info:nNN #1 #2 #3
@@ -1226,7 +1226,12 @@
}
}
\seq_gpush:NV \g_@@_struct_stack_seq \c@g_@@_struct_abs_int
- \seq_gpush:NV \g_@@_struct_tag_stack_seq \g_@@_struct_tag_tl
+ \@@_role_get:VVN
+ \g_@@_struct_tag_tl
+ \g_@@_struct_tag_NS_tl
+ \l_@@_get_tmpc_tl
+ \seq_gpush:Nx \g_@@_struct_tag_stack_seq
+ {{\g_@@_struct_tag_tl}{\l_@@_get_tmpc_tl}}
\tl_gset:NV \g_@@_struct_stack_current_tl \c@g_@@_struct_abs_int
%\seq_show:N \g_@@_struct_stack_seq
\bool_if:NF
@@ -1314,7 +1319,8 @@
}
\seq_get:NNT \g_@@_struct_tag_stack_seq \l_@@_tmpa_tl
{
- \tl_gset:NV \g_@@_struct_tag_tl \l_@@_tmpa_tl
+ \tl_gset:Nx \g_@@_struct_tag_tl
+ { \exp_last_unbraced:NV\use_i:nn \l_@@_tmpa_tl }
}
%<debug>\@@_debug_struct_end_insert:
}
@@ -1474,7 +1480,7 @@
% \section{Attributes and attribute classes}
% \begin{macrocode}
%<*header>
-\ProvidesExplPackage {tagpdf-attr-code} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-attr-code} {2022-12-22} {0.98a}
{part of tagpdf - code related to attributes and attribute classes}
%</header>
% \end{macrocode}
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-tree.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-tree.dtx
index ecbd96f04ee..f8c7aa27d75 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-tree.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-tree.dtx
@@ -47,13 +47,13 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{implementation}
% \begin{macrocode}
%<@@=tag>
%<*header>
-\ProvidesExplPackage {tagpdf-tree-code} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-tree-code} {2022-12-22} {0.98a}
{part of tagpdf - code related to writing trees and dictionaries to the pdf}
%</header>
% \end{macrocode}
@@ -348,9 +348,12 @@
{
\prop_map_inline:Nn\g_@@_role_rolemap_prop
{
- \pdfdict_gput:nnx {g_@@_role/RoleMap_dict}
- {##1}
- {\pdf_name_from_unicode_e:n{##2}}
+ \tl_if_eq:nnF {##1}{##2}
+ {
+ \pdfdict_gput:nnx {g_@@_role/RoleMap_dict}
+ {##1}
+ {\pdf_name_from_unicode_e:n{##2}}
+ }
}
\pdf_object_write:nnx { @@/tree/rolemap }{dict}
{
@@ -418,7 +421,7 @@
\cs_new_protected:Npn \@@_tree_write_namespaces:
{
\pdf_version_compare:NnF < {2.0}
- {
+ {
\prop_map_inline:Nn \g_@@_role_NS_prop
{
\pdfdict_if_empty:nF {g_@@_role/RoleMapNS_##1_dict}
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-user.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-user.dtx
index a70c14bb217..a2a0475ccf1 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-user.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-user.dtx
@@ -46,7 +46,7 @@
% }^^A
% }
%
-% \date{Version 0.98, released 2022-12-22}
+% \date{Version 0.98a, released 2022-12-22}
% \maketitle
% \begin{documentation}
% \section{Setup commands}
@@ -246,7 +246,7 @@
% \begin{macrocode}
%<@@=tag>
%<*header>
-\ProvidesExplPackage {tagpdf-user} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-user} {2022-12-22} {0.98a}
{tagpdf - user commands}
%</header>
% \end{macrocode}
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf.dtx
index d9550ab7a7f..59795d78a39 100644
--- a/Master/texmf-dist/source/latex/tagpdf/tagpdf.dtx
+++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf.dtx
@@ -92,7 +92,7 @@
% \begin{macrocode}
%<@@=tag>
%<*package>
-\ProvidesExplPackage {tagpdf} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf} {2022-12-22} {0.98a}
{ A package to experiment with pdf tagging }
\bool_if:nF
@@ -118,7 +118,7 @@
% \end{macrocode}
%<*debug>
% \begin{macrocode}
-\ProvidesExplPackage {tagpdf-debug} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-debug} {2022-12-22} {0.98a}
{ debug code for tagpdf }
\@ifpackageloaded{tagpdf}{}{\PackageWarning{tagpdf-debug}{tagpdf~not~loaded,~quitting}\endinput}
% \end{macrocode}
@@ -159,7 +159,7 @@
% \end{macrocode}
% \begin{macrocode}
%<*base>
-\ProvidesExplPackage {tagpdf-base} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-base} {2022-12-22} {0.98a}
{part of tagpdf - provide base, no-op versions of the user commands }
%</base>
% \end{macrocode}
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-base.sty b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-base.sty
index d9ded28bea6..3da06a2f1b4 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-base.sty
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-base.sty
@@ -24,7 +24,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf.dtx
-\ProvidesExplPackage {tagpdf-base} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-base} {2022-12-22} {0.98a}
{part of tagpdf - provide base, no-op versions of the user commands }
\AddToHook{begindocument}
{
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-generic.sty b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-generic.sty
index 9551032812d..ea2f311304c 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-generic.sty
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-generic.sty
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-mc-generic.dtx
-\ProvidesExplPackage {tagpdf-debug-generic} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-debug-generic} {2022-12-22} {0.98a}
{part of tagpdf - debugging code related to marking chunks - generic mode}
\cs_set_protected:Npn \tag_mc_begin:n #1 %#1 keyval
{
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug.sty b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug.sty
index 1e3290a404a..944dd28d7fc 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug.sty
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug.sty
@@ -26,7 +26,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf.dtx
-\ProvidesExplPackage {tagpdf-debug} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-debug} {2022-12-22} {0.98a}
{ debug code for tagpdf }
\@ifpackageloaded{tagpdf}{}{\PackageWarning{tagpdf-debug}{tagpdf~not~loaded,~quitting}\endinput}
\prop_gput:Nnn \g_msg_module_type_prop { tag / debug} {}
@@ -159,7 +159,12 @@
}
}
\seq_gpush:NV \g__tag_struct_stack_seq \c@g__tag_struct_abs_int
- \seq_gpush:NV \g__tag_struct_tag_stack_seq \g__tag_struct_tag_tl
+ \__tag_role_get:VVN
+ \g__tag_struct_tag_tl
+ \g__tag_struct_tag_NS_tl
+ \l__tag_get_tmpc_tl
+ \seq_gpush:Nx \g__tag_struct_tag_stack_seq
+ {{\g__tag_struct_tag_tl}{\l__tag_get_tmpc_tl}}
\tl_gset:NV \g__tag_struct_stack_current_tl \c@g__tag_struct_abs_int
%\seq_show:N \g__tag_struct_stack_seq
\bool_if:NF
@@ -237,7 +242,8 @@
}
\seq_get:NNT \g__tag_struct_tag_stack_seq \l__tag_tmpa_tl
{
- \tl_gset:NV \g__tag_struct_tag_tl \l__tag_tmpa_tl
+ \tl_gset:Nx \g__tag_struct_tag_tl
+ { \exp_last_unbraced:NV\use_i:nn \l__tag_tmpa_tl }
}
\__tag_debug_struct_end_insert:
}
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-luatex.def b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-luatex.def
index 629fcd69295..b3c2876b012 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-luatex.def
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-luatex.def
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-backend.dtx
-\ProvidesExplFile {tagpdf-luatex.def} {2022-12-22} {0.98}
+\ProvidesExplFile {tagpdf-luatex.def} {2022-12-22} {0.98a}
{tagpdf~driver~for~luatex}
{
\fontencoding{TU}\fontfamily{lmr}\fontseries{m}\fontshape{n}\fontsize{10pt}{10pt}\selectfont
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-generic.sty b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-generic.sty
index 8427bfee078..b345e736719 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-generic.sty
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-generic.sty
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-mc-generic.dtx
-\ProvidesExplPackage {tagpdf-mc-code-generic} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-mc-code-generic} {2022-12-22} {0.98a}
{part of tagpdf - code related to marking chunks - generic mode}
\__tag_prop_new:N \g__tag_MCID_byabspage_prop
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-lua.sty b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-lua.sty
index 06f079202f7..30ad779f1ae 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-lua.sty
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-lua.sty
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-mc-luacode.dtx
-\ProvidesExplPackage {tagpdf-mc-code-lua} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf-mc-code-lua} {2022-12-22} {0.98a}
{tagpdf - mc code only for the luamode }
\hook_gput_code:nnn{begindocument}{tagpdf/mc}
{
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex-book.def b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex-book.def
index 8718afcbea2..42d51a6d383 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex-book.def
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex-book.def
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-data.dtx
-%% \ProvidesExplFile {tagpdf-ns-latex-book.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-latex-book.def} {2022-12-22} {0.98a}
%% {latex-book} {https://www.latex-project.org/ns/book/2022}{}
chapter, H1,pdf2,
section, H2,pdf2,
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex-inline.def b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex-inline.def
index 784e54197bb..5dcec775dc7 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex-inline.def
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex-inline.def
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-data.dtx
-%% \ProvidesExplFile {tagpdf-ns-latex-inline.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-latex-inline.def} {2022-12-22} {0.98a}
%% {latex-inline} {https://www.latex-project.org/ns/inline/2022}{}
chapter, Span, pdf2,
section, Span, pdf2,
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex.def b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex.def
index 290d501df4d..4d5115640f9 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex.def
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-latex.def
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-data.dtx
-%% \ProvidesExplFile {tagpdf-ns-latex.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-latex.def} {2022-12-22} {0.98a}
%% {latex} {https://www.latex-project.org/ns/dflt/2022}{}
title, Title, pdf2,
part, Title, pdf2,
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-mathml.def b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-mathml.def
index 0d7c83dfdba..0d0096c63f4 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-mathml.def
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-mathml.def
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-data.dtx
-%% \ProvidesExplFile {tagpdf-ns-mathml.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-mathml.def} {2022-12-22} {0.98a}
abs,,,
and,,,
annotation,,,
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-pdf.def b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-pdf.def
index af9c46a9b54..693faa9ba45 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-pdf.def
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-pdf.def
@@ -19,58 +19,69 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-data.dtx
-%% \ProvidesExplFile {tagpdf-ns-pdf.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-pdf.def} {2022-12-22} {0.98a}
%% {pdf} {http://iso.org/pdf/ssn}{}
-StructTreeRoot,,,D,
-Document,,,D,
-Part,,,G,
-Sect,,,G,
-Div,,,G,
-Caption,,,GB,
-NonStruct,,,G,
-H,,,B,
-H1,,,B,
-H2,,,B,
-H3,,,B,
-H4,,,B,
-H5,,,B,
-H6,,,B,
-P,,,B,
-L,,,BI,
-LI,,,L,
-Lbl,,,I,
-LBody,,,L,
-Table,,,B,
-TR,,,T,
-TH,,,T,
-TD,,,T,
-THead,,,T,
-TBody,,,T,
-TFoot,,,T,
-Span,,,I,
-Link,,,GBI,
-Annot,,,GBI,
-Figure,,,GBI,
-Formula,,,GBI,
-Form,,,GBI,
-Ruby,,,I,
-RB,,,I,
-RT,,,I,
-Warichu,,,I,
-WT,,,I,
-WP,,,I,
-Artifact,,,GBI,
-Art,,,,G, % only pdf, types unclear, needs correction later
-BlockQuote,,,G, %or GB?
-TOC,,,G,
-TOCI,,,G,
-Index,,,G,
-Private,,,G,
-Quote,,,I,
-Note,,,GBI, % I in reference, but
-Reference,,,B, %
-BibEntry,,,B, %
-Code,,,I, %
+StructTreeRoot,StructTreeRoot,pdf,D,
+Document,Document,pdf,D,
+Part,Part,pdf,G,
+Sect,Sect,pdf,G,
+Div,Div,pdf,G,
+Caption,Caption,pdf,GB,
+NonStruct,NonStruct,pdf,G,
+H,H,pdf,B,
+H1,H1,pdf,B,
+H2,H2,pdf,B,
+H3,H3,pdf,B,
+H4,H4,pdf,B,
+H5,H5,pdf,B,
+H6,H6,pdf,B,
+P,P,pdf,B,
+L,L,pdf,BI,
+LI,LI,pdf,L,
+Lbl,Lbl,pdf,I,
+LBody,LBody,pdf,L,
+Table,Table,pdf,B,
+TR,TR,pdf,T,
+TH,TH,pdf,T,
+TD,TD,pdf,T,
+THead,THead,pdf,T,
+TBody,TBody,pdf,T,
+TFoot,TFoot,pdf,T,
+Span,Span,pdf,I,
+Link,Link,pdf,GBI,
+Annot,Annot,pdf,GBI,
+Figure,Figure,pdf,GBI,
+Formula,Formula,pdf,GBI,
+Form,Form,pdf,GBI,
+Ruby,Ruby,pdf,I,
+RB,RB,pdf,I,
+RT,RT,pdf,I,
+Warichu,Warichu,pdf,I,
+WT,WT,pdf,I,
+WP,WP,pdf,I,
+Artifact,Artifact,pdf,GBI,
+Art,Art,pdf,,G, % only pdf, types unclear, needs correction later
+BlockQuote,BlockQuote,pdf,G, %or GB?
+TOC,TOC,pdf,G,
+TOCI,TOCI,pdf,G,
+Index,Index,pdf,G,
+Private,Private,pdf,G,
+Quote,Quote,pdf,I,
+Note,Note,pdf,GBI, % I in reference, but
+Reference,Reference,pdf,B, %
+BibEntry,BibEntry,pdf,B, %
+Code,Code,pdf,I, %
+DocumentFragment,Art,pdf,D, %from pdf2
+Aside,Note,pdf,G,
+H7,H6,pdf,B,
+H8,H6,pdf,B,
+H9,H6,pdf,B,
+H10,H6,pdf,B,
+Title,P,pdf,GB,
+FENote,Note,pdf,GBI,
+Sub,Span,pdf,I,
+Em,Span,pdf,I,
+Strong,Span,pdf,I,
%%
%%
%% End of file `tagpdf-ns-pdf.def'.
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-pdf2.def b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-pdf2.def
index fe63f43089b..fbc68fa9b54 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-pdf2.def
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-ns-pdf2.def
@@ -19,57 +19,57 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-data.dtx
-%% \ProvidesExplFile {tagpdf-ns-pdf2.def} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-ns-pdf2.def} {2022-12-22} {0.98a}
%% {pdf2} {http://iso.org/pdf2/ssn}{}
-Document,,,D,
-Part,,,G,
-Sect,,,G,
-Div,,,G,
-Caption,,,GB,
-NonStruct,,,G,
-H,,,B,
-H1,,,B,
-H2,,,B,
-H3,,,B,
-H4,,,B,
-H5,,,B,
-H6,,,B,
-P,,,B,
-L,,,BI,
-LI,,,L,
-Lbl,,,I,
-LBody,,,L,
-Table,,,B,
-TR,,,T,
-TH,,,T,
-TD,,,T,
-THead,,,T,
-TBody,,,T,
-TFoot,,,T,
-Span,,,I,
-Link,,,GBI,
-Annot,,,GBI,
-Figure,,,GBI,
-Formula,,,GBI,
-Form,,,GBI,
-Ruby,,,I,
-RB,,,I,
-RT,,,I,
-Warichu,,,I,
-WT,,,I,
-WP,,,I,
-Artifact,,,GBI,
-DocumentFragment,Art, pdf,D, %rest only pdf2
-Aside, Note, pdf,G,
-H7, H6, pdf,B,
-H8, H6, pdf,B,
-H9, H6, pdf,B,
-H10, H6, pdf,B,
-Title, P, pdf,GB,
-FENote, Note, pdf,GBI,
-Sub, Span, pdf,I,
-Em, Span, pdf,I,
-Strong, Span, pdf,I,
+Document,Document,pdf2,D,
+Part,Part,pdf2,G,
+Sect,Sect,pdf2,G,
+Div,Div,pdf2,G,
+Caption,Caption,pdf2,GB,
+NonStruct,NonStruct,pdf2,G,
+H,H,pdf2,B,
+H1,H1,pdf2,B,
+H2,H2,pdf2,B,
+H3,H3,pdf2,B,
+H4,H4,pdf2,B,
+H5,H5,pdf2,B,
+H6,H6,pdf2,B,
+P,P,pdf2,B,
+L,L,pdf2,BI,
+LI,LI,pdf2,L,
+Lbl,Lbl,pdf2,I,
+LBody,LBody,pdf2,L,
+Table,Table,pdf2,B,
+TR,TR,pdf2,T,
+TH,TH,pdf2,T,
+TD,TD,pdf2,T,
+THead,THead,pdf2,T,
+TBody,TBody,pdf2,T,
+TFoot,TFoot,pdf2,T,
+Span,Span,pdf2,I,
+Link,Link,pdf2,GBI,
+Annot,Annot,pdf2,GBI,
+Figure,Figure,pdf2,GBI,
+Formula,Formula,pdf2,GBI,
+Form,Form,pdf2,GBI,
+Ruby,Ruby,pdf2,I,
+RB,RB,pdf2,I,
+RT,RT,pdf2,I,
+Warichu,Warichu,pdf2,I,
+WT,WT,pdf2,I,
+WP,WP,pdf2,I,
+Artifact,Artifact,pdf2,GBI,
+DocumentFragment,DocumentFragment,pdf2,D, %rest only pdf2
+Aside,Aside,pdf2,G,
+H7,H7,pdf2,B,
+H8,H8,pdf2,B,
+H9,H9,pdf2,B,
+H10,H10,pdf2,B,
+Title,Title,pdf2,GB,
+FENote,FENote,pdf2,GBI,
+Sub,Sub,pdf2,I,
+Em,Em,pdf2,I,
+Strong,Strong,pdf2,I,
%%
%%
%% End of file `tagpdf-ns-pdf2.def'.
diff --git a/Master/texmf-dist/doc/latex/tagpdf/tagpdf-parent-child-2.csv b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-parent-child-2.csv
index 9c0a2dd9074..43263cb5513 100644
--- a/Master/texmf-dist/doc/latex/tagpdf/tagpdf-parent-child-2.csv
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-parent-child-2.csv
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-data.dtx
-%% \ProvidesExplFile {tagpdf-parent-child-2.csv} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-parent-child-2.csv} {2022-12-22} {0.98a}
,,,StructTreeRoot,Document,DocumentFragment,Art,Part,Div,Sect,Aside,BlockQuote,NonStruct,TOC,TOCI,Index,Private,Title,Sub,Quote,Note,Reference,BibEntry,P,Hn,H,Lbl,Code,Em,Strong,Span,Link,Annot,Form,Ruby,RB,RT,RP,Warichu,WT,WP,FENote,L,LI,LBody,Table,TR,TH,TD,THead,TBody,TFoot,Caption,Figure,Formula,math,mathml,Artifact,MC
Document,both,document level,1,0..n,0..n,∅,‡,‡,∅,0..n,0..n,‡,∅,∅,∅,0..n,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,0..n,∅
DocumentFragment,2.0,document level,∅,0..n,0..n,0..n,‡,‡,0..n,0..n,0..n,‡,∅,∅,∅,0..n,∅,∅,∅,∅*,∅,∅,∅,∅,∅,∅,∅*,∅,∅,∅,∅*,∅*,∅,∅,∅,∅,∅,∅,∅,∅,∅*,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅*,∅,∅,∅,∅,0..n,∅
diff --git a/Master/texmf-dist/doc/latex/tagpdf/tagpdf-parent-child.csv b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-parent-child.csv
index 975e0bbd360..39567b05cc0 100644
--- a/Master/texmf-dist/doc/latex/tagpdf/tagpdf-parent-child.csv
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf-parent-child.csv
@@ -19,7 +19,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf-data.dtx
-%% \ProvidesExplFile {tagpdf-parent-child.csv} {2022-12-22} {0.98}
+%% \ProvidesExplFile {tagpdf-parent-child.csv} {2022-12-22} {0.98a}
,,,StructTreeRoot,Document,Art,Part,Div,Sect,BlockQuote,NonStruct,TOC,TOCI,Index,Private,Quote,Note,Reference,BibEntry,P,Hn,H,Lbl,Code,Span,Link,Annot,Form,Ruby,RB,RT,RP,Warichu,WT,WP,L,LI,LBody,Table,TR,TH,TD,THead,TBody,TFoot,Caption,Figure,Formula,MC
Document,both,document level,1,0..n,∅,‡,‡,∅,0..n,‡,∅,∅,∅,0..n,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅
Art,1.7,grouping,∅,0..n,∅,‡,‡,0..n,0..n,‡,∅,∅,∅,0..n,∅,0..n,∅,∅,∅,0..1,0..1,∅,∅,∅,0..n,0..n,∅,∅,∅,∅,∅,∅,∅,∅,∅,∅,0..n,∅,∅,0..n,0..n,∅,∅,∅,0..n,0..n,∅,∅
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf.lua b/Master/texmf-dist/tex/latex/tagpdf/tagpdf.lua
index daaf3d6555d..676e7a99b2e 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf.lua
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf.lua
@@ -24,7 +24,7 @@
local ProvidesLuaModule = {
name = "tagpdf",
- version = "0.98", --TAGVERSION
+ version = "0.98a", --TAGVERSION
date = "2022-12-22", --TAGDATE
description = "tagpdf lua code",
license = "The LATEX Project Public License 1.3c"
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty b/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty
index 634f6b0f0cc..ebd2964642a 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty
@@ -28,7 +28,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf.dtx
-\ProvidesExplPackage {tagpdf} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdf} {2022-12-22} {0.98a}
{ A package to experiment with pdf tagging }
\bool_if:nF
@@ -881,9 +881,12 @@
{
\prop_map_inline:Nn\g__tag_role_rolemap_prop
{
- \pdfdict_gput:nnx {g__tag_role/RoleMap_dict}
- {##1}
- {\pdf_name_from_unicode_e:n{##2}}
+ \tl_if_eq:nnF {##1}{##2}
+ {
+ \pdfdict_gput:nnx {g__tag_role/RoleMap_dict}
+ {##1}
+ {\pdf_name_from_unicode_e:n{##2}}
+ }
}
\pdf_object_write:nnx { __tag/tree/rolemap }{dict}
{
@@ -1160,6 +1163,18 @@
}
}
\cs_generate_variant:Nn \__tag_role_add_tag:nn {VV,ne}
+\pdf_version_compare:NnT < {2.0}
+ {
+ \cs_new:Npn \__tag_role_get:nnN #1#2#3
+ {
+ \prop_get:NnNF \g__tag_role_rolemap_prop {#1}#3
+ {
+ \tl_set:Nn #3 {#1}
+ }
+ }
+ \cs_generate_variant:Nn \__tag_role_get:nnN {VVN}
+ }
+
\cs_new_protected:Nn \__tag_role_add_tag:nnnn %tag/namespace/role/namespace
{
\__tag_check_add_tag_role:nnn {#1/#2}{#3}{#4}
@@ -1173,14 +1188,17 @@
\tl_set:Nn\l__tag_tmpa_tl{--UNKNOWN--}
}
\__tag_role_alloctag:nnV {#1}{#2}\l__tag_tmpa_tl
- \pdfdict_gput:nnx {g__tag_role/RoleMapNS_#2_dict}{#1}
- {
- [
- \pdf_name_from_unicode_e:n{#3}
- \c_space_tl
- \pdf_object_ref:n {tag/NS/#4}
- ]
- }
+ \tl_if_in:nnF {-pdf-pdf2-mathml-}{-#2-}
+ {
+ \pdfdict_gput:nnx {g__tag_role/RoleMapNS_#2_dict}{#1}
+ {
+ [
+ \pdf_name_from_unicode_e:n{#3}
+ \c_space_tl
+ \pdf_object_ref:n {tag/NS/#4}
+ ]
+ }
+ }
\tl_if_empty:nF { #2 }
{
\prop_get:cnN { g__tag_role_NS_#4_prop } {#3}\l__tag_tmpa_tl
@@ -1195,6 +1213,20 @@
}
}
\cs_generate_variant:Nn \__tag_role_add_tag:nnnn {VVVV}
+\pdf_version_compare:NnF < {2.0}
+ {
+ \cs_new:Npn \__tag_role_get:nnN #1#2#3
+ {
+ \prop_get:cnNTF {g__tag_role_NS_#2_prop} {#1}\l__tag_get_tmpc_tl
+ {
+ \tl_set:Nx #3 {\exp_last_unbraced:NV\use_i:nn \l__tag_get_tmpc_tl}
+ }
+ {
+ \tl_set:Nn #3 {#1}
+ }
+ }
+ \cs_generate_variant:Nn \__tag_role_get:nnN {VVN}
+ }
\bool_new:N\l__tag_role_update_bool
\bool_set_true:N \l__tag_role_update_bool
@@ -1219,7 +1251,7 @@
\tl_set:Nn \l__tag_tmpa_tl {#5}
}
\__tag_role_alloctag:nnV {#2}{#1}\l__tag_tmpa_tl
- \tl_if_empty:nF {#3}
+ \tl_if_eq:nnF {#2}{#3}
{
\__tag_role_add_tag:nn {#2}{#3}
}
@@ -1254,8 +1286,8 @@
{ ! \tl_if_empty_p:n {#3} }{! \str_if_eq_p:nn {#1}{pdf2}}
{
\__tag_role_add_tag:nnnn {#2}{#1}{#3}{#4}
- \prop_gput:cnn {g__tag_role_NS_#1_prop} {#2}{{#3}{#4}}
}
+ \prop_gput:cnn {g__tag_role_NS_#1_prop} {#2}{{#3}{#4}}
}
}
}
@@ -1408,11 +1440,14 @@
\seq_pop_left:NN \l__tag_role_tmpa_seq\l__tag_get_tmpc_tl
\seq_map_inline:Nn\l__tag_role_tmpa_seq
{
- \tl_if_in:nnF {-Part-Div-NonStruct-}{-##1-}
+ \tl_set:Nx\l__tag_tmpa_tl { \use_ii:nn ##1 }
+ \exp_args:Nne
+ \tl_if_in:nnF {-Part-Div-NonStruct-}{-\l__tag_tmpa_tl-}
{
\tl_set:Nn\l__tag_role_real_parent_tl {##1}
\int_zero:N\l__tag_tmpa_int
- \__tag_role_get_parent_child_rule:nnN {##1}{#2}#3
+ \exp_args:NV
+ \__tag_role_get_parent_child_rule:nnN \l__tag_tmpa_tl{#2}#3
\int_set:Nn\l__tag_tmpa_int{1}
\seq_map_break:
}
@@ -1712,7 +1747,7 @@
\seq_new:N \g__tag_struct_stack_seq
\seq_gpush:Nn \g__tag_struct_stack_seq {0}
\seq_new:N \g__tag_struct_tag_stack_seq
-\seq_gpush:Nn \g__tag_struct_tag_stack_seq {Root}
+\seq_gpush:Nn \g__tag_struct_tag_stack_seq {{Root}{StructTreeRoot}}
\prop_new:N\g__tag_struct_tag_NS_prop
\tl_new:N \l__tag_struct_stack_parent_tmpa_tl
@@ -2317,7 +2352,12 @@
}
}
\seq_gpush:NV \g__tag_struct_stack_seq \c@g__tag_struct_abs_int
- \seq_gpush:NV \g__tag_struct_tag_stack_seq \g__tag_struct_tag_tl
+ \__tag_role_get:VVN
+ \g__tag_struct_tag_tl
+ \g__tag_struct_tag_NS_tl
+ \l__tag_get_tmpc_tl
+ \seq_gpush:Nx \g__tag_struct_tag_stack_seq
+ {{\g__tag_struct_tag_tl}{\l__tag_get_tmpc_tl}}
\tl_gset:NV \g__tag_struct_stack_current_tl \c@g__tag_struct_abs_int
%\seq_show:N \g__tag_struct_stack_seq
\bool_if:NF
@@ -2393,7 +2433,8 @@
}
\seq_get:NNT \g__tag_struct_tag_stack_seq \l__tag_tmpa_tl
{
- \tl_gset:NV \g__tag_struct_tag_tl \l__tag_tmpa_tl
+ \tl_gset:Nx \g__tag_struct_tag_tl
+ { \exp_last_unbraced:NV\use_i:nn \l__tag_tmpa_tl }
}
}
}
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdfdocu-patches.sty b/Master/texmf-dist/tex/latex/tagpdf/tagpdfdocu-patches.sty
index 9e39ec15479..cc4eb9f4b76 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdfdocu-patches.sty
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdfdocu-patches.sty
@@ -1,5 +1,5 @@
%\RequirePackage[enable-debug]{expl3}[2018/06/14]
-\ProvidesExplPackage {tagpdfdocu-patches} {2022-12-22} {0.98}
+\ProvidesExplPackage {tagpdfdocu-patches} {2022-12-22} {0.98a}
{patches/commands for the tagpdf documentation}
\RequirePackage{etoolbox,xpatch}
@@ -10,17 +10,16 @@
\tag_mc_end_push:
\tag_struct_begin:n{tag=Span,alt=TeX,actualtext=TeX}
\tagmcbegin{}
- \kern-.1667em\lower.5ex\hbox{E}\kern-.125emX\@
+ T\kern-.1667em\lower.5ex\hbox{E}\kern-.125emX\@
\tagmcend
\tag_struct_end:
\tag_mc_begin_pop:n{}}
-\DeclareRobustCommand{\LaTeX}{
+\DeclareRobustCommand{\LaTeX}{L\kern-.36em%
{
- \tag_mc_end_push:
- \tag_struct_begin:n{tag=Span,alt=LaTeX,actualtext=LaTeX}
- \tagmcbegin{}
- L\kern-.36em%
- \sbox\z@ T%
+ \tag_mc_end_push:
+ \tag_struct_begin:n{tag=Span,alt=LaTeX,actualtext=LaTeX}
+ \tagmcbegin{}
+ \sbox\z@ T%
\vbox to\ht\z@{\hbox{\check@mathfonts
\fontsize\sf@size\z@
\math@fontsfalse\selectfont
@@ -28,13 +27,11 @@
\vss}%
}%
\kern-.15em%
- \TeX
- \tagmcend
- \tag_struct_end:
- \tag_mc_begin_pop:n{}
- }
-
-
+ T\kern-.1667em\lower.5ex\hbox{E}\kern-.125emX\@
+ \tagmcend
+ \tag_struct_end:
+ \tag_mc_begin_pop:n{}
+ }
% textbf
\AddToHook{cmd/textbf/before}