From 7f953885f8c56e9dc4cb8a3701f89f200ff8dfb4 Mon Sep 17 00:00:00 2001 From: Guangxiong Lin Date: Wed, 6 Sep 2023 23:28:10 +0800 Subject: Avoid scanning tags when completing --- .vim/after/plugin/mucomplete.vim | 2 +- .vimrc | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.vim/after/plugin/mucomplete.vim b/.vim/after/plugin/mucomplete.vim index e126e31..2f5b30a 100644 --- a/.vim/after/plugin/mucomplete.vim +++ b/.vim/after/plugin/mucomplete.vim @@ -8,7 +8,7 @@ let s:default_cond = { t -> strlen(&omnifunc) > 0 && t =~# '\%(\.\)$' } let g:mucomplete#can_complete.default = { 'omni': s:default_cond } let g:mucomplete#chains = {} let g:mucomplete#chains.default = - \ [ 'ulti', 'user', 'omni', 'keyn', 'path' ] + \ [ 'ulti', 'user', 'omni', 'c-p', 'path' ] let s:c_cond = { t -> strlen(&omnifunc) > 0 && t =~# '\%(\.\|->\)$' } let g:mucomplete#can_complete.c = { 'omni': s:c_cond } diff --git a/.vimrc b/.vimrc index ed60ad7..ef35e03 100644 --- a/.vimrc +++ b/.vimrc @@ -59,6 +59,7 @@ if !has('nvim') set completeopt+=popup set completepopup=align:menu,border:off,highlight:WildMenu endif +set complete=.,w,b,u,i " Don't use tags as there may be lots of tags set shortmess+=c set belloff+=ctrlg @@ -141,7 +142,7 @@ nnoremap cd :cd %:p:h :pwd nnoremap cnoremap -highlight Pmenu ctermbg=grey +" highlight Pmenu ctermbg=grey packadd! onedark.vim silent colorscheme onedark -- cgit v1.2.3