latex3 / tagpdf

Tagging support code for LaTeX
59 stars 7 forks source link

Adjust orders of structure elements #64

Closed lvjr closed 1 year ago

lvjr commented 1 year ago

In PDF, mark contents and structure elements are independent. But it seems tagpdf has not yet provided a way for adjusting positions of structure elements.

This issue is from https://github.com/lvjr/tabularray/issues/88. In building a long table, tabularray typesets TBody before THead, therefore the orders of these two structure elements need to be exchanged in PDF.

Also in PDF and HTML, Caption must be the first element of Table, but in LaTeX users can put captions at the end of table environments. Therefore it is important to provide some interface for adjusting positions of structure elements.

u-fischer commented 1 year ago

See the keys stash, label, parent key and the \tagstructuse command. Together they allow you switch the order of structure elements in various ways. (For the mc there are similar options.)

lvjr commented 1 year ago

Thank you. And maybe the documentation needs more examples.

car222222 commented 1 year ago

All documentation always needs more examples, and more explanations, and more . . . :-)