I use many tools for drawing diagrams (system design, UI sketches) such as Figma, Canva and Miro. The standard behavior for these tools is to navigate through the document by holding the middle mouse button. But in KDE, it pastes the contents of the clipboard. It’s really annoying, the tools are almost unusable because navigating by keyboard is obviously inconvenient.
I tried to disable this behavior by unchecking Middle-click: Pastes selected text, but it doesn’t work.
It’s possible to disable this behavior in Firefox-based browsers. But it’s not convenient for me because I use Chromium-based browsers mostly.
Middle-click text pasting is very old and standard since forever.
I understand it, but operating systems are evolving, and users’ needs are changing. For the Wayland example, why not stay on x11 if it’s been the standard for many, many years.
I don’t mind pasting by the middle-click, but IMHO, there should be an option to disable it. I can use the tools I mentioned above on macOS, Windows and I would like to use them on Linux (with KDE).
I’ve just rechecked with rebooting the system and the same behavior: pasting selected text while navigating on Canva whiteboard. I’m not sure, maybe it’s a Fedora bug.
This isn’t a matter of ‘new standards’ it’s a similar problem to ‘why not just keep upgrading your Austin Morris Minor?’. There comes a time when the code is not manageable - but the standards are another matter.
Furthermore, it isn’t feasible to scrap this behaviour because a couple of applications misbehave… The only time this bothered me was when I used a fresh desktop and middle-clicked the desktop (usually to bring up a menu, switch desktops) and ended up with an annoying Stick-it note there instead… easily fixed with settings.
There’s a note that says you can use Spacebar and Left Click to hold and pan instead.
Miro is separate (these actions are controlled by software). This issue on a CHROMEBOOK, so it is not KDE Plasma specific.
With Miro, it appears that Shift and LMB does the job - try that.
Figma apparently has a fix using a Greasemonkey script.
Greasemonkey Script:
A userscript can block pasting only in Figma. Install the Greasemonkey addon and use code that cancels paste events during middle-click drags
While scrolling by holding MMB is sometimes useful, if I can only have one of them, I preffer middle-click-pasting. But I would really appreciate it if more applications would implement it correctly..
But… why can’t we have both? I mean as in:
short press & release => paste
hold => scroll
If I remember correctly, this is basically how it’s handled with the trackpoint on Thinkpads since more than a decade. Why not everywhere else as well?
If you use Plasma and KWin, only it can restrict this feature centrally (or try to).
Did you check with canva in firefox with middle click pasting disabled (clipboard.autocopy) ?
And is it disabled on other websites ? Is it the clipboard content that is pasted (and not the currently selected text) ?
A website or application can re-implement the middle click pasting by themselves although not fully.
I use keyd to map two “extra” mouse buttons to keystrokes, which are configured in the KDE shortcut settings to trigger the Overview effect, and move the top window to my other screen.
I agree. It’s a bad example. Maybe I can provide another one, like arrow keys and WASD in FPS, but it doesn’t make sense. Let’s talk substance.
I disagree with that. Not a couple of applications. Almost every drawing tool supports middle-click navigation. If you look at forums, there are tons of questions related to the issue. The number of threads on the forums further proves that the problem exists. But thank you for providing possible workarounds.
In summary, thank you guys for providing workarounds and possible hacks. It definitely works:
Using Firefox with middlemouse.paste works.
Using 3rd party tools and scripts works as well.
Some tools reimplemented middle-click pasting (like draw io).
And I don’t mind about middle-click pasting at all. My complaint was about another point. On Linux, where you can customize almost everything, whatever you want: disable CapsLock, change keyboard layout by any hotkey, open folders\files by single-click or double-click. Among this customization, you can’t configure such a trivial thing as middle-click pasting. And you have to ask developers of each tool to fix it on their side, whereas on Windows and macOS it works initially.
I have a different take on this from an accessibility perspective. I have a motor control disability and the middle mouse button is heavily responsible for populating the clipboard and pasting all the time and actively makes my user experience more difficult. I just want an off toggle. The existing standards were not made with people like me in mind.
If it’s just about turning it off, you could remap the middle mouse button to something else. (possible tools: xremap, input-remapper, inputmangler, etc.)
Depending on your specific needs, maybe the debounce feature in inputmangler could help. (I’m the author of that tool, so write me if you need help setting in up - it can be tricky)
EDIT: I just remembered - there is a debounce feature in libinput, too. It might be more sophisticated and possibly easier to set up - if you can find out how (in which case: please write me too, because I have no idea how to configure any libinput feature on wayland -.-)
Thanks for advising. But if I remap the middle-click button, the default behavior, like navigating through a document by holding the middle-button will not work.
There have been complaints about middle-click paste across different forums for over a decade but it doesn’t seem to be fixable by the KDE devs unfortunately, that toggle just cannot affect random applications that have this function.
I also did not expect this behaviour to be so difficult to change and it has been a pain since switching away from Windows. I don’t find the paste function useful at all and the risk of randomly pasting personal information in the wrong place has made me afraid of ever using autoscroll.
Given how long it has been a problem for some users and the level of coordination across projects changing this would require, the chance of it ever being easily customizable seem close to zero. These are the joys of fragmentation in operating systems with so many independently developed components, I suppose.
There is a toggle in System Settings. I use the toggle.
I have set middle-click paste to off for both my mice and MMB hold and drag for one of them.
It works in all KDE apps I tried and by default in all Qt apps I make.
Meaning that I don’t need to do any extra programming for it to work properly.
If you are getting different behaviour in your specific application, that is because your application is doing something extra, to make middle-click to paste work.
Firefox has an option in about:config as others have stated. That works.
If you are unable to disable the thing in a non-KDE application, I would suggest giving a bug report to that specific application or the toolkit they use.
If I enable both, MMB drag to scroll and MMB paste there is a chance I invoke paste when I am trying to scroll.
This had tripped me quite a few times during programming while using X11 and got fixed in Wayland.
Please don’t remove the ability to toggle.