- Subject: Re: [slang-users] Fwd: True Color (24 bit color) escape sequences support
- From: Egmont Koblinger <egmont@xxxxxxxxx>
- Date: Fri, 4 Sep 2015 22:16:35 +0200
Hi guys,
On one hand, this is awesome news, thanks a lot! :)
On the other hand... I really wouldn't say slang now has true color support.
It can indeed use any of the 16M colors, but it still has the
old-fashioned palette-like API where you can define at most 256 color
pairs and you have to stick to them. (Correct me if I'm wrong, I never
did any slang programming, just looking at the API docs now.)
Back in 1996 the computer I bought could only do 8-bit color depth at
1024x768, that is, it had 16M available colors, but could only show
256 (any 256) of them at a time. This is where slang arrived at in
2015. It was a year later that I replaced my video card to have
16-bit color depth and got rid of the palette approach for good.
Except for terminals where 20 years later it's still an issue.
True color support in Slang would mean that for each and every
character cell I could specify the fg and bg color (and all other
attributes like bold, italic, underlined) absolutely independently
from the rest of the screen, even being able to have different color
for all the cells of the screen if I wanted. Just as, beginning with
Unicode support, every cell can have any character out of the 2^21
ones independently from the rest of the cells.
This definitely needs a new set of APIs along with some internal refactoring.
Any use for this? Well, being able to implement a browser with exact
colors as defined on the web page (one the terminal web browsers,
can't remember which one, can actually do it), being able to syntax
highlight an #rrggbb code with its exact color in mcedit, being able
to implement a screen multiplexer, etc...
John (or anyone else), any chance you'd be interested in implementing
this for version 3?
And now for something completely different: Please see gnome-terminal
developer chpe's comment at
https://bugzilla.gnome.org/show_bug.cgi?id=754521 -- would you see any
benefit in making COLORTERM a whatever-separated list of terms for
future compatibility?
Thanks a lot,
egmont
On Wed, Sep 2, 2015 at 8:36 AM, John E. Davis <jed@xxxxxxxxxxx> wrote:
> Антон Кочков <anton.kochkov@xxxxxxxxx> wrote:
>> Since there was no answer to my previous message and to this day
>> support of the TrueColor is wide, I'm sending the new message to this
>> mailing list, asking to support those 24bit color escape sequences.
>
> The patch was integrated into pre2.3.1-35. The NEWS file contains:
>
> The SLtt interface has been modified to support 24 bit (true)
> colors. Until the next major release (version 3), this feature is
> available for 64 bit Unix/VMS systems to keep binary compatibility.
> Support for 32 bit systems will be added in version 3.
>
> Since not all terminals support true color, and it is not supported
> by terminfo, 24 bit color is disabled by default. A list of
> terminals that support true color may be found at
> <https://gist.github.com/XVilka/8346728>.
>
> To indicate that a terminal supports true color, set the value of
> the environment variable COLORTERM to either "24bit" or "truecolor",
> e.g.,
>
> export COLORTERM=truecolor
>
> Then to use 24 bit color in applications such as jed and slrn, use a
> 24bit RGB value in the form "#RRGGBB" as the name of the color.
> For example, to set the color of the status line in jed to AliceBlue
> (#F0F8FF) on a SlateGray (#708090) background, use
>
> set_color ("status", "#F0F8FF", "#708090");
>
> in the .jedrc file. In slrn, to set the color of the author name to
> the above colors use
>
> color author "#F0F8FF" "#708090"
>
> in the .slrnrc file. Also note other character attributes may be
> specified, e.g., "#F0F8FF;italics;underline".
>
> Thanks,
> --John
> _______________________________________________
> For list information, visit <http://jedsoft.org/slang/mailinglists.html>.
>
[2015 date index]
[2015 thread index]
[Thread Prev] [Thread Next]
[Date Prev] [Date Next]