Dictionary completions in Vim can use a ‘infer case’ mode, where, e.g.,
“Probab” will correctly autocomplete to, e.g., “Probability”, even though the
entry in the dictionary might be in a different case. The problem is that this
mode only works if `ignorecase` is on. And sometimes, we want one (`infercase`)
but not the other (`ignorecase`).
The following function, if added to your “`~/.vimrc`”, sets it up so that `ignorecase` is
forced on when dictionary completions are invoked via the `
and then restored to its original state when exiting.
A better approach than binding all the exit keys would be an autocommand on leaving the pop-up completion menu, but I could only find a trigger for entering the popupmenu.