2
From fbterm(1) we can read:
FbTerm supports xterm's 256 color mode extension. (...) But xterm's 256 color escape sequences conflict with the linux sequences implemented by FbTerm, so private escape sequences were introduced to support this feature:
ESC [ 1 ; n } set foreground color to n (0 - 255) ESC [ 2 ; n } set background color to n (0 - 255) ESC [ 3 ; n ; r ; g ; b } set color n to (r, g, b) , n, r, g, b all in (0 - 255)
How can these escape sequences be written with the command echo -ne
?
Do you have a reference for the default colour palette? – Attie – 2018-10-06T22:52:59.257
No, but you could try something like
for i in {0..255}; do echo -ne "\E[2;$i} "; done; tput sgr0; echo
, this should print 255 coloured spaces and reset every text-colour-related setting to defaults in the end (tput sgr0
). – Kai – 2018-10-09T05:31:28.567Indeed - perhaps you could add this to your answer with a screenshot of the result? Numbers in the color would be even better :-) – Attie – 2018-10-09T09:21:46.947
1Done, I added both one-liners (-: – Kai – 2018-10-10T07:38:39.510
How do you end the color without
tput sgr0
? What is the escape sequence? – Gringo Suave – 2019-09-14T21:22:25.727