You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
16M colors aren't referencing a palette, the RGB value is output directly
Terminal sequence for TrueColor is different than the one for 256 and lower color mode (palette)
So, to add TC support (and do other improvements along the way), the course of action is:
Convert TermColors and Crysterm functions to work with hex (Int32) numbers as the native format (so instead of the current string "#0000ff" you would specify 0x0000ff)
But still keep support in Crysterm for hex strings and color names (just parse into Int32)
Add support for TrueColor term escape sequence, not just 256 palette
Keep results of color blending/mixing and terminal sequence values in a cache so they're not always being recalculated
Convert TermColors to be suitable for use as a class/struct
With TermColors converted to class/struct, accept the colorspace size in the initializer (def initialize(colors))
Combine Crysterm/TermColors/Tput so that there is better detection for supported colors, depending on terminal [emulator] in use
The text was updated successfully, but these errors were encountered:
Add TrueColor support to Crysterm.
Crysterm uses a related shard TermColors to output color. TermColors is used to blend/mix colors, find nearest color in the palette (round down), etc.
TermColors (and consequently Crysterm) currently use the following approach:
light-
orbright-
On the other hand, TrueColor uses 16M terminal colors. Information about checking for TC support or escape sequences that need to be printed can be found on:
https://github.com/termstandard/colors
https://mudhalla.net/tintin/info/truecolor/
https://unix.stackexchange.com/questions/404414/print-true-color-24-bit-test-pattern#404415
https://medium.com/@dubistkomisch/how-to-actually-get-italics-and-true-colour-to-work-in-iterm-tmux-vim-9ebe55ebc2be
The most important info is that:
So, to add TC support (and do other improvements along the way), the course of action is:
def initialize(colors)
)The text was updated successfully, but these errors were encountered: