termstandard / colors

Color standards for terminal emulators
The Unlicense
1.09k stars 42 forks source link

Anybody know of a patch for urxvt to support 24-bit color? #54

Open clort81 opened 1 year ago

clort81 commented 1 year ago

urxvt does not support 24 bit colors properly because it can't display more than a limited subset of colors at one time.

Is there any patch we could get into urxvt that would allow true (non paletted) 24 bit support?

It might be a big job (?). Certainly each colored string would need to remember the full 3 bytes of rgb color info, as opposed to one byte.

If each character in a 100 column, 10k line scrollback buffer got two bytes of color info added, that'd be another 2MB memory use.

If memory consumption is an issue. Color data could be a sparse array.

As a text artist, I find Urxvt completely fails with such images which display correctly in xterm, and other true 24bit terminals:

baroque-fantasy-city

baroque-fantasy-city.ans.gz

ghost commented 1 year ago

have a look at this patch

kurahaupo commented 1 year ago

That patch is good but incomplete; it only implements the secondary compact format, and does not implement the original standard, namely CSI 38:5::Red:Green:Blue:Alpha m (where :Alpha is optional, and yes that's two colons before the Red component).