terminalpp
terminalpp copied to clipboard
Don't change character set if unnecessary
If a character would be written in a different character, but it's actually the same character (e.g. 'X' is both US_ASCII and UK), then don't bother changing the character sets.
This would involve having a database of characters and what entries in character sets correspond to what characters.
An easy half-way solution would be to avoid character set switches for character 0x00-0x7F, which are the same in all character sets.
Note: DEC graphical characters has a smaller overlapping character set.
This may be required for anything complicated using Windows Terminal, see https://github.com/microsoft/terminal/issues/16529