16
10
I am trying to use the desert color scheme with VIM 7.0 on CentOS 5.6 x64 located here:
I've downloaded the file and saved it in my ~/.vim/colors
directory. I then tell VIM to use the colour scheme by issuing:
:colors desert
It's supposed to look like this:
However I get this:
I'm logging onto this server just as a regular user (not root
or sudo
) using PuTTY 0.60 and have set the following options under Window -> Colours
:
Allow terminal to specify ANSI colours - checked Allow terminal to use 256-colour mode - checked Bolded test is a different colour - checked Attempt to use logical palettes - unchecked Use system colours - unchecked
If I sudo
or logon as root
and try the same I don't get any colours at all other than white text on a black background.
Are these schemes mostly aimed at gVIM and is PuTTY just not able to display these colours?
I've google'd around a bit and bumped into articles such as this one but they don't appear to work.
Excellent answer. It's better, but I have feeling 256 colours isn't enough to render these pastel shades. Any idea why I don't get any colours at all when logged in as
root
? – Kev – 2011-09-14T14:44:51.5271@Kev: 1) 256-color mode is the best you can get on a VT100-compatible terminal emulator. (I heard KDE Konsole having true-color support, but it's very much nonstandard.) 2) When you log in as root, you get a separate home directory, and a separate
~/.vim/colors
as well. – user1686 – 2011-09-14T14:47:24.360I have the color scheme in
~/.vim/colors
but it seems to be ignored. I know vim can see it because if I do:colors
for a scheme that isn't there it reportsE185: Cannot find color scheme blahblahblah
whereas no error when I do:colors desert
. – Kev – 2011-09-14T14:50:35.027@Kev: Hm. Do you have syntax highlighting enabled? (
:syn on
) How about $TERM - is it set to a sane value? – user1686 – 2011-09-14T14:52:33.387Hmm...colours and syntax highlighting work with
vim
launched asroot
but notvi
. I can live with that I guess. – Kev – 2011-09-14T15:18:08.2201@Kev: Because
vi
does not have color schemes or syntax highlighting - or anything except the original basic features. (Vim is "Vi Improved" after all.) – user1686 – 2011-09-14T16:09:32.9771
vi --version
says it's vim, so is it a cut back vim to make it look like vi? Sorry if that's a daft question, it's been years since I worked with unix in anger (SCO Unix boxes with serial ports) and there was only vi (real vi). – Kev – 2011-09-14T16:19:39.9501Sort of. When you run vim as "
vi
", it starts in a "compatibility" mode, behaving as much as possible like vi. I don't know CentOS, so I'm not sure if it is just a mode, or an entirely separate trimmed-down build. (My distro packages the real vi instead...) – user1686 – 2011-09-14T16:58:01.087