1

I prefer using vim directly inside my terminal emulator (gnome-terminal or konsole) rather than using gvim, because it integrates better in my workflow.

Unfortunately, it also seems to make nice color schemes unavailable.

Is there an easy way to make color schemes such as wombat work in a terminal emulator?

1

3 Answers 3

4

Colorschemes can be written specifically for gvim, or specifically for an 88/256 color terminal. If your terminal does not support 88 or 256 colors -- or your colorscheme doesn't support terminals at all, many colorschemes are not going to work.

If you are willing to give it a try the CSApprox.vim script will attempt to make gui colorschemes available in your terminal by changing the colorscheme to use colors that are available in your terminal.

Another option is to use the CSExact.vim script which instead changes your terminal's color palette to match the colors defined in the colorscheme. This has the advantage of being more precise with the few drawbacks mentioned in the docs.

3

Some colorschemes might only work in a 256-color terminal. What is the value of your TERM environment variable? Try setting it to e.g. xterm-256color.

2

first lines of my .vimrc:

if $COLORTERM == 'gnome-terminal'
    set term=gnome-256color
    colorscheme wombat
    "colorscheme railscasts
    "colorscheme ir_black
else
    colorscheme default
endif

(GNOME Terminal 2.30.2, VIM 7.2.330)

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .