![]() |
Font Effects in 8-Bit and 24-Bit Colour Representations
I want to use 8-Bit and 24-Bit colours in terminal, and have seen some different versions.
Code:
code="\e[38;5;${if}m" Have also noticed that the Font Effect only affects the foreground and can be included separately (e.g. \e[5m). Is this correct ? Code:
code="\e[5m\e[38;5;${ir};${ig};${ib}m" |
Example:
Code:
green="\033[0;32m" |
Bold: "\033[01m"
Underline: "\033[04m" styled text: [style-code][text]\033[0m It is unimportant if [text] is already colored. That is all I know. If – together with Teck's example – it is not sufficient, then I have not understood the OP and am ready to learn something. Also, ... which style should possibly affect something else than the foreground? |
Code:
#!/usr/bin/bash |
All times are GMT -5. The time now is 07:02 PM. |