18 ms·
Highlight to copy, middle-click to paste. Works every time for me. Obviously, if you want to paste into vim you have to be in insert mode.
by audeyisaacs 11y ago
Highlight to copy, middle-click to paste. Works every time for me.
Obviously, if you want to paste into vim you have to be in insert mode.
- icebraining 11y agoPretty much, never had a problem with it.
- sandGorgon 11y agomy laptop does not have middle button. so I have to do a weird left-right button click. Very inconvenient for me. I truly envy the OSX people just on this one aspect.
- vodik 11y agoshift-insert works in X if you can't middle click. In gvim too, out-of-the-box if you're in insert mode.
- sandGorgon 11y agoI was HOPING for that. Its part of IBM CUA. Unfortunately it doesn't work everywhere.. Especially the terminal (unless you remap keybindings)
- e12e 11y agoTechnically vim exposes the x11 clipboards (plural) as registers - I never use registers, but I think "+p [Ed: for those not familiar with vim: " can be thought of as 'with/from/into register named:', + is the register and p is paste. Similarily "+yw is 'yank/copy current word into register named +' ] should be paste x11 selection. I don't normally use gvim/vim as an x11 application, but looks like * (star) is typically system clipboard: http://vim.wikia.com/wiki/Accessing_the_system_clipboard http://vim.wikia.com/wiki/Accessing_the_system_clipboard
- sandGorgon 11y agowhy does it work on osx then ? is there something special happening at the OS level there ?
- ris 11y agoYes, except when you have to select something in between the time you copy & paste, e.g. change focus to the URL bar of a browser. Then ctrl-C is your friend, and works everywhere except the terminal. But the terminal is a special case when it comes to copy/paste and always will be a little weird on any platform. Especially when it comes to line-wrapping in full-terminal applications like vi.