Vim: bold highlighting only after reload solarized color scheme

有些话、适合烂在心里 提交于 2020-01-05 07:33:43

问题


I have the following minimal .vimrc file under $HOME directory (I'm on Ubuntu 14.04 LTS, using vim-gnome):

syntax on
set background=dark
colorscheme solarized

And everything was highlighted as expected except for those supposed to be bold.

By default, solarized color scheme should bold errors and todos. However it doesn't work right away. For example, opening a file and invoking :he group-name, I get the following:

You can see error and todo are not bold. If I now reload solarized by :colo solarized, the highlighting will finally get correct:

So what goes wrong here? how can I get solarized to work properly?


回答1:


I have found an workaround:

Put colo solarized in /usr/share/vim/gvimrc solved the problem.

Initially, I thought some script loaded between solarized.vim and gvimrc might have conflicted with the bold setting of solarized.vim. But It seems not the case, because I've tried putting colo solarized in every script between them (based on output of :script), which has no effect.

Strangely, It only works fine to put colo solarized in /usr/share/vim/gvimrc.



来源:https://stackoverflow.com/questions/26913996/vim-bold-highlighting-only-after-reload-solarized-color-scheme

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!