If you have a look at ftplugin/sql.vim it does this. I override the ctrl-left|right keys. When pumvisible() is false I want to do the default Vim behaviour. When it is true I want to perform special SQL actions.
I was only able to do this via a mapping which called a function. But that does keept it neat and tidy. HTH, Dave ----- Original Message ----- From: "Karl Guertin" [EMAIL PROTECTED] Sent: 09/26/2006 11:50 AM To: "VIM Help" <[email protected]> Subject: Detecting when in omnicomplete I'm playing around with keybindings and omnicompletion and I'd like a special set of keybindings when pumvisible() and it's an omnicomplete match. I can mostly do this by setting a buffer variable in all my mappings that would cause me to enter/exit omnicomplete, but I keep missing edge cases. Is there a better way to detect which completion mode vim is in?
