texlive[63282] Master/texmf-dist: tagpdf (11may22)

commits+karl at tug.org commits+karl at tug.org
Wed May 11 21:52:50 CEST 2022


Revision: 63282
          http://tug.org/svn/texlive?view=revision&revision=63282
Author:   karl
Date:     2022-05-11 21:52:50 +0200 (Wed, 11 May 2022)
Log Message:
-----------
tagpdf (11may22)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/tagpdf/README.md
    trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.pdf
    trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.tex
    trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf.pdf
    trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf.tex
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-backend.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-checks.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-generic.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-luacode.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-shared.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-space.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-struct.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-tree.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-user.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf.dtx
    trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf.ins
    trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-generic.sty
    trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-lua.sty
    trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug.sty
    trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-luatex.def
    trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-generic.sty
    trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-lua.sty
    trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf.lua
    trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty
    trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdfdocu-patches.sty

Added Paths:
-----------
    trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-base.sty

Modified: trunk/Master/texmf-dist/doc/latex/tagpdf/README.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/tagpdf/README.md	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/doc/latex/tagpdf/README.md	2022-05-11 19:52:50 UTC (rev 63282)
@@ -1,6 +1,6 @@
 #tagpdf — A package to create tagged pdf
-Packageversion: 0.93 
-Packagedate: 2022/01/13
+Packageversion: 0.94 
+Packagedate: 2022/05/11
 Author: Ulrike Fischer
 
 ## License

Modified: trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.tex	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf-code.tex	2022-05-11 19:52:50 UTC (rev 63282)
@@ -23,11 +23,7 @@
  for those people who are interested.
 
  \fi
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 
 % The next line is needed so that \GetFileInfo will be able to pick up

Modified: trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf.tex	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/doc/latex/tagpdf/tagpdf.tex	2022-05-11 19:52:50 UTC (rev 63282)
@@ -4,8 +4,8 @@
 \DocumentMetadata{pdfversion=2.0,lang=en-UK,testphase=phase-II}
 
 \makeatletter
-\def\UlrikeFischer at package@version{0.93}
-\def\UlrikeFischer at package@date{2022-01-13}
+\def\UlrikeFischer at package@version{0.94}
+\def\UlrikeFischer at package@date{2022-05-11}
 \makeatother
 
 \documentclass[DIV=12,parskip=half-,bibliography=totoc]{scrartcl}
@@ -57,7 +57,7 @@
  }
 
 \usepackage{hyperxmp}
-\usepackage[pdfdisplaydoctitle=true,hyperfootnotes=false,
+\usepackage[pdfdisplaydoctitle=true,%hyperfootnotes=false,
             ]{hyperref}
 
  \hypersetup{
@@ -96,9 +96,6 @@
 
 \begin{document}
 
-\tagstructbegin{tag=Document}
-
-
 \tagstructbegin{tag=Title}
 \tagmcbegin{tag=Title}
 
@@ -150,6 +147,14 @@
 
 
 \tableofcontents
+\section{Preface to version 0.94}
+
+In this version a small package, \pkg{tagpdf-base} has been added. It provides
+no-op versions of the main expl3 user commands for packages that want to support
+tagging but can't be sure if the \pkg{tagpdf} package has been loaded.
+
+
+
 \section{Preface to version 0.93}
 The main change in the package itself in this version is the support for structure destinations.
 This is a new type of destinations in \PDF~2.0.
@@ -189,7 +194,7 @@
 But in my opinion missing are means to \emph{experiment} with tagging and accessibility. Means to try out, how difficult it is to tag some structures, means to try out, how much tagging is really needed (standards and validators don't need to be right \ldots), means to test what else is needed so that a \PDF{} works e.g. with a screen reader. Without such experiments it is imho quite difficult to get a feeling about what has to be done, which kernel changes are needed, how packages should be adapted.
 
 This package tries to close this gap by offering \emph{core} commands to tag a \PDF{}%
-\tagpdfparaOff\footnote{In case you don't know what this means: there will be some explanations later on.}\tagpdfparaOn.
+\footnote{In case you don't know what this means: there will be some explanations later on.}.
 
 My hope is that the knowledge gained by the use of this package will at the end allow to decide if and how code to do tagging should be part of the \LaTeX\ kernel.
 
@@ -566,7 +571,7 @@
 \section{Tagging}
 
 
-pdf is a page orientated graphic format. It simply puts ink and glyphs at various coordinates on a page. A simple stream of a page can look like this\tagpdfparaOff\footnote{The appendix contains some remarks about the syntax of a \PDF{} file}\tagpdfparaOn:
+pdf is a page orientated graphic format. It simply puts ink and glyphs at various coordinates on a page. A simple stream of a page can look like this\footnote{The appendix contains some remarks about the syntax of a \PDF{} file}:
 
 \begin{lstlisting}[columns=fixed]
 stream
@@ -711,7 +716,7 @@
 
 
 
-\item[Content]  Content is marked also with of a pair of keywords, \texttt{BDC} and \texttt{EMC}. The first argument of \texttt{BDC} is a tag name which describes the structural type of the text\tagpdfparaOff\footnote{There is quite some redundancy in the specification here. The structural type is also set in the structure tree. One wonders if it isn't enough to use  always \texttt{/SPAN} here.}\tagpdfparaOn
+\item[Content]  Content is marked also with of a pair of keywords, \texttt{BDC} and \texttt{EMC}. The first argument of \texttt{BDC} is a tag name which describes the structural type of the text\footnote{There is quite some redundancy in the specification here. The structural type is also set in the structure tree. One wonders if it isn't enough to use  always \texttt{/SPAN} here.}
     Examples are \texttt{/P} (paragraph), \texttt{/H2} (heading), \texttt{/TD} (table cell). The reference mentions a number of standard types but it is possible to add more or to use different names.
 
 In the second argument of \texttt{BDC} -- in the property dictionary -- more data can be stored. \emph{Required} is an \texttt{/MCID}-key which takes an integer as a value:
@@ -1436,7 +1441,8 @@
 One or more such attributes can be attached to a structure element. It is also possible to store such an attribute under a symbolic name in a so-called \enquote{ClassedMap} and then to attach references to such classes to a structure.
 
 To use such attributes you must at first declare it in \verb+\tagpdfsetup+ with the key \texttt{newattribute}. This key takes two argument, a name and the content of the attribute.
-The name should be a sensible key name, the content a dictionary.
+The name should be a sensible key name, it is converted to a pdf name with
+\verb+\pdf_name_from_unicode_e:n+, so slashes and spaces are allow. The content should be a dictionary without the braket.
 
 
 
@@ -1987,7 +1993,6 @@
 \end{description}
 
 
-\tagstructend %document
 \end{document}
 %http://msf.mathmlcloud.org/file_formats/8 %sample \PDF{} for math
 

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-backend.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-backend.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-backend.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -23,11 +23,7 @@
 % for those people who are interested.
 %
 %<*driver>
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 \usepackage{array,booktabs,caption}
 \hypersetup{pdfauthor=Ulrike Fischer,
@@ -51,13 +47,13 @@
 %    }^^A
 % }
 %
-% \date{Version 0.93, released 2022-01-13}
+% \date{Version 0.94, released 2022-05-11}
 % \maketitle
 % \begin{implementation}
 %    \begin{macrocode}
 %<@@=tag>
 %<*luatex>
-\ProvidesExplFile {tagpdf-luatex.def} {2022-01-13} {0.93}
+\ProvidesExplFile {tagpdf-luatex.def} {2022-05-11} {0.94}
   {tagpdf~driver~for~luatex}
 %    \end{macrocode}
 % \section{Loading the lua}
@@ -161,8 +157,8 @@
 
 local ProvidesLuaModule = {
     name          = "tagpdf",
-    version       = "0.93",       --TAGVERSION
-    date          = "2022-01-13", --TAGDATE
+    version       = "0.94",       --TAGVERSION
+    date          = "2022-05-11", --TAGDATE
     description   = "tagpdf lua code",
     license       = "The LATEX Project Public License 1.3c"
 }

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-checks.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-checks.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-checks.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -24,11 +24,7 @@
 %
 %
 %<*driver>
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 \usepackage{array,booktabs,caption}
 \hypersetup{pdfauthor=Ulrike Fischer,
@@ -52,7 +48,7 @@
 %    }^^A
 % }
 %
-% \date{Version 0.93, released 2022-01-13}
+% \date{Version 0.94, released 2022-05-11}
 % \maketitle
 % \begin{documentation}
 % \section{Commands}
@@ -298,7 +294,7 @@
 %    \begin{macrocode}
 %<@@=tag>
 %<*header>
-\ProvidesExplPackage {tagpdf-checks-code} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-checks-code} {2022-05-11} {0.94}
  {part of tagpdf - code related to checks, conditionals, debugging and messages}
 %</header>
 %    \end{macrocode}
@@ -468,6 +464,7 @@
 % the only sensible values for the argument are |mc_tag| and |struct_tag|.
 %    \begin{macrocode}
 \cs_new:Npn \tag_get:n #1   { \use:c {@@_get_data_#1: } }
+%</package>
 %    \end{macrocode}
 % \end{macro}
 %
@@ -478,7 +475,12 @@
 % The test is true if all booleans, the global and the two local one are true.
 %
 %    \begin{macrocode}
+%<*base>
 \prg_new_conditional:Npnn \tag_if_active: { p , T , TF, F }
+  { \prg_return_false: }
+%</base>
+%<*package>
+\prg_set_conditional:Npnn \tag_if_active: { p , T , TF, F }
   {
      \bool_lazy_all:nTF
        {
@@ -528,7 +530,7 @@
   }
 %    \end{macrocode}
 % \end{macro}
-% \subsection{Checks related to stuctures}
+% \subsection{Checks related to structures}
 % \begin{macro}{\@@_check_structure_has_tag:n}
 % 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.

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-generic.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-generic.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-generic.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -1,6 +1,6 @@
 % \iffalse meta-comment
 %
-%% File: tagpdf-mc.dtx
+%% File: tagpdf-mc-generic.dtx
 %
 % Copyright (C) 2019-2022 Ulrike Fischer
 %
@@ -22,11 +22,7 @@
 %
 % for those people who are interested.
 %<*driver>
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 \usepackage{array,booktabs,caption}
 \hypersetup{pdfauthor=Ulrike Fischer,
@@ -50,7 +46,7 @@
 %    }^^A
 % }
 %
-% \date{Version 0.93, released 2022-01-13}
+% \date{Version 0.94, released 2022-05-11}
 % \maketitle
 % \begin{documentation}
 % \end{documentation}
@@ -59,11 +55,11 @@
 %    \begin{macrocode}
 %<@@=tag>
 %<*generic>
-\ProvidesExplPackage {tagpdf-mc-code-generic} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-mc-code-generic} {2022-05-11} {0.94}
  {part of tagpdf - code related to marking chunks - generic mode}
 %</generic>
 %<*debug>
-\ProvidesExplPackage {tagpdf-debug-generic} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-debug-generic} {2022-05-11} {0.94}
  {part of tagpdf - debugging code related to marking chunks - generic mode}
 %</debug>
 %    \end{macrocode}
@@ -668,9 +664,11 @@
 % the state is passed to the end command through a global var and
 % a global boolean.
 %    \begin{macrocode}
+%<base>\cs_new_protected:Npn \tag_mc_begin:n #1 {}
+%<base>\cs_new_protected:Nn \tag_mc_end:{}
 %<*generic|debug>
 %<*generic>
-\cs_new_protected:Npn \tag_mc_begin:n #1 %#1 keyval
+\cs_set_protected:Npn \tag_mc_begin:n #1 %#1 keyval
   {
     \@@_check_if_active_mc:T
       {
@@ -717,7 +715,7 @@
 %</debug>
   }
 %<*generic>
-\cs_new_protected:Nn \tag_mc_end:
+\cs_set_protected:Nn \tag_mc_end:
   {
     \@@_check_if_active_mc:T
       {

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-luacode.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-luacode.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-luacode.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -1,6 +1,6 @@
 % \iffalse meta-comment
 %
-%% File: tagpdf-mc.dtx
+%% File: tagpdf-mc-luacode.dtx
 %
 % Copyright (C) 2019-2022 Ulrike Fischer
 %
@@ -22,11 +22,7 @@
 %
 % for those people who are interested.
 %<*driver>
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 \usepackage{array,booktabs,caption}
 \hypersetup{pdfauthor=Ulrike Fischer,
@@ -50,7 +46,7 @@
 %    }^^A
 % }
 %
-% \date{Version 0.93, released 2022-01-13}
+% \date{Version 0.94, released 2022-05-11}
 % \maketitle
 % \begin{implementation}
 % The code is splitted into three parts: code shared by all engines,
@@ -90,7 +86,7 @@
 %    \begin{macrocode}
 %<@@=tag>
 %<*luamode>
-\ProvidesExplPackage {tagpdf-mc-code-lua} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-mc-code-lua} {2022-05-11} {0.94}
   {tagpdf - mc code only for the luamode }
 %</luamode>
 %    \end{macrocode}
@@ -294,7 +290,7 @@
 % We currently don't check if there is nesting as it doesn't matter so
 % much in lua.
 %    \begin{macrocode}
-\cs_new_protected:Nn \tag_mc_begin:n
+\cs_set_protected:Nn \tag_mc_begin:n
   {
     \@@_check_if_active_mc:T
       {
@@ -331,7 +327,7 @@
 %
 % TODO: check how the use command must be guarded.
 %    \begin{macrocode}
-\cs_new_protected:Nn \tag_mc_end:
+\cs_set_protected:Nn \tag_mc_end:
   {
     \@@_check_if_active_mc:T
       {

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-shared.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-shared.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-mc-shared.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -1,6 +1,6 @@
 % \iffalse meta-comment
 %
-%% File: tagpdf-mc.dtx
+%% File: tagpdf-mc-shared.dtx
 %
 % Copyright (C) 2019-2022 Ulrike Fischer
 %
@@ -22,11 +22,7 @@
 %
 % for those people who are interested.
 %<*driver>
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 \usepackage{array,booktabs,caption}
 \hypersetup{pdfauthor=Ulrike Fischer,
@@ -50,7 +46,7 @@
 %    }^^A
 % }
 %
-% \date{Version 0.93, released 2022-01-13}
+% \date{Version 0.94, released 2022-05-11}
 % \maketitle
 % \begin{documentation}
 % \section{Public Commands}
@@ -178,7 +174,7 @@
 %    \begin{macrocode}
 %<@@=tag>
 %<*header>
-\ProvidesExplPackage {tagpdf-mc-code-shared} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-mc-code-shared} {2022-05-11} {0.94}
   {part of tagpdf - code related to marking chunks -
    code shared by generic and luamode }
 %</header>
@@ -300,6 +296,7 @@
   {
     \tl_new:c { g_@@_mc_label_\tl_to_str:n{#1}_used_tl }
   }
+%</shared>
 %    \end{macrocode}
 %
 % \end{macro}
@@ -311,7 +308,9 @@
 %
 % TODO: is testing for struct the right test?
 %    \begin{macrocode}
-\cs_new_protected:Npn \tag_mc_use:n #1 %#1: label name
+%<base>\cs_new_protected:Npn \tag_mc_use:n #1 {}
+%<*shared>
+\cs_set_protected:Npn \tag_mc_use:n #1 %#1: label name
   {
     \@@_check_if_active_struct:T
       {
@@ -332,6 +331,7 @@
           }
        }
   }
+%</shared>
 %    \end{macrocode}
 % \end{macro}
 % \begin{macro}
@@ -343,7 +343,10 @@
 % and then stops all tagging. It creates a group.
 % It pushes and pops mc-chunks at the begin and end.
 %    \begin{macrocode}
-\cs_new_protected:Npn \tag_mc_artifact_group_begin:n #1
+%<base>\cs_new_protected:Npn \tag_mc_artifact_group_begin:n #1 {}
+%<base>\cs_new_protected:Npn \tag_mc_artifact_group_end:{}
+%<*shared>
+\cs_set_protected:Npn \tag_mc_artifact_group_begin:n #1
  {
   \tag_mc_end_push:
   \tag_mc_begin:n {artifact=#1}
@@ -350,12 +353,13 @@
   \tag_stop_group_begin:
  }
 
-\cs_new_protected:Npn \tag_mc_artifact_group_end:
+\cs_set_protected:Npn \tag_mc_artifact_group_end:
  {
   \tag_stop_group_end:
   \tag_mc_end:
   \tag_mc_begin_pop:n{}
  }
+%</shared>
 %    \end{macrocode}
 % \end{macro}
 %
@@ -362,7 +366,10 @@
 % \begin{macro}{\tag_mc_end_push:, \tag_mc_begin_pop:n}
 %
 %    \begin{macrocode}
-\cs_new_protected:Npn \tag_mc_end_push:
+%<base>\cs_new_protected:Npn \tag_mc_end_push: {}
+%<base>\cs_new_protected:Npn \tag_mc_begin_pop:n #1 {}
+%<*shared>
+\cs_set_protected:Npn \tag_mc_end_push:
   {
     \@@_check_if_active_mc:T
       {
@@ -381,7 +388,7 @@
       }
   }
 
-\cs_new_protected:Npn \tag_mc_begin_pop:n #1
+\cs_set_protected:Npn \tag_mc_begin_pop:n #1
   {
     \@@_check_if_active_mc:T
       {

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -22,11 +22,7 @@
 %
 % for those people who are interested.
 %<*driver>
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 \usepackage{array,booktabs,caption}
 \hypersetup{pdfauthor=Ulrike Fischer,
@@ -50,7 +46,7 @@
 %    }^^A
 % }
 %
-% \date{Version 0.93, released 2022-01-13}
+% \date{Version 0.94, released 2022-05-11}
 % \maketitle
 % \begin{documentation}
 % \begin{function}
@@ -91,7 +87,7 @@
 %    \begin{macrocode}
 %<@@=tag>
 %<*header>
-\ProvidesExplPackage {tagpdf-roles-code} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-roles-code} {2022-05-11} {0.94}
  {part of tagpdf - code related to roles and structure names}
 %</header>
 %    \end{macrocode}

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-space.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-space.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-space.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -22,11 +22,7 @@
 %
 % for those people who are interested.
 %<*driver>
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 \usepackage{array,booktabs,caption}
 \hypersetup{pdfauthor=Ulrike Fischer,
@@ -50,7 +46,7 @@
 %    }^^A
 % }
 %
-% \date{Version 0.93, released 2022-01-13}
+% \date{Version 0.94, released 2022-05-11}
 % \maketitle
 % \begin{documentation}
 % \begin{function}{interwordspace (setup-key)}
@@ -68,7 +64,7 @@
 %    \begin{macrocode}
 %<@@=tag>
 %<*header>
-\ProvidesExplPackage {tagpdf-space-code} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-space-code} {2022-05-11} {0.94}
  {part of tagpdf - code related to real space chars}
 %</header>
 %    \end{macrocode}

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-struct.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-struct.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-struct.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -22,11 +22,7 @@
 %
 % for those people who are interested.
 %<*driver>
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 \usepackage{array,booktabs,caption}
 \hypersetup{pdfauthor=Ulrike Fischer,
@@ -50,7 +46,7 @@
 %    }^^A
 % }
 %
-% \date{Version 0.93, released 2022-01-13}
+% \date{Version 0.94, released 2022-05-11}
 % \maketitle
 % \begin{documentation}
 % \section{Public Commands}
@@ -221,7 +217,7 @@
 %    \begin{macrocode}
 %<@@=tag>
 %<*header>
-\ProvidesExplPackage {tagpdf-struct-code} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-struct-code} {2022-05-11} {0.94}
  {part of tagpdf - code related to storing structure}
 %</header>
 %    \end{macrocode}
@@ -969,7 +965,6 @@
        \group_end:
      }
  }
-%</package>
 %    \end{macrocode}
 % \end{macro}
 % \begin{macro}{root-AF (setup-key)}
@@ -998,6 +993,7 @@
           }
       },
   }
+%</package>
 %    \end{macrocode}
 % \end{macro}
 % \section{User commands}
@@ -1004,8 +1000,10 @@
 %
 % \begin{macro}{\tag_struct_begin:n,\tag_struct_end:}
 %    \begin{macrocode}
+%<base>\cs_new_protected:Npn \tag_struct_begin:n #1 {}
+%<base>\cs_new_protected:Npn \tag_struct_end:{}
 %<*package|debug>
-%<package>\cs_new_protected:Npn \tag_struct_begin:n #1 %#1 key-val
+%<package>\cs_set_protected:Npn \tag_struct_begin:n #1 %#1 key-val
 %<debug>\cs_set_protected:Npn \tag_struct_begin:n #1 %#1 key-val
   {
 %<package>\@@_check_if_active_struct:T
@@ -1067,7 +1065,7 @@
      }
 %<debug>{ \@@_debug_struct_begin_ignore:n { #1 }}
   }
-%<package>\cs_new_protected:Nn \tag_struct_end:
+%<package>\cs_set_protected:Nn \tag_struct_end:
 %<debug>\cs_set_protected:Nn \tag_struct_end:
   { %take the current structure num from the stack:
     %the objects are written later, lua mode hasn't all needed info yet
@@ -1104,8 +1102,9 @@
 % This command allows to use a stashed structure in another place.
 % TODO: decide how it should be guarded. Probably by the struct-check.
 %    \begin{macrocode}
+%<base>\cs_new_protected:Npn \tag_struct_use:n #1 {}
 %<*package>
-\cs_new_protected:Nn \tag_struct_use:n %#1 is the label
+\cs_set_protected:Npn \tag_struct_use:n #1 %#1 is the label
   {
     \@@_check_if_active_struct:T
       {
@@ -1171,7 +1170,7 @@
 % \section{Attributes and attribute classes}
 %    \begin{macrocode}
 %<*header>
-\ProvidesExplPackage {tagpdf-attr-code} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-attr-code} {2022-05-11} {0.94}
   {part of tagpdf - code related to attributes and attribute classes}
 %</header>
 %    \end{macrocode}
@@ -1217,8 +1216,8 @@
 %    \begin{macrocode}
 \cs_new_protected:Npn \@@_attr_new_entry:nn #1 #2 %#1:name, #2: content
   {
-    \prop_gput:Nnn \g_@@_attr_entries_prop
-      {#1}{#2}
+    \prop_gput:Nen \g_@@_attr_entries_prop
+      {\pdf_name_from_unicode_e:n{#1}}{#2}
   }
 
 \keys_define:nn { @@ / setup }
@@ -1239,7 +1238,14 @@
     attribute-class .code:n =
      {
        \clist_set:No \l_@@_tmpa_clist { #1 }
-       \seq_set_from_clist:NN \l_@@_tmpa_seq \l_@@_tmpa_clist
+       \seq_set_from_clist:NN \l_@@_tmpb_seq \l_@@_tmpa_clist
+%    \end{macrocode}
+%    we convert the names into pdf names with slash
+%    \begin{macrocode}
+       \seq_set_map_x:NNn \l_@@_tmpa_seq \l_@@_tmpb_seq
+         {
+           \pdf_name_from_unicode_e:n {##1}
+         }
        \seq_map_inline:Nn \l_@@_tmpa_seq
          {
            \prop_if_in:NnF \g_@@_attr_entries_prop {##1}
@@ -1248,14 +1254,10 @@
              }
            \seq_gput_left:Nn\g_@@_attr_class_used_seq { ##1}
          }
-       \seq_set_map:NNn \l_@@_tmpb_seq \l_@@_tmpa_seq
-         {
-           /##1
-         }
        \tl_set:Nx \l_@@_tmpa_tl
          {
            \int_compare:nT { \seq_count:N \l_@@_tmpa_seq > 1 }{[}
-           \seq_use:Nn \l_@@_tmpb_seq  { \c_space_tl  }
+           \seq_use:Nn \l_@@_tmpa_seq  { \c_space_tl  }
            \int_compare:nT { \seq_count:N \l_@@_tmpa_seq > 1 }{]}
          }
        \int_compare:nT { \seq_count:N \l_@@_tmpa_seq > 0 }
@@ -1277,7 +1279,14 @@
     attribute .code:n  = % A property (attribute, value currently a dictionary)
       {
         \clist_set:No          \l_@@_tmpa_clist { #1 }
-        \seq_set_from_clist:NN \l_@@_tmpa_seq \l_@@_tmpa_clist
+        \seq_set_from_clist:NN \l_@@_tmpb_seq \l_@@_tmpa_clist
+%    \end{macrocode}
+%    we convert the names into pdf names with slash
+%    \begin{macrocode}
+       \seq_set_map_x:NNn \l_@@_tmpa_seq \l_@@_tmpb_seq
+         {
+           \pdf_name_from_unicode_e:n {##1}
+         }
         \tl_set:Nx \l_@@_attr_value_tl
           {
             \int_compare:nT { \seq_count:N \l_@@_tmpa_seq > 1 }{[}%]

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-tree.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-tree.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-tree.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -23,11 +23,7 @@
 % for those people who are interested.
 %
 %<*driver>
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 \usepackage{array,booktabs,caption}
 \hypersetup{pdfauthor=Ulrike Fischer,
@@ -51,13 +47,13 @@
 %    }^^A
 % }
 %
-% \date{Version 0.93, released 2022-01-13}
+% \date{Version 0.94, released 2022-05-11}
 % \maketitle
 % \begin{implementation}
 %    \begin{macrocode}
 %<@@=tag>
 %<*header>
-\ProvidesExplPackage {tagpdf-tree-code} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-tree-code} {2022-05-11} {0.94}
  {part of tagpdf - code related to writing trees and dictionaries to the pdf}
 %</header>
 %    \end{macrocode}
@@ -333,7 +329,7 @@
     \seq_gremove_duplicates:N \g_@@_attr_class_used_seq
     \seq_set_map:NNn \l_@@_tmpa_seq \g_@@_attr_class_used_seq
       {
-        /##1\c_space_tl
+        ##1\c_space_tl
         <<
           \prop_item:Nn
             \g_@@_attr_entries_prop

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-user.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-user.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf-user.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -22,11 +22,7 @@
 %
 % for those people who are interested.
 %<*driver>
-\RequirePackage{pdfmanagement-testphase}
-\DeclareDocumentMetadata{}
-\makeatletter
-\declare at file@substitution{doc.sty}{doc-v3beta.sty}
-\makeatother
+\DocumentMetadata{}
 \documentclass{l3doc}
 \usepackage{array,booktabs,caption}
 \hypersetup{pdfauthor=Ulrike Fischer,
@@ -50,7 +46,7 @@
 %    }^^A
 % }
 %
-% \date{Version 0.93, released 2022-01-13}
+% \date{Version 0.94, released 2022-05-11}
 % \maketitle
 % \begin{documentation}
 % \section{Setup commands}
@@ -250,7 +246,7 @@
 %    \begin{macrocode}
 %<@@=tag>
 %<*header>
-\ProvidesExplPackage {tagpdf-user} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-user} {2022-05-11} {0.94}
   {tagpdf - user commands}
 %</header>
 %    \end{macrocode}

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf.dtx	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf.dtx	2022-05-11 19:52:50 UTC (rev 63282)
@@ -33,9 +33,10 @@
 % \end{syntax}
 % \end{function}
 %
-% \begin{function}{ \tag_stop_group_begin:, \tag_stop_group_end: }
+% \begin{function}{ \tag_stop_group_begin:, \tag_stop_group_end:, \tag_stop: }
 % We need a command to stop tagging in some places.
-% This simply switches the two local booleans.
+% This simply switches the two local booleans. The grouping commands
+% can be used to group the effect.
 % \end{function}
 %
 % \begin{function}{activate-space (setup-key)}
@@ -80,7 +81,7 @@
 %    \begin{macrocode}
 %<@@=tag>
 %<*package>
-\ProvidesExplPackage {tagpdf} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf} {2022-05-11} {0.94}
   { A package to experiment with pdf tagging }
 
 \bool_if:nF
@@ -98,7 +99,7 @@
      {
        Activate~it~with \MessageBreak
        \string\RequirePackage{pdfmanagement-testphase}\MessageBreak
-       \string\DeclareDocumentMetadata{<options>}\MessageBreak
+       \string\DocumentMetadata{<options>}\MessageBreak
        before~\string\documentclass
      }
   }
@@ -106,7 +107,7 @@
 %    \end{macrocode}
 %<*debug>
 %    \begin{macrocode}
-\ProvidesExplPackage {tagpdf-debug} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-debug} {2022-05-11} {0.94}
   { debug code for tagpdf }
 \@ifpackageloaded{tagpdf}{}{\PackageWarning{tagpdf-debug}{tagpdf~not~loaded,~quitting}\endinput}
     \end{macrocode}
@@ -140,7 +141,17 @@
 %    \begin{macrocode}
 \RequirePackage{l3ref-tmp}
 %    \end{macrocode}
-%
+% To be on the safe side for now, load also the base definitions
+%    \begin{macrocode}
+\RequirePackage{tagpdf-base}
+%</package>
+%    \end{macrocode}
+%    \begin{macrocode}
+%<*base>
+\ProvidesExplPackage {tagpdf-base} {2022-05-11} {0.94}
+  {part of tagpdf - provide base, no-op versions of the user commands }
+%</base>
+%    \end{macrocode}
 % \section{Temporary code}
 % This is code which will be removed when proper support exists in LaTeX
 % \subsection{a LastPage label}
@@ -147,6 +158,7 @@
 % See also issue \#2 in Accessible-xref
 % \begin{macro}{\@@_lastpagelabel:}
 %    \begin{macrocode}
+%<*package>
  \cs_new_protected:Npn \@@_lastpagelabel:
    {
      \legacy_if:nT { @filesw }
@@ -302,7 +314,7 @@
 \cs_generate_variant:Nn \pdf_object_ref:n {e}
 \cs_generate_variant:Nn \pdfannot_dict_put:nnn {nnx}
 \cs_generate_variant:Nn \pdffile_embed_stream:nnn {nxx,oxx}
-\cs_generate_variant:Nn \prop_gput:Nnn {Nxx}
+\cs_generate_variant:Nn \prop_gput:Nnn {Nxx,Nen}
 \cs_generate_variant:Nn \prop_put:Nnn  {Nxx}
 \cs_generate_variant:Nn \ref_label:nn { nv }
 \cs_generate_variant:Nn \seq_set_split:Nnn{Nne}
@@ -427,6 +439,11 @@
     \bool_set_false:N \l_@@_active_mc_bool
   }
 \cs_set_eq:NN \tag_stop_group_end: \group_end:
+\cs_new_protected:Npn \tag_stop:
+  {
+    \bool_set_false:N \l_@@_active_struct_bool
+    \bool_set_false:N \l_@@_active_mc_bool
+  }
 %    \end{macrocode}
 % \end{macro}
 %

Modified: trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf.ins
===================================================================
--- trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf.ins	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/source/latex/tagpdf/tagpdf.ins	2022-05-11 19:52:50 UTC (rev 63282)
@@ -70,6 +70,17 @@
   }
 
 \generate
+ {\file{tagpdf-base.sty}
+   {
+    \from{tagpdf.dtx}{base}
+    \from{tagpdf-mc-generic.dtx}{base}
+    \from{tagpdf-mc-shared.dtx}{base}
+    \from{tagpdf-struct.dtx}{base}
+    \from{tagpdf-checks.dtx}{base}
+   }
+ }
+
+\generate
   {\file{tagpdf-luatex.def}{\from{tagpdf-backend.dtx}{luatex}}}
 \generate
   {\file{tagpdf-mc-code-generic.sty}{\from{tagpdf-mc-generic.dtx}{generic}}}
@@ -97,6 +108,7 @@
 \generate
   {\file{tagpdf-debug-lua.sty}{\from{tagpdf-mc-luacode.dtx}{debug}}}
 
+
 \def\MetaPrefix{-- }
 \def\defaultpostamble{%
   \MetaPrefix^^J%

Added: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-base.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-base.sty	                        (rev 0)
+++ trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-base.sty	2022-05-11 19:52:50 UTC (rev 63282)
@@ -0,0 +1,49 @@
+%%
+%% This is file `tagpdf-base.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% tagpdf.dtx  (with options: `base')
+%% tagpdf-mc-generic.dtx  (with options: `base')
+%% tagpdf-mc-shared.dtx  (with options: `base')
+%% tagpdf-struct.dtx  (with options: `base')
+%% tagpdf-checks.dtx  (with options: `base')
+%% 
+%% Copyright (C) 2019-2022 Ulrike Fischer
+%% 
+%% 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 "tagpdf bundle" (The Work in LPPL)
+%% and all files in that bundle must be distributed together.
+%% 
+%% File: tagpdf.dtx
+\ProvidesExplPackage {tagpdf-base} {2022-05-11} {0.94}
+  {part of tagpdf - provide base, no-op versions of the user commands }
+%% File: tagpdf-mc-generic.dtx
+\cs_new_protected:Npn \tag_mc_begin:n #1 {}
+\cs_new_protected:Nn \tag_mc_end:{}
+
+%% File: tagpdf-mc-shared.dtx
+
+\cs_new_protected:Npn \tag_mc_use:n #1 {}
+\cs_new_protected:Npn \tag_mc_artifact_group_begin:n #1 {}
+\cs_new_protected:Npn \tag_mc_artifact_group_end:{}
+\cs_new_protected:Npn \tag_mc_end_push: {}
+\cs_new_protected:Npn \tag_mc_begin_pop:n #1 {}
+%% File: tagpdf-struct.dtx
+\cs_new_protected:Npn \tag_struct_begin:n #1 {}
+\cs_new_protected:Npn \tag_struct_end:{}
+\cs_new_protected:Npn \tag_struct_use:n #1 {}
+
+%% File: tagpdf-checks.dtx
+\prg_new_conditional:Npnn \tag_if_active: { p , T , TF, F }
+  { \prg_return_false: }
+%% 
+%%
+%% End of file `tagpdf-base.sty'.


Property changes on: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-base.sty
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-generic.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-generic.sty	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-generic.sty	2022-05-11 19:52:50 UTC (rev 63282)
@@ -18,8 +18,8 @@
 %% This file is part of the "tagpdf bundle" (The Work in LPPL)
 %% and all files in that bundle must be distributed together.
 %% 
-%% File: tagpdf-mc.dtx
-\ProvidesExplPackage {tagpdf-debug-generic} {2022-01-13} {0.93}
+%% File: tagpdf-mc-generic.dtx
+\ProvidesExplPackage {tagpdf-debug-generic} {2022-05-11} {0.94}
  {part of tagpdf - debugging code related to marking chunks - generic mode}
 \cs_set_protected:Npn \tag_mc_begin:n #1 %#1 keyval
   {

Modified: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-lua.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-lua.sty	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug-lua.sty	2022-05-11 19:52:50 UTC (rev 63282)
@@ -18,7 +18,7 @@
 %% This file is part of the "tagpdf bundle" (The Work in LPPL)
 %% and all files in that bundle must be distributed together.
 %% 
-%% File: tagpdf-mc.dtx
+%% File: tagpdf-mc-luacode.dtx
 %% 
 %%
 %% End of file `tagpdf-debug-lua.sty'.

Modified: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug.sty	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-debug.sty	2022-05-11 19:52:50 UTC (rev 63282)
@@ -26,7 +26,7 @@
 %% and all files in that bundle must be distributed together.
 %% 
 %% File: tagpdf.dtx
-\ProvidesExplPackage {tagpdf-debug} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf-debug} {2022-05-11} {0.94}
   { debug code for tagpdf }
 \@ifpackageloaded{tagpdf}{}{\PackageWarning{tagpdf-debug}{tagpdf~not~loaded,~quitting}\endinput}
     \end{macrocode}
@@ -113,33 +113,11 @@
 %% File: tagpdf-user.dtx
 
 
-%% File: tagpdf-mc.dtx
+%% File: tagpdf-mc-shared.dtx
 
 %% File: tagpdf-tree.dtx
 %% File: tagpdf-roles.dtx
 %% File: tagpdf-struct.dtx
-\keys_define:nn { __tag / setup }
-  {
-    root-AF .code:n =
-     {
-        \pdf_object_if_exist:nTF {#1}
-          {
-            \__tag_struct_add_AF:en { 0 }{#1}
-            \__tag_prop_gput:cnx
-             { g__tag_struct_0_prop }
-             { AF }
-             {
-               [
-                 \tl_use:c
-                   { g__tag_struct_0_AF_tl }
-               ]
-             }
-          }
-          {
-
-          }
-      },
-  }
 \cs_set_protected:Npn \tag_struct_begin:n #1 %#1 key-val
   {
 \__tag_check_if_active_struct:TF

Modified: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-luatex.def
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-luatex.def	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-luatex.def	2022-05-11 19:52:50 UTC (rev 63282)
@@ -19,7 +19,7 @@
 %% and all files in that bundle must be distributed together.
 %% 
 %% File: tagpdf-backend.dtx
-\ProvidesExplFile {tagpdf-luatex.def} {2022-01-13} {0.93}
+\ProvidesExplFile {tagpdf-luatex.def} {2022-05-11} {0.94}
   {tagpdf~driver~for~luatex}
 {
   \fontencoding{TU}\fontfamily{lmr}\fontseries{m}\fontshape{n}\fontsize{10pt}{10pt}\selectfont

Modified: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-generic.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-generic.sty	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-generic.sty	2022-05-11 19:52:50 UTC (rev 63282)
@@ -18,8 +18,8 @@
 %% This file is part of the "tagpdf bundle" (The Work in LPPL)
 %% and all files in that bundle must be distributed together.
 %% 
-%% File: tagpdf-mc.dtx
-\ProvidesExplPackage {tagpdf-mc-code-generic} {2022-01-13} {0.93}
+%% File: tagpdf-mc-generic.dtx
+\ProvidesExplPackage {tagpdf-mc-code-generic} {2022-05-11} {0.94}
  {part of tagpdf - code related to marking chunks - generic mode}
 \__tag_prop_new:N \g__tag_MCID_byabspage_prop
 
@@ -332,7 +332,7 @@
   }
 
 \cs_new:Nn \__tag_get_data_mc_tag: { \g__tag_mc_key_tag_tl }
-\cs_new_protected:Npn \tag_mc_begin:n #1 %#1 keyval
+\cs_set_protected:Npn \tag_mc_begin:n #1 %#1 keyval
   {
     \__tag_check_if_active_mc:T
       {
@@ -365,7 +365,7 @@
         \group_end:
       }
   }
-\cs_new_protected:Nn \tag_mc_end:
+\cs_set_protected:Nn \tag_mc_end:
   {
     \__tag_check_if_active_mc:T
       {

Modified: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-lua.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-lua.sty	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf-mc-code-lua.sty	2022-05-11 19:52:50 UTC (rev 63282)
@@ -18,8 +18,8 @@
 %% This file is part of the "tagpdf bundle" (The Work in LPPL)
 %% and all files in that bundle must be distributed together.
 %% 
-%% File: tagpdf-mc.dtx
-\ProvidesExplPackage {tagpdf-mc-code-lua} {2022-01-13} {0.93}
+%% File: tagpdf-mc-luacode.dtx
+\ProvidesExplPackage {tagpdf-mc-code-lua} {2022-05-11} {0.94}
   {tagpdf - mc code only for the luamode }
 \hook_gput_code:nnn{begindocument}{tagpdf/mc}
   {
@@ -168,7 +168,7 @@
   }
 
 \cs_generate_variant:Nn \__tag_mc_handle_stash:n { x }
-\cs_new_protected:Nn \tag_mc_begin:n
+\cs_set_protected:Nn \tag_mc_begin:n
   {
     \__tag_check_if_active_mc:T
       {
@@ -199,7 +199,7 @@
         \group_end:
      }
   }
-\cs_new_protected:Nn \tag_mc_end:
+\cs_set_protected:Nn \tag_mc_end:
   {
     \__tag_check_if_active_mc:T
       {

Modified: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf.lua
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf.lua	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf.lua	2022-05-11 19:52:50 UTC (rev 63282)
@@ -24,8 +24,8 @@
 
 local ProvidesLuaModule = {
     name          = "tagpdf",
-    version       = "0.93",       --TAGVERSION
-    date          = "2022-01-13", --TAGDATE
+    version       = "0.94",       --TAGVERSION
+    date          = "2022-05-11", --TAGDATE
     description   = "tagpdf lua code",
     license       = "The LATEX Project Public License 1.3c"
 }

Modified: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty	2022-05-11 19:52:50 UTC (rev 63282)
@@ -27,7 +27,7 @@
 %% and all files in that bundle must be distributed together.
 %% 
 %% File: tagpdf.dtx
-\ProvidesExplPackage {tagpdf} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdf} {2022-05-11} {0.94}
   { A package to experiment with pdf tagging }
 
 \bool_if:nF
@@ -45,7 +45,7 @@
      {
        Activate~it~with \MessageBreak
        \string\RequirePackage{pdfmanagement-testphase}\MessageBreak
-       \string\DeclareDocumentMetadata{<options>}\MessageBreak
+       \string\DocumentMetadata{<options>}\MessageBreak
        before~\string\documentclass
      }
   }
@@ -56,6 +56,7 @@
 \ExecuteOptions{luamode}
 \ProcessOptions
 \RequirePackage{l3ref-tmp}
+\RequirePackage{tagpdf-base}
  \cs_new_protected:Npn \__tag_lastpagelabel:
    {
      \legacy_if:nT { @filesw }
@@ -120,7 +121,7 @@
 \cs_generate_variant:Nn \pdf_object_ref:n {e}
 \cs_generate_variant:Nn \pdfannot_dict_put:nnn {nnx}
 \cs_generate_variant:Nn \pdffile_embed_stream:nnn {nxx,oxx}
-\cs_generate_variant:Nn \prop_gput:Nnn {Nxx}
+\cs_generate_variant:Nn \prop_gput:Nnn {Nxx,Nen}
 \cs_generate_variant:Nn \prop_put:Nnn  {Nxx}
 \cs_generate_variant:Nn \ref_label:nn { nv }
 \cs_generate_variant:Nn \seq_set_split:Nnn{Nne}
@@ -181,6 +182,11 @@
     \bool_set_false:N \l__tag_active_mc_bool
   }
 \cs_set_eq:NN \tag_stop_group_end: \group_end:
+\cs_new_protected:Npn \tag_stop:
+  {
+    \bool_set_false:N \l__tag_active_struct_bool
+    \bool_set_false:N \l__tag_active_mc_bool
+  }
 
 \keys_define:nn { __tag / setup }
   {
@@ -263,7 +269,7 @@
   {The~number~of~automatic~begin~(#1)~and~end~(#2)~para~hooks~differ!}
   {This~quite~probably~a~coding~error~and~the~structure~will~be~wrong!}
 \cs_new:Npn \tag_get:n #1   { \use:c {__tag_get_data_#1: } }
-\prg_new_conditional:Npnn \tag_if_active: { p , T , TF, F }
+\prg_set_conditional:Npnn \tag_if_active: { p , T , TF, F }
   {
      \bool_lazy_all:nTF
        {
@@ -490,7 +496,7 @@
     { \prg_return_true: }
     { \prg_return_false: }
  }
-%% File: tagpdf-mc.dtx
+%% File: tagpdf-mc-shared.dtx
 
 \newcounter { g__tag_MCID_abs_int }
 \cs_new:Npn \__tag_get_mc_abs_cnt: { \int_use:N \c at g__tag_MCID_abs_int }
@@ -513,7 +519,7 @@
   {
     \tl_new:c { g__tag_mc_label_\tl_to_str:n{#1}_used_tl }
   }
-\cs_new_protected:Npn \tag_mc_use:n #1 %#1: label name
+\cs_set_protected:Npn \tag_mc_use:n #1 %#1: label name
   {
     \__tag_check_if_active_struct:T
       {
@@ -534,7 +540,7 @@
           }
        }
   }
-\cs_new_protected:Npn \tag_mc_artifact_group_begin:n #1
+\cs_set_protected:Npn \tag_mc_artifact_group_begin:n #1
  {
   \tag_mc_end_push:
   \tag_mc_begin:n {artifact=#1}
@@ -541,13 +547,13 @@
   \tag_stop_group_begin:
  }
 
-\cs_new_protected:Npn \tag_mc_artifact_group_end:
+\cs_set_protected:Npn \tag_mc_artifact_group_end:
  {
   \tag_stop_group_end:
   \tag_mc_end:
   \tag_mc_begin_pop:n{}
  }
-\cs_new_protected:Npn \tag_mc_end_push:
+\cs_set_protected:Npn \tag_mc_end_push:
   {
     \__tag_check_if_active_mc:T
       {
@@ -566,7 +572,7 @@
       }
   }
 
-\cs_new_protected:Npn \tag_mc_begin_pop:n #1
+\cs_set_protected:Npn \tag_mc_begin_pop:n #1
   {
     \__tag_check_if_active_mc:T
       {
@@ -786,7 +792,7 @@
     \seq_gremove_duplicates:N \g__tag_attr_class_used_seq
     \seq_set_map:NNn \l__tag_tmpa_seq \g__tag_attr_class_used_seq
       {
-        /##1\c_space_tl
+        ##1\c_space_tl
         <<
           \prop_item:Nn
             \g__tag_attr_entries_prop
@@ -1862,7 +1868,7 @@
           }
       },
   }
-\cs_new_protected:Npn \tag_struct_begin:n #1 %#1 key-val
+\cs_set_protected:Npn \tag_struct_begin:n #1 %#1 key-val
   {
 \__tag_check_if_active_struct:T
       {
@@ -1920,7 +1926,7 @@
         \group_end:
      }
   }
-\cs_new_protected:Nn \tag_struct_end:
+\cs_set_protected:Nn \tag_struct_end:
   { %take the current structure num from the stack:
     %the objects are written later, lua mode hasn't all needed info yet
     %\seq_show:N \g__tag_struct_stack_seq
@@ -1946,7 +1952,7 @@
           }
       }
   }
-\cs_new_protected:Nn \tag_struct_use:n %#1 is the label
+\cs_set_protected:Npn \tag_struct_use:n #1 %#1 is the label
   {
     \__tag_check_if_active_struct:T
       {
@@ -1990,8 +1996,8 @@
 \prop_new:N \g__tag_attr_objref_prop %will contain obj num of used attributes
 \cs_new_protected:Npn \__tag_attr_new_entry:nn #1 #2 %#1:name, #2: content
   {
-    \prop_gput:Nnn \g__tag_attr_entries_prop
-      {#1}{#2}
+    \prop_gput:Nen \g__tag_attr_entries_prop
+      {\pdf_name_from_unicode_e:n{#1}}{#2}
   }
 
 \keys_define:nn { __tag / setup }
@@ -2006,7 +2012,11 @@
     attribute-class .code:n =
      {
        \clist_set:No \l__tag_tmpa_clist { #1 }
-       \seq_set_from_clist:NN \l__tag_tmpa_seq \l__tag_tmpa_clist
+       \seq_set_from_clist:NN \l__tag_tmpb_seq \l__tag_tmpa_clist
+       \seq_set_map_x:NNn \l__tag_tmpa_seq \l__tag_tmpb_seq
+         {
+           \pdf_name_from_unicode_e:n {##1}
+         }
        \seq_map_inline:Nn \l__tag_tmpa_seq
          {
            \prop_if_in:NnF \g__tag_attr_entries_prop {##1}
@@ -2015,14 +2025,10 @@
              }
            \seq_gput_left:Nn\g__tag_attr_class_used_seq { ##1}
          }
-       \seq_set_map:NNn \l__tag_tmpb_seq \l__tag_tmpa_seq
-         {
-           /##1
-         }
        \tl_set:Nx \l__tag_tmpa_tl
          {
            \int_compare:nT { \seq_count:N \l__tag_tmpa_seq > 1 }{[}
-           \seq_use:Nn \l__tag_tmpb_seq  { \c_space_tl  }
+           \seq_use:Nn \l__tag_tmpa_seq  { \c_space_tl  }
            \int_compare:nT { \seq_count:N \l__tag_tmpa_seq > 1 }{]}
          }
        \int_compare:nT { \seq_count:N \l__tag_tmpa_seq > 0 }
@@ -2040,7 +2046,11 @@
     attribute .code:n  = % A property (attribute, value currently a dictionary)
       {
         \clist_set:No          \l__tag_tmpa_clist { #1 }
-        \seq_set_from_clist:NN \l__tag_tmpa_seq \l__tag_tmpa_clist
+        \seq_set_from_clist:NN \l__tag_tmpb_seq \l__tag_tmpa_clist
+       \seq_set_map_x:NNn \l__tag_tmpa_seq \l__tag_tmpb_seq
+         {
+           \pdf_name_from_unicode_e:n {##1}
+         }
         \tl_set:Nx \l__tag_attr_value_tl
           {
             \int_compare:nT { \seq_count:N \l__tag_tmpa_seq > 1 }{[}%]

Modified: trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdfdocu-patches.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdfdocu-patches.sty	2022-05-11 19:52:19 UTC (rev 63281)
+++ trunk/Master/texmf-dist/tex/latex/tagpdf/tagpdfdocu-patches.sty	2022-05-11 19:52:50 UTC (rev 63282)
@@ -1,5 +1,5 @@
 %\RequirePackage[enable-debug]{expl3}[2018/06/14]
-\ProvidesExplPackage {tagpdfdocu-patches} {2022-01-13} {0.93}
+\ProvidesExplPackage {tagpdfdocu-patches} {2022-05-11} {0.94}
  {patches/commands for the tagpdf documentation}
 \RequirePackage{etoolbox}
 
@@ -86,7 +86,11 @@
 % no internal patches, but KOMA-only solution
 %%%%%%%%
 
+% the structure should be opened rather early to catch the refstepcounter!
 \AddtoDoHook{heading/begingroup}{\tagpdfparaOff\use_none:n}
+\cs_new_protected:Npn \__tag_struct_section_begin:n #1 {\tagstructbegin{tag=\prop_item:Nn\g_tag_section_level_prop{#1}}}
+\AddtoDoHook{heading/postinit}{\__tag_struct_section_begin:n}
+\AddtoDoHook{heading/endgroup}{\tagstructend\use_none:n}
 
 \prop_new:N    \g_tag_section_level_prop
 \prop_gput:Nnn \g_tag_section_level_prop {section}{H1}
@@ -98,7 +102,6 @@
  {
   \@hangfrom
    {\hskip #2
-    \tagstructbegin{tag=\prop_item:Nn\g_tag_section_level_prop{#1}}
     %\tl_if_empty:nF{#3}
     \tl_if_in:nnF{\@empty}{#3}
     {
@@ -109,7 +112,7 @@
    }
    {\tag_mc_begin:n    {tag=\prop_item:Nn\g_tag_section_level_prop{#1}}
     #4
-    \tag_mc_end:\tagstructend}%
+    \tag_mc_end:}%
  }
 
 % minisec is simply P,  so we let paratagging handle this.



More information about the tex-live-commits mailing list.