by akkartik · 4y ago · 0 comments
"We don’t switch from blue to some other specified color, because we don’t know the background color of the terminal. Some people, possibly aliens, don’t favor a dark terminal background. If the terminal background were white, and we had just used e.g. ncdirect_fg(n, 0xffffff), text following “house” would be invisible.
"One might observe that a user with a blue background will have invisible “house” text. This is a real issue, one lacking a perfect solution. It is not generally possible to discover the RGB values of the default colors. I suppose all one can do is rest easy, serene in the belief that white backgrounds are one thing, but people with chromatic backgrounds deserve whatever happens to them."
That's a lot of cognitive dissonance in a work about UI design. Let's try to do better in making TUIs mainstream. That requires encouraging people to use the few features terminals _do_ provide. Like chromatic backgrounds.
I've been doing a fair amount of ncurses hacking recently[1], and I prefer to always explicitly specify colors. People won't get their preferred colors by default, but they'll always get a legible configuration by default.
These days we have dark modes and more elaborate extensions. Still sometimes things don't align.
So thanks for at least specifying both.