Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FR] Provide tags and attributes for endnotes #728

Open
gusbrs opened this issue Oct 10, 2024 · 3 comments
Open

[FR] Provide tags and attributes for endnotes #728

gusbrs opened this issue Oct 10, 2024 · 3 comments

Comments

@gusbrs
Copy link
Contributor

gusbrs commented Oct 10, 2024

I'd like to suggest the inclusion to tagpdf of tags and attribute NoteType for endnotes.

In adding tagging support for postnotes I'm currently setting the following:

    \tagpdfsetup
      {
        add-new-tag = { tag=endnote, role=FENote } ,
        add-new-tag = { tag=endnotemark, role=Lbl } ,
        newattribute = { EndnoteType } { /O /FENote /NoteType /Endnote }
      }

https://github.com/gusbrs/postnotes/blob/356053d957843489d112b56cd917c86e581dabd1/postnotes.dtx#L2773-L2778

Even if the kernel + base + tools does not have endnotes facilities (but you do have endnotes.sty in your hands currently, don't you?), I'd say it makes sense for these settings to be available in tagpdf since these are actually things which come from PDF standards (modulo if I got those settings correctly...).

Also, there's also the question if a package should be making such settings at all (I'm currently doing it because otherwise there's no way to get things to work). I don't actually own that namespace. As far as my testing goes, repeating these settings does not result in harm, so they seem to work as "provide". (Though in the TeX.SX chat Ulrike was in doubt on what the expected behavior was supposed to be). I have no idea what happens if different people use different values there, though, and who would take precedence.

@u-fischer
Copy link
Member

Well at first: the keys got new names (but the older still works):

\tagpdfsetup
      {
        role/new-tag = {tag=endnote, role=FENote} ,
        role/new-tag = {tag=endnotemark, role=Lbl} ,
        role/new-attribute = {EndnoteType} { /O /FENote /NoteType /Endnote}
      }

I also now checked too (it is so difficult to remember what one did ...) and confirm that using that more than once doesn't error and the last setting wins (which makes me wonder, if I should rename the keys to role/set-tag).

I quite agree that these things should be in the kernel, but we need to decide first about a naming scheme and that is not trivial.

It wouldn't be good if we now add endnote and tell you to use that and then decide that we want to use ltx-endnote, or perhaps ltx-FENote for both footnotes and endnotes and use only the attribute to differentiate them and then you have to adapt your package again and again.

So for now I think it is ok if you define that yourself. Mark it as temporary and we review that next year. And probably it would be good to start a public list somewhere of used tag names, their role mapping, and attributes.

@gusbrs
Copy link
Contributor Author

gusbrs commented Oct 10, 2024

Well at first: the keys got new names (but the older still works):

I'll update that. Thanks.

I quite agree that these things should be in the kernel, but we need to decide first about a naming scheme and that is not trivial.

It wouldn't be good if we now add endnote and tell you to use that and then decide that we want to use ltx-endnote, or perhaps ltx-FENote for both footnotes and endnotes and use only the attribute to differentiate them and then you have to adapt your package again and again.

I have no qualms with the cautious / long-term approach. I concur.

However, about the names, a question from an inexperient. I understand that structurally the roles are the critical, but isn't using "traditional"/"expected" names also a bonus in the world of "not quite compliant readers"? In other words, won't readers also look for the actual tag and using something unusual mean "less compatibility coverage"?

So for now I think it is ok if you define that yourself. Mark it as temporary and we review that next year.

Will do.

@gusbrs
Copy link
Contributor Author

gusbrs commented Oct 15, 2024

A side note. I was checking footnotes for reference now and, if you agree setting NoteType for endnotes like this is a good idea, probably the equivalent should be done for footnotes (as far as I can tell, it currently is not set).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants