" Ultimate VIMRC without plugin " Copyrights @ Yavobo " Version 0.10 " Created in 2016.11.02 11:11 " Updated in 2020.03.10 16:19 " " Describe: " This is an version of no plugin. " That's my favours! " " 1.base {{{ syntax on filetype indent plugin on set nocompatible set nobackup set noswapfile set history=2048 set autochdir set whichwrap=b,s,<,>,[,] set nobomb set vb t_vb= au GuiEnter * set t_vb= set backspace=indent,eol,start whichwrap+=<,>,[,] set ff=unix set cindent shiftwidth=4 " Vim 的默认寄存器和系统剪贴板共享 set clipboard+=unnamed " 设置 alt 键不映射到菜单栏 set winaltkeys=no " }}} " 2.Lang & Encoding {{{ let $LANG = 'en_US.UTF-8' language messages zh_CN.UTF-8 set encoding=utf-8 set termencoding=cp936 set fileencoding=utf-8 set fileencodings=ucs-bom,utf-8,cp936,gb18030,big5,euc-jp,euc-kr,latin1 set langmenu=zh_CN.utf-8 set imcmdline " 防止菜单出现乱码 source $VIMRUNTIME/delmenu.vim source $VIMRUNTIME/menu.vim " }}} " 3.Theme {{{ " Set Number line and Cursor line " Set Status line set laststatus=2 set statusline=[%{&ff}:%{&fenc}]%F%m%r%h\ %w\ \ %=%l,%c\ %L set cmdheight=1 " Set font if has("win32") set guifont=YaHei_Consolas_Hybrid:h16 endif " Normal setup " 不显示工具/菜单栏 set guioptions-=T set guioptions-=m set guioptions-=L set guioptions-=r set guioptions-=b " 最大化启动 if has("gui_running") && has("win32") map <F11> :call libcallnr("gvimfullscreen.dll","ToggleFullScreen", 0)<CR> au GUIEnter * simalt ~x endif " 按F11切换全屏 imap <F11> :call libcallnr("gvimfullscreen.dll","ToggleFullScreen", 0)<CR> " }}} " 4.Behavior {{{ set autoindent set mouse=a set backspace=2 set wrap set smartindent set tabstop=4 set softtabstop=4 set expandtab "set ai! map <F5> :tabnext<cr> map <F6> :tabnew<cr> set number set cursorline " For windows 7 " Display will not be normal in terminal when set t_Co to 256, it must be set to 8 " ------------------------------------------------------------------------ "set t_Co=8 colorscheme ron highlight Normal ctermbg=Black "highlight LineNr term=NONE cterm=NONE ctermbg=DarkCyan ctermfg=Yellow highlight LineNr term=NONE cterm=NONE ctermfg=Green highlight CursorLine term=NONE cterm=NONE ctermbg=DarkBlue highlight CursorLineNr term=NONE cterm=NONE ctermbg=DarkGreen ctermfg=Red " For windows 10 " Display will be same as gui in terminal to set t_Co to 256 " ---------------------------------------------------------- "set t_Co=256 "colorscheme torte "highlight Normal ctermbg=235 "highlight LineNr term=NONE cterm=NONE ctermbg=234 ctermfg=yellow "highlight CursorLine term=NONE cterm=NONE ctermbg=238 "highlight CursorLineNr term=NONE cterm=NONE ctermbg=236 ctermfg=red if has("gui_running") colorscheme desert highlight CursorLine guibg=#555555 highlight LineNr guibg=#222222 highlight CursorLineNr guifg=yellow endif " 设置标签 highlight TabLine guibg=#121212 guifg=red term=underline cterm=bold ctermfg=red ctermbg=gray highlight TabLineSel guibg=#121212 guifg=yellow term=bold cterm=bold ctermbg=Red ctermfg=yellow " 5.others 其它设置 if has("win32") " vimrc文件修改之后自动加载, windows autocmd! bufwritepost _vimrc source % else " vimrc文件修改之后自动加载, linux autocmd! bufwritepost .vimrc source % endif " 6.Extend " 快捷输入 " 自动完成括号和引号 " inoremap ' ''<ESC>i " inoremap " ""<ESC>i " inoremap ( ()<ESC>i " inoremap [ []<ESC>i " inoremap { {<CR>}<ESC>O " }}}
标签:插件,set,vimrc,NONE,cterm,ctermbg,term,highlight From: https://www.cnblogs.com/merrynuts/p/16739472.html