From 7f8f4b86882f1d519cb6e5273e19cf725e5a6c56 Mon Sep 17 00:00:00 2001 From: Vahagn Khachatryan Date: Thu, 10 Dec 2015 13:29:23 -0500 Subject: [PATCH] More plugins are added. --- vim/vimrc | 138 ++++++++++++++++++++++++++++++++++-------------------- 1 file changed, 86 insertions(+), 52 deletions(-) diff --git a/vim/vimrc b/vim/vimrc index b970154..361a4d0 100755 --- a/vim/vimrc +++ b/vim/vimrc @@ -38,7 +38,7 @@ set shiftwidth=4 " blanks according to softtabstop. set smarttab " Don't expand tabs. -set noexpandtab +set expandtab if has('autocmd') " Unset expandtab for make files in any case. autocmd FileType make setlocal noexpandtab @@ -113,6 +113,45 @@ set notimeout ttimeout ttimeoutlen=200 " Display " +" Configure coloring on command line terminals. +if &term=="xterm" + " enable 256 colors + set t_Co=256 + " set t_Co=8 + + set t_Sb=[4%dm + set t_Sf=[3%dm +endif +" +" Configure color theme, fonts and other graphics. +" +if has("gui_running") + " set color scheme + colorscheme darkblue + "set guioptions-=m + "set guioptions-=T + set lines=50 + set columns=85 + + " Set the font. + if has("win32") || has("win64") + "set guifont=FreeMono:h14:cANSI + "set guifont=Courier\ AM:h12 + else + "set guifont=Bitstream\ Vera\ Sans\ Mono\ 12 + set guifont=Monospace\ 12 + endif +else + colorscheme vahagn_black_terminal +endif + +" Switch syntax highlighting on, when the terminal has colors +" Also switch on highlighting the last used search pattern. +if &t_Co > 2 || has("gui_running") + syntax on + set hlsearch +endif + " wrap text at window edge without modifying buffer set nowrap " Scroll this much chars when scrolled horizontally. @@ -150,8 +189,10 @@ if exists('&number') set number endif " Turn on spell check. -if exists("+spell") +if exists("+spell") && &diff=="nodiff" set spell + highlight clear SpellBad + highlight SpellBad cterm=underline ctermfg=red endif " Show 80th column. if exists("+colorcolumn") @@ -167,13 +208,6 @@ set wildmode=longest:full " remember more history set history=1000 -" Switch syntax highlighting on, when the terminal has colors -" Also switch on highlighting the last used search pattern. -if &t_Co > 2 || has("gui_running") - syntax on - set hlsearch -endif - " Highlight searched string as typed. set incsearch @@ -186,42 +220,6 @@ highlight DiffText cterm=none ctermfg=Black ctermbg=Magenta gui=none guifg=Black set list set listchars=tab:>-,trail:ยท - - -" -" .gvimrc content here. -" -if has("gui_running") - " set color scheme - colorscheme darkblue - "set guioptions-=m - "set guioptions-=T - set lines=50 - set columns=85 - - " Set the font. - if has("win32") || has("win64") - "set guifont=FreeMono:h14:cANSI - "set guifont=Courier\ AM:h12 - else - "set guifont=Bitstream\ Vera\ Sans\ Mono\ 12 - set guifont=Monospace\ 12 - endif -else - colors vahagn_black_terminal -endif - -" enable 256 colors -set t_Co=256 -" Configure coloring on command line terminals. -if &term=="xterm" - " enable 256 colors - set t_Co=256 - " set t_Co=8 - - set t_Sb=[4%dm - set t_Sf=[3%dm -endif " In many terminal emulators the mouse works just fine, thus enable it. if has('mouse') " set mouse=n @@ -230,12 +228,21 @@ endif + """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" " vimdiff " -" ignore whitespaces -set diffopt+=iwhite +" Turn on spell check. +if &diff=="diff" + + "turn off spelling + set nospell + + " ignore whitespaces + set diffopt+=iwhite + +endif @@ -344,6 +351,38 @@ if filereadable(expand("~/.vim/bundle/Vundle.vim/README.md")) " Plugin 'xterm-color-table.vim' + " :A switches to the header file (or vise versa) + " :AS splits and switches + " :AV vertical splits and switches + " :AT new tab and switches + " :AN cycles through matches + " :IH switches to file under cursor + " :IHS splits and switches + " :IHV vertical splits and switches + " :IHT new tab and switches + " :IHN cycles through matches + " ih switches to file under cursor + " is switches to the alternate file of file under + " cursor (e.g. on switches to foo.cpp) + " ihn cycles through matches + Plugin 'vim-scripts/a.vim' + + " + " :set syntax=cpp.doxygen to highlight doxygen comments. + " + Plugin 'vim-scripts/DoxyGen-Syntax' + " + " In vim, place the cursor on the line and + " :DoxLic - generates license comment. + " :DoxAuthor - skeleton and leave the cursor just after @author tag. + " :Dox - generates function/class comment. + " :DoxUndoc(DEBUG) - if you want to ignore all code fragment ifdefed with + " DEBUG. + " :DoxBlock - + " + Plugin 'vim-scripts/DoxygenToolkit.vim' + + " call vundle#end() filetype plugin indent on @@ -358,9 +397,7 @@ if exists("dddd") "Plugin 'Valloric/YouCompleteMe' "Plugin 'rhysd/vim-clang-format' Plugin 'vim-scripts/Mark' -Plugin 'bling/vim-airline' Plugin 'danro/rename.vim' -Plugin 'gmarik/Vundle.vim' Plugin 'kana/vim-operator-user' Plugin 'kien/ctrlp.vim' Plugin 'majutsushi/tagbar' @@ -377,10 +414,7 @@ Plugin 'tpope/vim-fugitive' Plugin 'tpope/vim-unimpaired' Plugin 'vim-scripts/Align' Plugin 'vim-scripts/Buffergator' -Plugin 'vim-scripts/a.vim' Plugin 'vim-scripts/taglist.vim' -Plugin 'vim-scripts/DoxyGen-Syntax' -Plugin 'vim-scripts/DoxygenToolkit.vim' Plugin 'msanders/snipmate.vim' Plugin 'vim-scripts/xml.vim' Plugin 'junegunn/vim-easy-align'