Usually insert mode completion (<C-n>
) inserts the right word the first time I press <C-n>
, but not always. Therefore, I would like Vim to insert the match it deems best when I press <C-n>
, but still allow me to cancel this insertion afterwards should the correct match not show up or be a long way down the list.
Of course I could code this behavior, but I have a feeling there should be a standard key(-combination) to do this. Could someone point me in the right direction?
Bonus question: is there another key I can use to get the longest match (as it was before I hit <C-n>
)?
For what it's worth, I'm using completeopt=menu
ctrl-u
what you are looking for?