Alt text and media types for preformatted text

Oliver Simmons oliversimmo at gmail.com
Mon Mar 1 09:44:26 GMT 2021


On Mon, 1 Mar 2021 at 03:47, Alex // nytpu <alex at nytpu.com> wrote:
>
> So the sighted people with fancy syntax highlighting get to trivially
> read it line-by-line, but the people writing accessible software have to
> 1) seek forward to find the end of the preformatted text block; 2) read
> the alt text; then, if the user wants to display the preformatted block
> 3) jump backwards to the beginning of the preformatted text block and
> read it; then 4) skip past the last line of the preformatted text block
> so it isn't read again; then 5) continue parsing.

I assumed that the content type would be used to decide whether it
would be read.
Anyways, my point was that using the closing ``` is not going to work,
as Gemtext is meant to be read line-by-line.
Whether it's the alt text or content type, having either of them last is flawed.

> I think syntax highlighting deserves an easier implementation than
> accessibility too, so I'm fine with this situation, I'm glad someone
> else finally agrees with me on this.
>
> I mean seriously, I like syntax highlighting as much as anyone but
> advanced syntax highlighting has to be context-sensitive and possibly
> requires looking back in the code block anyways, so might as well put it
> at the end, if you have it at all.  But let's just look at the concept
> at all for a second: if you really have such a massive block of code
> that you need syntax highlighting, just put it in its own file and let
> either the browser color it via MIME type or the user can just open it
> in their editor.  If your short snippet of code can't be understood
> without syntax highlighting then it's probably a problem with your code
> rather than the presentation...

Agreed.

- Oliver Simmons


More information about the Gemini mailing list