💾 Archived View for bbs.geminispace.org › s › Gemini › 22449 captured on 2024-12-17 at 15:08:41. Gemini links have been rewritten to link to archived content
-=-=-=-=-=-=-
Can't find in Gemini specification something about terminal emulation feature,
that is client-side improvisation?
https://en.wikipedia.org/wiki/ANSI_escape_code
Dec 04 · 13 days ago · 👍 dragfyre
The use of SGR codes in Gemini text is a nonstandard feature, and is not implemented by all clients. (ANSI escape codes other than SGR codes probably would not be meaningful and probably should not be used.)
So if nobody use other ANSI features in preformatted text, I will integrate SGR colors only
Thanks!
A consequence of early terminal clients dumping content... Please try to support at least foreground, and preferably background especially in preformatted mode so that games work
🕹️ skyjake [mod...] · Dec 05 at 04:32:
ANSI escape codes other than SGR codes probably would not be meaningful and probably should not be used.
I've found that correctly rendering many ASCII art images requires a few cursor control sequences, too, like moving right by N columns.
If one's goal is rendering ASCII art in plaintext documents and Gemtext preformatted blocks, implementing support for ANSI escape sequences is needed.
The Gemtext specification says nothing about the use of ANSI escape sequences, though. This leaves the client free to present them however they choose to, which basically is either stripping them out or applying the corresponding formatting.
Generally speaking, I would recommend that these are only applied inside preformatted blocks, since they are formatting instructions, and the client provides settings to disable them.