I'm trying to get more colors in the terminal emulator. Mostly to get prettier syntax highlighting. I've googled quite extensively for a terminal emulator that supports 24bit colordepth and that doesn't seem to exist. And even if it did gnu screen, that I use extensively, only supports 256 colors.

An alternative approach would be to manipulate the color palette of the terminal. gnome-terminal allows this, but only for the colors in the first 16 positions of the palette. This will allow me to change palette entry 3 from the glaring #00CD00 to the more soothing #4E9A06, which makes for a nicer experience on the commandline. For syntax highlighting, however, 16 colors is a bit limited. Now I'm looking for a terminal emulator that will let me tailor the entire 256 entries of the palette.

Is there such a beast to be found?

| improve this question | | | | |

Since February 17 there is a fork of rxvt-unicode that does exactly what I was looking for. Via X resources it lets you customize all 256 colors. Each color can be set to any one of 2^24 RGB triplets.

On a freshly installed Ubuntu 11.04 the installation is done like this:

sudo apt-get install libperl-dev libx11-dev libxft-dev git g++
git clone https://github.com/trapd00r/rxvt-unicode.git
cd rxvt-unicode
sh configure --enable-256-color --enable-font-styles \ 
             --enable-perl--enable-mousewheel --enable-lastlog --enable-xft
make install
| improve this answer | | | | |

try xterm. 256 color xterm is supported, for example, by that vim plugin. it should also work with rxvt and mrxvt.

| improve this answer | | | | |
  • I know that I can get 256 colors in vim provided I use a terminal that supports it. But I can't pick the 256 colors I get to use. The palette is fixed. That's the thing I want to change. – oivvio Nov 18 '09 at 20:11

The eLinks Manual has this to say regarding its true-color mode:

Note that only terminal capable to show it is konsole from kdebase-3.5.4.

Not being a Konsole user, a cursory web search for the feature makes me uncertain whether anybody else knows about it or whether any other software can currently make use of it.

| improve this answer | | | | |

Although I haven't found it explicitly stated anywhere, as far as I can tell only 16 colors are user-definable, and the other are simply variations of the original 16. Kept in mind should be that the terminal is only intended to support 16 colors, no less, no more. That it's possible to display more than that is basically just cleverness and good programming.

So as an answer to your question: No, you can't define the full palette of 256 colors.

| improve this answer | | | | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.