Firefox – Vimperator copy/pasting

firefoxvimvimperator

I'm trying out Vimperator. I mainly wanted it for the hjkl scrolling, and I like its "hint" system for following links. These two features are really all I need; I think.

I don't mind the other features, it just sometimes get in my way.

The thing that annoys me the most is copy/pasting. I'm used to Ctrl + c/Ctrl+v, I don't mind using another shortcut, but ..

:help yank indicates that copying selected text is done with Y, but the only method mentioned for pasting is the middle mouse button!

This is so ridiculously against the spirit of Vim!

How can I paste in Vimperator without using the mouse?

Best Answer

The best and easiest thing that you can do is to remap the keys. It's not hard. Put this into your _vimperatorrc (or .vimperatorrc in Linux)

noremap <C-c> <C-v><C-c>
noremap <C-v> <C-v><C-v>

<C-v> is by default mapped to "Pass next" mode, which means that next key you press is sent directly to Firefox, without being processed and eaten by vimperator. So the mappings above just activate the "Pass next" mode and send the respective shortcut.

There is even a vimperator plugin which extends this even further and remaps all common windows shortcuts, so they behave as expected.