2
0
mirror of https://github.com/webgefrickel/dotfiles synced 2024-11-19 03:25:33 +00:00
steffen-dotfiles/vim/config/plugins/neocomplete.vim

29 lines
1.1 KiB
VimL
Raw Normal View History

" Neocomplete
"======================================================================
let g:acp_enableAtStartup = 0
let g:neocomplete#enable_at_startup = 1
let g:neocomplete#auto_completion_start_length = 3
let g:neocomplete#force_overwrite_completefunc = 1
2016-03-07 14:24:49 +00:00
inoremap <expr><C-g> neocomplete#undo_completion()
inoremap <expr><C-l> neocomplete#complete_common_string()
inoremap <silent> <CR> <C-r>=<SID>neocomplete_cr_function()<CR>
2016-05-02 08:15:21 +00:00
inoremap <expr><C-y> neocomplete#close_popup()
inoremap <expr><C-e> neocomplete#cancel_popup()
2016-03-07 14:24:49 +00:00
" <TAB>: completion.
2016-05-02 08:15:21 +00:00
inoremap <expr><TAB> pumvisible() ? "\<C-n>" : "\<TAB>"
2016-03-07 14:24:49 +00:00
" " <C-h>, <BS>: close popup and delete backword char.
inoremap <expr><C-h> neocomplete#smart_close_popup()."\<C-h>"
inoremap <expr><BS> neocomplete#smart_close_popup()."\<C-h>"
function! s:neocomplete_cr_function()
return neocomplete#close_popup() . "\<CR>"
endfunction
if !exists('g:neocomplete#sources#omni#input_patterns')
let g:neocomplete#sources#omni#input_patterns = {}
let g:neocomplete#sources#omni#input_patterns.php = '[^. \t]->\h\w*\|\h\w*::'
endif