I just downloaded and stated using the YCM plugin for vim. However I noticed that whenever the auto-complete pops up giving completion suggestions a split window also opens up in my current window. Any suggestions on how I can configure YCM to not open up a split window ? or at least shut the window when I select something.
Vim : youCompleteme plugin opens up a split window with function definition
Asked Answered
In your .vimrc file add this line :
let g:ycm_autoclose_preview_window_after_insertion = 1
According to the documentation :
When this option is set to 1, YCM will auto-close the preview window after the user leaves insert mode. This option is irrelevant if g:ycm_autoclose_preview_window_after_completion is set or if no preview window is triggered. See the g:ycm_add_preview_to_completeopt option for more details.
For more infos : https://github.com/Valloric/YouCompleteMe#the-gycm_autoclose_preview_window_after_completion-option
Put this in your .vimrc
:
set completeopt-=preview
I think it fixes that according to https://github.com/ycm-core/YouCompleteMe/issues/2015
© 2022 - 2024 — McMap. All rights reserved.
:sp
orsp
orsplit
or:vs
or:vsplit
in your plugin files. If you find it in any file , put those lines here. – Bellarmine