How can I change vim status line color?

gcali picture gcali · Jan 30, 2012 · Viewed 39.6k times · Source

I'm tring to change vim's status line color by editing my .vimrc .

By using the command au, I tried to change the color of the status line when entering or leaving insert mode; by using this command nothing happens:

hi StatusLine guibg=whatevercolourIwant

By changing the status line color directly, without any au command, the background remains the same.

Is there reason why by executing

:hi StatusLine guibg=red,

for instance, the background of the status bar still remains greenish?

Answer

Kent picture Kent · Jan 30, 2012

if you are running vim in terminal, try:

hi StatusLine ctermbg=whatever ctermfg=whatever

guibg guifg are for GUI.

hope it helps.