appstream icon indicating copy to clipboard operation
appstream copied to clipboard

Screenshots: add support for specifying alt-text

Open sgued opened this issue 11 months ago • 8 comments

Alt text is useful to describe the screenshot for screen readers and for when the image hasn't loaded. I currently have not found any way to specify alt-text in the appstream metadata, and flathub uses alt="" for the screenshots.

sgued avatar Jan 09 '25 17:01 sgued

caption should have a different content and not describe the content of a screenshot word for word

razzeee avatar Mar 29 '25 21:03 razzeee

Should alt text be translatable if we added it? It isn't in HTML...

ximion avatar Mar 29 '25 23:03 ximion

Should alt text be translatable if we added it? It isn't in HTML...

Yes. We need to show the correct translated alt text for your current language, at least for the flathub website.

razzeee avatar Mar 30 '25 00:03 razzeee

But the screenshot isn't translated... And we already have translatable screenshots. So, any alt text could simply be in the language of the screenshot image, couldn't it?

ximion avatar Mar 30 '25 00:03 ximion

But the screenshot isn't translated... And we already have translatable screenshots. So, any alt text could simply be in the language of the screenshot image, couldn't it?

That sounds correct.

For flathub, we're not using that (yet)

razzeee avatar Mar 30 '25 11:03 razzeee

Screenshots should be translatable (AFAIK that is not yet possible?), and that should allow changing the source URL for the image, and IMHO it would make sense to have the alt-text always match the language of the screenshots? If that doesn't work for some app the app can just have the multiple languages link to the same URL.

sgued avatar Mar 30 '25 12:03 sgued

Quicstart also recommends english screenshots, which would be weird, if we actually supported other languages https://www.freedesktop.org/software/appstream/docs/chap-Quickstart.html#qsr-app-screenshots-info

I would have expected a wording more like At least screenshots with english as the display language should be provided

razzeee avatar Mar 30 '25 13:03 razzeee

The quickstart guide is not comprehensive, it is intentionally brief to make people read less to get a decent file done. It has also not been updated in ages, especially not since screenshot translations have been added. Translations are possible, at the image level: https://www.freedesktop.org/software/appstream/docs/chap-Metadata.html#tag-screenshots

ximion avatar Mar 30 '25 23:03 ximion