Parchment/AsyncGlk already has alignment working!
This won’t happen unless someone manually adds some CSS that says .Style_header rather than span.Style_header. Which is what was recommended for original GlkOte, so it’s understandable that someone would do it, but it’s also easy to fix.
Maybe it would be better to change to separate classes for lines and spans? It wouldn’t be hard, and I doubt that would break anyone’s code.
That’s what I’ve done. The expanded AsyncGlk GlkOte protocol has a styles map with keys of div.Style_header or span.Style_user1, or blank to target the window itself.
That’s perhaps not the most ideal for non-HTML interpreters to receive, though an interpreter like Gargoyle wouldn’t be using the GlkOte protocol. For a console app or Discord bot that uses the protocol I guess it would have to parse the CSS target, which wouldn’t be too hard. If there was a better option I could change what AsyncGlk does.