I found that I can not paste text to GVIM from firefox or other editor, anyone can tell me how to set my GVIM(GNOME) on Ubuntu11 ?
|
I used "Shift-Insert" earlier today with text copied from firefox and pasted into a terminal (vi) for a co-worker stuck with the same issue on 11.. Not sure what needs to be changed in gvim to sync up the clipboards. |
|||
|
|
|
The way I usually do this is to ensure that vim is in insert mode, select the text in Firefox (or whatever) and then middle click in vim - this is called the X11 selection, and is very handy. You can also use the
And if you have done Ctrl+C (or right click and "Copy") then you could do:
(Note that as usual, lower case Note that "* and "+ work both ways. So if you have selected text in visual mode in vim, you can copy it to the X11 selection using |
|||
|
|
|
@Hamish's answer is nice and works fine for VIM. Another way, perhaps more general, is to use Run this (or, more realistically, bind it to some key):
It will take your clipboard (where things end up after pressing ctrl-C, generally) and move it to your primary X selection (what you paste when you press the middle mouse button). So you can then press the middle mouse button to paste into VIM, GVIM or any other application. |
|||
|
|