Ivan Tomica

Fixing URxvt copy/paste

URxvt, or if you wish to call it rxvt-unicode, has this weird thing turned on by default where it binds ctrl+shift keys to all sorts of insanity (keycap picture insert mode and stuff like that).

Dammit, I want my “normal” terminal behavior back! By “normal” I think that if I press:

  • Ctrl + Shift + V -> paste contents of my main clipboard (from X)
  • Ctrl + Shift + C -> copy current selection to clipboard

So to restore that functionality here’s the magic thing you need in your .Xresources file in order to achieve it:

! Restore Ctrl+Shift+(c|v)
URxvt.keysym.Shift-Control-V: eval:paste_clipboard
URxvt.keysym.Shift-Control-C: eval:selection_to_clipboard
URxvt.iso14755: false
URxvt.iso14755_52: false

Once you have that just merge settings with:

xrdb -merge .Xresources

Sysadmin on the everlasting journey of learning.

1 Comment

  1. Nicu

    2020-09-22 - 14:22

    Thank You very much good Sir!

Leave a Reply

Your email address will not be published. Required fields are marked *