aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Christian Pohle2017-06-07 17:07:25 +0200
committerMax Christian Pohle2017-06-07 17:07:25 +0200
commitb35546eff796d4cbdb5a857725e2e4e81a510db1 (patch)
tree95733faa98be28ff348a159068a55fc84c6654f3
parent5ced76f09ddd3ebc3abe5203d95e36f8f41050d4 (diff)
downloadvim-karlmarks-b35546eff796d4cbdb5a857725e2e4e81a510db1.tar.bz2
vim-karlmarks-b35546eff796d4cbdb5a857725e2e4e81a510db1.zip
Some code folding and current word highlighting
-rw-r--r--vimrc-full16
1 files changed, 15 insertions, 1 deletions
diff --git a/vimrc-full b/vimrc-full
index 5146456..ebe3134 100644
--- a/vimrc-full
+++ b/vimrc-full
@@ -68,7 +68,7 @@ set winminwidth=30 | " (and all other windows, so TODO: watch out)
68set tags+=../tags 68set tags+=../tags
69" set textwidth=100 | " line length (80 used to be default, but...) 69" set textwidth=100 | " line length (80 used to be default, but...)
70" set colorcolumn= | " not used, because we have a :match directive for textwidth 70" set colorcolumn= | " not used, because we have a :match directive for textwidth
71set updatetime=1000 | " updates the screen more often 71set updatetime=100 | " updates the screen more often
72set viminfo+=% | " restore buffer list 72set viminfo+=% | " restore buffer list
73set writedelay=0 73set writedelay=0
74set wildmenu | " use a menu in the command line 74set wildmenu | " use a menu in the command line
@@ -441,6 +441,9 @@ if !has('nvim') | " settings which have been removed from neovim
441 set ttyscroll=100 | " improves speed for terminal vim, incomp. with nvim 441 set ttyscroll=100 | " improves speed for terminal vim, incomp. with nvim
442 set ttyfast | " improves speed for terminal vim (incomp. with nvim) 442 set ttyfast | " improves speed for terminal vim (incomp. with nvim)
443 " set termguicolors | " When on, uses highlight-guifg and highlight-guibg attributes in the terminal (=24bit color) incomp. with nvim 443 " set termguicolors | " When on, uses highlight-guifg and highlight-guibg attributes in the terminal (=24bit color) incomp. with nvim
444 "
445 let g:loaded_ruby_provider = 1 " disable ruby support
446 let g:loaded_python_provider = 1 " disable pthon3
444endif 447endif
445 448
446if has("autocmd") 449if has("autocmd")
@@ -654,6 +657,17 @@ let g:netrw_liststyle = 3 | " 3=tree
654let g:netrw_preview = 0 | " 657let g:netrw_preview = 0 | "
655let g:netrw_winsize = 20 | " window size in percent 658let g:netrw_winsize = 20 | " window size in percent
656 659
660
661function! HighlightWordUnderCursor()
662 if getline(".")[col(".")-1] !~# '[[:punct:][:blank:]]'
663 exec 'match' 'Bold' '/\V\<'.expand('<cword>').'\>/'
664 else
665 match none
666 endif
667endfunction
668
669autocmd! CursorHold,CursorHoldI * call HighlightWordUnderCursor()
670
657" au BufNewFile,BufRead,BufEnter *.cpp,*.hpp set omnifunc=omni#cpp#complete#Main 671" au BufNewFile,BufRead,BufEnter *.cpp,*.hpp set omnifunc=omni#cpp#complete#Main
658" Enable omni completion. 672" Enable omni completion.
659" autocmd FileType css setlocal omnifunc=csscomplete#CompleteCSS 673" autocmd FileType css setlocal omnifunc=csscomplete#CompleteCSS
..