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

improving alt-text usage #55

Open
pkra opened this issue Dec 9, 2019 · 6 comments
Open

improving alt-text usage #55

pkra opened this issue Dec 9, 2019 · 6 comments

Comments

@pkra
Copy link
Member

pkra commented Dec 9, 2019

Currently, only mbk103 has instances of the alt-text element. There, it appears only inside fig elements.

In ams-xml-to-html, we currently have

https://github.com/AmerMathSoc/ams-xml-to-html/blob/138f6c862fbe804ddafb9942be1cd245247ea4d0/ams-xml-to-html.xsl#L755-L757

This is very specific to this use case. For example, a figure with multiple graphics would have a single alt-text.

If we encounter new publications with alt-text (in particular, if content is required to include graphics alt-text), we should reconsider this. E.g., jats and bits allow alt-text as a child of graphic and inline-graphic.

In the JS implementation of ams-xml-to-html, it is somewhat inconvenient to implement the lookup the same way as in XSL; for simplicity, we will only look for alt-text if the parent is a fig element which will suffice for mbk103. We can update the implementation once we encounter new content.

@pkra
Copy link
Member Author

pkra commented Oct 26, 2020

@pkra
Copy link
Member Author

pkra commented Jul 30, 2022

Random note on authoring: make4ht supports \includegraphics[alt=hello]{hello.png} syntax.

@pkra
Copy link
Member Author

pkra commented Feb 4, 2024

Beyond the official LaTeX syntax, it would be good to provide an option for \begin{SVG}.

@pkra
Copy link
Member Author

pkra commented Feb 22, 2024

On another related note, it would be good to store the title in generated SVGs in the XML to make it simpler to find.

@pkra
Copy link
Member Author

pkra commented Feb 22, 2024

We should also prototype means of linking to long textual alternatives.

On the XML end, would could just have an xlink:href on the graphic though perhaps on a child works out better (e.g., long-desc ).

I don't know if TeX \label is too TeX-y - #36 comes to mind. I suspect if the href just links to a (empty) target element, we'll have trouble working out what to really use for the textual alternative.

@pkra
Copy link
Member Author

pkra commented Mar 20, 2024

For completeness, here's an experiment of mine for providing short labels inside math mode https://github.com/krautzource/mathjax-aria-label/ . The underlying constructs will remain explorable but on the higher level, SRE will pick up on the author's textual alternative.

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

2 participants