Closed wezm closed 6 years ago
I put a $20 bounty on this.
Now toolbar button paste CLIPBOARD and middle button paste PRIMARY mode. Also fix paste in command mode.
Shift-Insert not implemented as it can be binded with for example nnoremap
.
Paste toolbar button is working for me but middle click only makes the mode cycle:
Tried middle button on mouse and laptop and both behave the same.
Can't reproduce,
does it work if just paste '' register? in insert mode this is `Ctrl+r maybe you have some custom mapping on
Ctrl+r` ?
do some improvements, maybe this helps
I don't believe I have any mappings on Ctrl-r
. You can see my vim config and nvim config in my dotfiles repo. I just tried the latest build on a different laptop (with the same config) and it worked!
I'll release the claim as soon as I can log into Bountysource. I'm getting an Internal server error when I try to log in at the moment.
Still can't log onto BountySource. I've pinged them on Twitter.
I also can't log onto BountySource Thanks :+1:
I think I worked out how to trigger the behaviour in the animated GIF above. If you middle click in the space after the buffer it triggers this behaviour.
I.e. if the cursor is not on the last line and I middle click in the lower part of the window with the ~
lines it cycles through the different modes shown in the GIF.
still can't reproduce it, but found that neovim itself can process middle button 😄 , so just pass event directly to it. For me it do the same - paste from primary clipboard. maybe this helps. If there is still problems, can you check this behavior without plugins loaded.
What about Shift+Insert? Maybe you can let nvim process it too?
When i enter EDIT mode and press Shift-Insert, it works as expected in plain nvim, but not nvim-gtk. Also using Shift+Insert in command mode does not work, but works in plain nvim.
Looks like gnome termnal can process Shift+Insert and pass it to nvim https://github.com/GNOME/vte/blob/be6cd8246c7993326677c9e2058deedac4263667/src/vte.cc#L5277
For gui - Shift+Insert already passed to nvim. Maybe next maps can help:
map <S-Insert> "*gP
cmap <S-Insert> <C-R>+
imap <S-Insert> <C-R>+
i don't test them, but think this must work.
None of that bindings works.
When i press Shift+Insert in command mode, nothing happens. But when i press Shift+Del, text
@last-partizan yes, your right, Insert button does not passed, fixed this.
Also primary clipboard is *
, so update mapping a bit
map <S-Insert> "*gP
cmap <S-Insert> <C-R>*
imap <S-Insert> <C-R>*
Now it works! Thanks!
Did you ever get scroll/middle-click to paste?
Anyhow the remap mentioned above works for Shift-Insert! Maybe mention this in the README?
It would be nice to be able to paste the PRIMARY clipboard by pressing the middle mouse button or Shift-Insert.