MacOS – VIM in Terminal using Solarized Theme

colormacosterminal

I am trying to use the Solarized color scheme with VIM in Terminal on Mac OS X 10.8.5 Mountain Lion. However, the colors look washed out. They are lighter/paler than they should be. In MacVIM, the colors show up perfectly, but I prefer using VIM via the Terminal.

Here's a screenshot of what the colors should look like followed by a screenshot of what the colors actually look like in Terminal.

MacVIM
Terminal VIM

I have already tried all the suggestions from here: Is it possible to disable Terminal's automatic tweaking of colors in Lion?

Has anyone found any other solutions to fix the colors in VIM in Terminal mode?

Best Answer

In Solarized Dark.terminal and Solarized Light.terminal, the 2*8 ANSI colors are specified in the sRGB color space, which seems to be identical with Device RGB at least on my iMac. The text, bold text, selection, cursor, and background colors are untagged, or shown as Generic RGB in the color picker. Terminal doesn't convert either of them to the color space used by your display.

You can specify the colors using your display's color space manually. For each color:

  • Click the color well, memorize the HSB or RGB values, and change the profile to the profile used by your display.

  • Insert the values you memorized, which should be the same as the values shown in the table in http://ethanschoonover.com/solarized.

In Solarized Dark.terminal:

  • The background color is base02 (black)
  • The text color is base0 (brblue)
  • The color for bold text is base1 (brcyan)
  • The cursor color is base01 (brgreen)
  • The selection color is base2 (white)

On my iMac the background and foreground colors in Solarized Dark.terminal were initially too bright, but the color space used by my iMac is fairly close to sRGB, so most of the ANSI colors were not that far off.