Open gergap opened 9 years ago
I am running into this exact same problem. When using AutoClose in vim insert mode, I create a JavaScript function and add my first "{" and AutoClose adds the second one "}" to match it. I then hit my enter key to give my function a new line, then I click on my up arrow to return to where I want to type my text, once I click that up arrow, I get all that pumvisible() text inserted into my file.
Is there a way to ignore the mapping of
Thanks.
I had the same issue with some strange text inserted hitting the arrow keys. Also after installation of YouCompleteMe. For me replacing all the imap with inoremap statements in /plugin/AutoClose.vim line 29-36 seems to fix the issue.
Kind regards.
The official tips from YCM is to just use Raimondi/delimitMate
Alternatively let g:AutoClosePumvisible = {"ENTER": "", "ESC": ""}
ref
llikePepsi I had the same issue but it only started after I installed nerdtree and opened a second file from the tree, opening it in a new tab. Every time I pressed the up or down key in insert mode it would insert weird text like " Pumvisible() ... It looked like it was from one of the plugins .vim files. And thanks a lot for sharing your fix, spent half the day trying to fix it, couldn't find it anywhere on the internet.
@gergap @Mule52 @IlikePepsi @fatso83 @MuhammetFevziBayiroglu I have forked the project and made a number of modifications that will improve compatibility with autocompletion plugins like YouCompleteMe. Maybe my modifications can help improve your experience with AutoClose. You can find the project at: https://github.com/whitehatzero/vim-autoclose
Hi
1st conflict: Returning to normal mode when YCM popup is shown and ESC is pressed. This can be fixed by adding let g:AutoClosePumvisible = {"ENTER": "", "ESC": ""}
to .vimrc as described here: https://github.com/Valloric/YouCompleteMe/issues/9
2nd conflict: When in insert mode and pressing Cursor Up/Down it inserts some text like "pumvisible() ? ...". I could fix this here by uncommenting the "inoremaps" in line 471 and 473:
I don't know what this was for and what sideeffects it has to remove these mappings. Anyway, it works for me now. Maybe you can fix this upstream, so that your plugin works together with YouCompleteMe.
regards, Gerhard.