junegunn / vim-peekaboo

:eyes: " / @ / CTRL-R
1.13k stars 39 forks source link

Plugin blocks Mappings that include double quote character (") #8

Closed reckoner closed 9 years ago

reckoner commented 9 years ago

Hi,

I love your plugin, but my mappings such as

nmap <M-o> "+gP
imap <M-o> <ESC>"+gP

No longer work because your plug-in changes the double quote character. Is there a way around this?

Thanks!

junegunn commented 9 years ago

I don't understand why they don't work. They should still work though you may find pointless flashing of the peekaboo window annoying. It's possible that the other key bindings in your config are getting in the way.

Having said that, it is strongly recommended and considered to be a good practice that you always use noremaps instead of maps unless you explicitly want recursive expansion of the keys.

nnoremap <M-o> "+gP
inoremap <M-o> <ESC>"+gP

With noremaps, " is not expanded, so peekaboo will not be invoked.