codeium.vim icon indicating copy to clipboard operation
codeium.vim copied to clipboard

Ghosting of suggestion when leaving insert mode

Open martin-braun opened this issue 2 years ago • 4 comments

I think an animation says more than 1000 words:

2023-04-01 8 08 25 PM

As you can see, when I cancel insert mode with CTRL+C while having a suggestion, there is only one way to get rid of the suggestion which I like to call ghost suggestion: I have to go back into insert mode at the point where the suggestion is.

As much as I like Codeium (my first impression gives me appeal and satisfaction), this is a bitter piece that ships with it. I often cancel insert mode somewhere, just delete my stuff and move along, but the suggestion will remain and occupy valuable space. It also causes a lot of confusion along the way.

Possible solution: Remove all suggestions when going back into normal mode. Suggestions should only be a thing in insert mode, they should not?

martin-braun avatar Apr 01 '23 18:04 martin-braun

I found a better solution to my problem. I can simply map <CMD>call codeium#Clear()<CR> to <C-c> in normal mode, so that I can remove the suggestion by pressing <C-c> again.

I don't know if it is meant to have the suggestion available on normal mode to be honest.

martin-braun avatar Apr 01 '23 18:04 martin-braun

It starts to annoy me, so I tried to remove the suggestion when leaving insert mode without pressing C-c twice. I tried to map C-c on insert mode, but then I lose the default behavior. I reopen this, because I think an option should be implemented to automatically remove suggestions in normal/visual mode.

martin-braun avatar Apr 24 '23 18:04 martin-braun

Which editor do you use? I have never seen such behavior in my vim setup.

klew avatar Apr 24 '23 20:04 klew

@klew Neovim (https://github.com/NvChad/NvChad/ + https://github.com/martin-braun/CocChad) on macOS.

So you say the suggestions should disappear automatically on normal mode?

martin-braun avatar Apr 25 '23 22:04 martin-braun