Closed sharkdp closed 5 years ago
We distinguish 3 modes:
\x1b[38;5;167m
\x1b[38;2;255;0;127m
Note that we ignore the 16-color ANSI mode, as we can't really predict how the 16 colors look like.
We choose the mode in the following way:
--mode=24bit
--mode=8bit
PASTEL_MODE=8bit
PASTEL_MODE==24bit
COLORTERM==truecolor
COLORTERM==24bit
Further literature: https://gist.github.com/XVilka/8346728
This can now be easily done with ansi::Brush
ansi::Brush
We distinguish 3 modes:
\x1b[38;5;167m
)\x1b[38;2;255;0;127m
)Note that we ignore the 16-color ANSI mode, as we can't really predict how the 16 colors look like.
We choose the mode in the following way:
--mode=24bit
or--mode=8bit
=> use the given mode.PASTEL_MODE=8bit
, use 8 bit modePASTEL_MODE==24bit
orCOLORTERM==truecolor
orCOLORTERM==24bit
=> use 24 bit modeFurther literature: https://gist.github.com/XVilka/8346728