summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty')
-rw-r--r--Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty41
1 files changed, 20 insertions, 21 deletions
diff --git a/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty b/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty
index 91dcf65368e..c336ce49631 100644
--- a/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty
+++ b/Master/texmf-dist/tex/latex/tagpdf/tagpdf.sty
@@ -27,7 +27,7 @@
%% and all files in that bundle must be distributed together.
%%
%% File: tagpdf.dtx
-\ProvidesExplPackage {tagpdf} {2022-05-11} {0.94}
+\ProvidesExplPackage {tagpdf} {2022-05-29} {0.95}
{ A package to experiment with pdf tagging }
\bool_if:nF
@@ -268,7 +268,6 @@
\msg_new:nnnn { tag } {para-hook-count-wrong}
{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_set_conditional:Npnn \tag_if_active: { p , T , TF, F }
{
\bool_lazy_all:nTF
@@ -842,6 +841,7 @@
\prop_map_tokens:Nn \g__tag_role_NS_prop{\use_ii:nn}
}
}
+\hook_new:n {tagpdf/finish/before}
\cs_new_protected:Npn \__tag_finish_structure:
{
\bool_if:NT\g__tag_active_tree_bool
@@ -1365,8 +1365,6 @@
}
}
%% File: tagpdf-struct.dtx
-\newcounter { g__tag_struct_abs_int }
-\int_gzero:N \c@g__tag_struct_abs_int
\__tag_seq_new:N \g__tag_struct_objR_seq
\__tag_prop_new:N \g__tag_struct_cont_mc_prop
@@ -1485,13 +1483,14 @@
}
\cs_generate_variant:Nn \__tag_struct_kid_struct_gput_right:nn {xx}
-\cs_new_protected:Npn\__tag_struct_kid_OBJR_gput_right:nn #1 #2 %#1 num of parent struct,
+\cs_new_protected:Npn\__tag_struct_kid_OBJR_gput_right:nnn #1 #2 #3 %#1 num of parent struct,
%#2 obj reference
+ %#3 page object reference
{
\pdf_object_unnamed_write:nn
{ dict }
{
- /Type/OBJR/Obj~#2
+ /Type/OBJR/Obj~#2/Pg~#3
}
\__tag_seq_gput_right:cx
{ g__tag_struct_kids_#1_seq }
@@ -1500,7 +1499,7 @@
}
}
-\cs_generate_variant:Nn\__tag_struct_kid_OBJR_gput_right:nn { xx }
+\cs_generate_variant:Nn\__tag_struct_kid_OBJR_gput_right:nnn { xxx }
\cs_new_protected:Npn\__tag_struct_exchange_kid_command:N #1 %#1 = seq var
{
@@ -1625,13 +1624,17 @@
}
%put the obj number of the annot in the kid entry, this also creates
%the OBJR object
- \__tag_struct_kid_OBJR_gput_right:xx
+ \ref_label:nn {__tag_objr_page_#2 }{ tagabspage }
+ \__tag_struct_kid_OBJR_gput_right:xxx
{
\l__tag_struct_stack_parent_tmpa_tl
}
{
#1 %
}
+ {
+ \pdf_pageobject_ref:n { \__tag_ref_value:nnn {__tag_objr_page_#2 }{ tagabspage }{1} }
+ }
% add the parent obj number to the parent tree:
\exp_args:Nnx
\__tag_parenttree_add_objr:nn
@@ -2089,6 +2092,15 @@
},
}
%% File: tagpdf-space.dtx
+\keys_define:nn { __tag / setup }
+ {
+ interwordspace .choices:nn = { true, on }
+ { \msg_warning:nnx {tag}{sys-no-interwordspace}{\c_sys_engine_str} },
+ interwordspace .choices:nn = { false, off }
+ { \msg_warning:nnx {tag}{sys-no-interwordspace}{\c_sys_engine_str} },
+ interwordspace .default:n = true,
+ show-spaces .bool_set:N = \l__tag_showspaces_bool
+ }
\sys_if_engine_pdftex:T
{
\sys_if_output_pdf:TF
@@ -2138,19 +2150,6 @@
show-spaces .default:n = true
}
}
-
-\sys_if_engine_xetex:T
- {
- \keys_define:nn { __tag / setup }
- {
- interwordspace .choices:nn = { true, on }
- { \msg_warning:nnn {tag}{sys-no-interwordspace}{xetex} },
- interwordspace .choices:nn = { false, off }
- { \msg_warning:nnn {tag}{sys-no-interwordspace}{xetex} },
- interwordspace .default:n = true,
- show-spaces .bool_set:N = \l__tag_showspaces_bool
- }
- }
\sys_if_engine_luatex:T
{
\cs_new_protected:Nn \__tag_fakespace: