The questioner is using xubuntu
, apt-get install gvim
, which will be used in three situations vim
:
* xfce4-terminal
* gvim
* <ctrl><alt><f[num]>
The following is my attempt, but it only distinguishes these three 'situations', and the actual operation is not ideal,
I really don’t understand its color matching.
if &term == "xterm"
set t_Co=256
colorscheme lucius
set background=dark
elseif &term == "builtin_gui"
set guioptions=
colorscheme lucius
set background=dark
hi cursor guibg=#DB35EB
elseif &term == "linux"
endif
A piece of information found Optimized Vimrc with 256 Colorscheme
It will be more accurate to judge whether it is a GUI like this:
In addition, the terminal type of xfce-terminal can be adjusted, and the default may be<f[num]>)的terminal类型是
xterm
、xterm-color
或者xterm-256color
,你需要自己看看,Linux console(就是你所说的linux
.