diff options
Diffstat (limited to 'Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx | 36 |
1 files changed, 24 insertions, 12 deletions
diff --git a/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx b/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx index de239c2db79..80f9da0f6bd 100644 --- a/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx +++ b/Master/texmf-dist/source/latex/tagpdf/tagpdf-roles.dtx @@ -33,7 +33,7 @@ %</driver> % \fi % \title{^^A -% The \pkg{tagpdf-roles} module\\ Tags, roles and namesspace code ^^A +% The \pkg{tagpdf-roles} module\\ Tags, roles and namespace code ^^A % \\ Part of the tagpdf package % } % @@ -46,7 +46,7 @@ % }^^A % } % -% \date{Version 0.99b, released 2024-04-12} +% \date{Version 0.99c, released 2024-06-20} % \maketitle % \begin{documentation} % \begin{function} @@ -98,7 +98,7 @@ % \begin{macrocode} %<@@=tag> %<*header> -\ProvidesExplPackage {tagpdf-roles-code} {2024-04-12} {0.99b} +\ProvidesExplPackage {tagpdf-roles-code} {2024-06-20} {0.99c} {part of tagpdf - code related to roles and structure names} %</header> % \end{macrocode} @@ -190,7 +190,7 @@ % \end{variable} % % \begin{variable}{\g_@@_role_tags_class_prop} -% With pdf 2.0 we store the class in the NS dependant props. +% With pdf 2.0 we store the class in the NS dependent props. % With pdf <2.0 we store for now the type(s) of a tag in a common % prop. % Tags that are rolemapped should get the type from @@ -750,19 +750,31 @@ { \hook_gput_code:nnn {begindocument}{tagpdf} { - \cs_if_exist:NT \chapter - { - \prop_map_inline:cn{g_@@_role_NS_latex-book_prop} - { - \@@_role_add_tag:ne {#1}{\use_i:nn #2\c_empty_tl\c_empty_tl} - } - } + \bool_lazy_and:nnT + { + \cs_if_exist_p:N \chapter + } + { + \cs_if_exist_p:N \c@chapter + } + { + \prop_map_inline:cn{g_@@_role_NS_latex-book_prop} + { + \@@_role_add_tag:ne {#1}{\use_i:nn #2\c_empty_tl\c_empty_tl} + } + } } } { \hook_gput_code:nnn {begindocument}{tagpdf} { - \cs_if_exist:NT \chapter + \bool_lazy_and:nnT + { + \cs_if_exist_p:N \chapter + } + { + \cs_if_exist_p:N \c@chapter + } { \prop_map_inline:cn{g_@@_role_NS_latex-book_prop} { |