Ask HN: What happend to center mouse cut and paste in Linux?
Been captive on RHEL 6 for a long time. Installed a new linux distribution (fedora) and found that center button cut and paste does not work. Installed ubuntu, same thing. Google search seems to tell me "that is the way it is", and you can only cut and past like that inside a single application (which for me means an xterm). What has happened? Why would something like this that has been around for 30+ years across ever unix / window manager environment not be supported?
24 comments
[ 3.1 ms ] story [ 71.2 ms ] threadOn both fedora and Ubuntu.
Ah, on second thought: it might be because of Wayland. I've been using i3 so haven't been able to switch from x-land... So I wouldn't have encountered that problem
Check out Sway.
FWIW, CentOS 7 is ancient and long predates Wayland in Fedora.
One thing to remember is that the middle-click clipboard it's a separate clipboard from the Ctrl-C/Ctrl-V one. It's called the "primary selection", and as the name implies, it's updated if you select something new or even unselect the old selection. And nothing automatically synchronized with the Ctrl-C/Ctrl-V clipboard, so if you select something, copy it, and unselect it, middle-click won't work to paste any more but Ctrl-V (or Edit | Paste) still will.
If you want them synchronized you can use two autocutsel processes to do this (autocutsel synchronizes between either the "primary selection" or the "clipboard selection," and yet another type of X11 clipboard called the "cut buffer", so you need two to sync each selection with the cut buffer). https://blog.nelhage.com/2008/09/autocutsel/ describes how to do it. You might have had something like this in your RHEL 6 dotfiles that didn't get copied over to your new system.
Running one in your session allows to sync the toolkits' clipboards with X11's clipboard, which is what I choose to do - you only have one (history-enabled) clipboard that way, but it keeps the surprise effect ("Oh... I wasn't aware I was gonna paste _that_...") to a minimum, too :)
Sorry for the non-constructive comment, I guess it is nice to know that some appreciate it.
I set it back to default behavior on Ubuntu.
https://askubuntu.com/a/1028857
(Another Ubuntu annoyance - in "improving things" by switching from X11 to Wayland, they did away with the Gnome terminal tooltip which shows me how many characters I am resizing my Gnome terminal to. So it is now a rigmarole to set that up each time. Although they seem to turn that on and off at random, some random Ubuntu releases still seem to have it on by default).
(Also, I like the middle mouse cut and paste, too. I still use it in xterm)
Additionally you can also install the gnome shell extension Mousetweaks to enable gestures with a laptop trackpad.