[spec] Clarify purpose of alt-text
luke at marmaladefoo.com
Sun Feb 28 15:20:32 GMT 2021
On 28-Feb-2021 15:06, Adnan Maolood wrote:
> Section 5.4.3 of the Gemini specification currently states:
>> Any text following the leading "```" of a preformat toggle line which toggles
>> preformatted mode on MAY be interpreted by the client as "alt text" pertaining
>> to the preformatted text lines which follow the toggle line. Use of alt text
>> is at the client's discretion, and simple clients may ignore it. Alt text is
>> recommended for ASCII art or similar non-textual content which, for example,
>> cannot be meaningfully understood when rendered through a screen reader or
>> usefully indexed by a search engine. Alt text may also be used for computer
>> source code to identify the programming language which advanced clients may
>> use for syntax highlighting.
> I propose that the final sentence be removed, and that MAY be replaced
> with MUST:
I disagree - at present the spec lends equal weight to the two possible
interpretations of the label of the preformatted text areas
- they may be interpreted as an alternative label for screen reader
(an accessibility label since ascii art is meaningless to non-visual users)
- they may be used for text type identification (to convey the type of
content shown, for syntax highlighting or possibly more useful semantic
purposes, for example a client may choose not to render ascii art at all)
The spec does not restrict to a single application or interpretation of
the label for these preformatted areas. Both elements are important.
It is a reduction in scope to turn the may to a must as you suggest.
From an accessibility point of view, you could say that indicating the
content type is actually more important to screen readers as they can
definitively use that to choose whether to show the content or not.
The problem is these are orthogonal uses and the spec has them entangled
together. So the solution is to disentangle. I think the proposal to use
the opening and closing labels for each purpose (on the other email
thread) is the best solution so far.
More information about the Gemini