File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -60,6 +60,8 @@ set laststatus=2 " Always show the statusline
6060set hidden " Maintain scroll position (don't close buffer)
6161runtime macros/matchit.vim " Needed for Ruby block selection support: https://github.com/ nelstrom/vim - textobj- rubyblock
6262
63+ set ofu = syntaxcomplete#Complete
64+
6365" Visual
6466set showmatch " Show matching brackets.
6567set mat = 5 " Bracket blinking.
@@ -118,3 +120,19 @@ map <C-j> <C-W>j
118120map <C-k> <C-W> k
119121map <C-h> <C-W> h
120122map <C-l> <C-W> l
123+
124+ function ! SuperCleverTab ()
125+ if strpart (getline (' .' ), 0 , col (' .' ) - 1 ) = ~ ' ^\s*$'
126+ return " \<Tab> "
127+ else
128+ if &omnifunc != ' '
129+ return " \<C-X>\<C-O> "
130+ elseif &dictionary != ' '
131+ return " \<C-K> "
132+ else
133+ return " \<C-N> "
134+ endif
135+ endif
136+ endfunction
137+
138+ inoremap <Tab> <C-R> =SuperCleverTab()<cr>
You can’t perform that action at this time.
0 commit comments