You are not logged in.

#1 2015-05-01 10:38:31

Ploppz
Member
Registered: 2013-09-14
Posts: 295

How do you go about configuring colours for terminal [applications]?

I figured this might be the best place to ask but I'm not sure.

I'm using termite, and it has 256 colours predefined. I have always thought that I better define my own colours (override defaults), because the defaults didn't immediately look nice. However, I recently discovered that for example the vim plugin "vim-airlineish" uses colour 55, which matches the screenshots of the plugin - so default colour scheme is assumed. So I'm wondering if this default colour scheme is some kind of global, well known default? And does it perhaps have properties, like: you will most likely find a colour close to the one you want in there, or something else? Is there a name for it?
http://a.pomf.se/dmahvz.png

So what I'm really wondering, is: what is the preferred way to configure the colours of console applications?

Should I leave the default theme as it is and search for the colours I want in this colour scheme?

Or should I find my own set of colours, and choose amongst these when configuring specific applications? This is what I've been doing so far, and for example, I wanted a greenish theme on my desktop, but the default colour scheme doesn't seem to hold a wide spectrum of green colours. (following picture is from my current colours, which I recently set and which I am not really that satisfied with)
http://a.pomf.se/rpeisv.png

Or should I override colours as I need specific colours? An ideal way - but pretty unorderly - to design for instance a colour scheme for coding, would maybe be to use gcolor2/3 to choose any colour that you need, and then put it in the colour scheme. If you could do that easily but you can't really - you have to go through a moderate amount of steps to change one colour, and in the long run of revising, revising, it's just a hassle.

Thanks in advance for any input you can provide on this!

-- mod edit: converted img to url tags.  Trilby --

Last edited by Trilby (2015-05-01 11:41:41)

Offline

#2 2015-05-01 11:39:35

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 25,243

Re: How do you go about configuring colours for terminal [applications]?

You have a few different only paritially overlapping questions here.  How to find a color / is there a name for it:  There are 16 base colors, then a 216 color cube, then 24 grayscale colors.  You can get a bit more about this from a google search - here's one example:
https://fedoraproject.org/wiki/Features … _Terminals

There are also countless scripts to print out the 256 colors in a useful way in a terminal.  These scripts are littered all around these forums - just search and you'll find them.

It is common practice to override the first 16 colors.  There are also countless posts - and I think an entire thread - on these forums devoted to sharing these color schemes.  I believe it is also possible to override any of the other 240 colors, but it is generally not done and I'd advise against it.  These other 240 are generally the ones "assumed".  The first 16 have conventional meaning, but there are no specific shades that should be assumed: 1 is some shade of red or something the user prefers in place of red, 2 is some shade of green, etc.  8-15 are bright versions of 0-7.

Also, as you search - please find the forum guidelines and only link to larger images.  I converted the images to urls in your post.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#3 2015-05-01 14:11:08

Ploppz
Member
Registered: 2013-09-14
Posts: 295

Re: How do you go about configuring colours for terminal [applications]?

Thanks! Your post helped me a lot.

As for scripts to print out 256 colors, I can't really find any by googling.. maybe I'm a terrible googler.

Edit: I found one that outputs this, but I'm more interested in how the colours look on text on black background (so I'll keep looking). (source: http://www.robmeerman.co.uk/unix/256colours)

Last edited by Ploppz (2015-05-01 14:25:13)

Offline

#4 2015-05-01 14:19:37

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 25,243

Re: How do you go about configuring colours for terminal [applications]?

Here's mine

#!/bin/bash
echo; for i in {000..007}; do echo -en "\e[0m \e[38;5;"$i"m"$i"\e[7;38;5;"$i"m"$i ; done; echo
for i in {008..015}; do echo -en "\e[0m \e[38;5;"$i"m"$i"\e[7;38;5;"$i"m"$i ; done; echo; echo
let count=0
for i in {016..231}; do
	echo -en "\e[0m \e[38;5;"$i"m"$i"\e[7;38;5;"$i"m"$i
	let count=$count+1
	if [[ $count -gt 5 ]]; then let count=0; echo; fi
done
echo; for i in {232..239}; do echo -en "\e[0m \e[38;5;"$i"m"$i"\e[7;38;5;"$i"m"$i ; done; echo
for i in {240..247}; do echo -en "\e[0m \e[38;5;"$i"m"$i"\e[7;38;5;"$i"m"$i ; done; echo
for i in {248..255}; do echo -en "\e[0m \e[38;5;"$i"m"$i"\e[7;38;5;"$i"m"$i ; done; echo -e "\033[0m"; echo

"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#5 2015-05-01 14:22:14

Ploppz
Member
Registered: 2013-09-14
Posts: 295

Re: How do you go about configuring colours for terminal [applications]?

Trilby wrote:

Here's mine

Thanks! That's very useful.

Offline

#6 2015-05-01 15:04:59

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 25,243

Re: How do you go about configuring colours for terminal [applications]?

For the 16 color themes see here.  My search results were a bit limited at first too ... cause someone used the British spelling of "colour" for that thread.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

Board footer

Powered by FluxBB