1
0
Fork 0

ansi-colours: Format 256 colour columns better

This commit is contained in:
tastytea 2022-03-19 07:32:37 +01:00
parent bc1d575dc4
commit 5ce626bb46
Signed by: tastytea
SSH Key Fingerprint: SHA256:FBkvrOlhq5use1XEttyUGT4bUTDVA1ar9SgIc9P03cM
1 changed files with 7 additions and 2 deletions

View File

@ -20,10 +20,15 @@ done
print "\n\e[1;97m256 colour pallette:\e[0m"
local -a colours
for n in {0..255}; do
for n in {0..15}; do
colours+="\e[38;5;${n}m\\\e[38;5;${n}m\e[0m"
done
print -c ${colours}
print -C 2 ${colours}
colours=()
for n in {16..255}; do
colours+="\e[38;5;${n}m\\\e[38;5;${n}m\e[0m"
done
print -C 6 -a ${colours}
print "\n\e[1;97m256 colour background:\e[0m 48 instead of 38"
print "\e[1;97mTrue colour:\e[0m \\\e[38;2;\e[0;31mR\e[0m;\e[0;32mG\e[0m;\e[0;34mB\e[0mm" \