I have trouble with the right Vim configuration. I'm using the latest version of Vim as well as the latest version of iTerm2.

I try to get the solarized colorscheme working, but without luck so far.

Here you can see an image with (top left, top right, bottom left, bottom right) iTerm2, Terminal.app, MacVim and my iTerm2 settings.

terminals + settings

I also imported the solarized color scheme in iTerm2.

Here the link to my .vimrc

  • JIC, are you sure, "solarized" is 256-color scheme? – Maximus Feb 1 '13 at 20:55
  • it's not necessarily just solarized which is not working. I get 3 different results for every scheme :( – Stefan Schmidt Feb 1 '13 at 21:23
  • I have this exact problem; font colors do change between colorschemes, but not the background… – cemerick Apr 3 '13 at 17:53

You have set t_Co=256, try these lines in addition.

set term=xterm
set t_Co=256
let &t_AB="\e[48;5;%dm"
let &t_AF="\e[38;5;%dm"

I added CSApprox, and everything just worked.

  • Some mode details? As it stands, the answer isn't exactly informative... – vonbrand Apr 3 '13 at 20:13
  • More details? I'm afraid I'm new to both vim and iterm, so I don't have much in the way of explanation. However, I do know that installing that plugin allowed me to set the color scheme to whatever I wanted and get the same results in iTerm as I do in MacVim. – cemerick Apr 4 '13 at 0:22

What background colour of solarized you want to use? (light or dark)

If you want dark background, put set bg=dark in your .vimrc

If you want light background, put set bg=light in your .vimrc

I saw that in comment of your .vimrc line #74

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.