Summary: | Disabled Middle Click Pasting makes text selection in some GTK apps impossible on Wayland | ||
---|---|---|---|
Product: | [Plasma] kwin | Reporter: | postix <postix> |
Component: | wayland-generic | Assignee: | KWin default assignee <kwin-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | grave | CC: | kde, me, meven.car, meven, nate, postix |
Priority: | NOR | Keywords: | wayland |
Version: | 5.26.2 | ||
Target Milestone: | --- | ||
Platform: | openSUSE | ||
OS: | Linux | ||
Latest Commit: | https://invent.kde.org/plasma/kwin/commit/07195af2b02a044f1ef39bf0b3c26aab58e19dca | Version Fixed In: | 5.26.5 |
Sentry Crash Report: | |||
Attachments: |
Screen recording
kWin Support Info |
Description
postix
2022-11-06 13:43:12 UTC
I found another app, which is affected: `GTK Demo 4.8.2`. ...and more affected GTK apps: * GTK Widget Factory 4.8.2 * Simple-Scan 42.5 * Virtual Machine Manager 4.1.0 * Gnome Chess 43.0 * HandBrake 1.5.1 * RawTherapee 5.8 * gst-debug-viewer 1.20.4 * Xournal++ 1.1.2 Created attachment 153559 [details]
Screen recording
Created attachment 153560 [details]
kWin Support Info
Has been happening to me in all GTK apps ever since Plasma 5.25.90 but I was never really sure why. Turned middle-click paste back on, lo and behold, now I can mark text in GTK text entry fields again. Tested with Pinta and DeaDBeeF on Plasma 5.26.3. This does not affect Firefox, however I'm not quite sure if Firefox is GTK or Qt, or either. (In reply to Aurora Robb Kristiansen from comment #5) > Has been happening to me in all GTK apps ever since Plasma 5.25.90 but I was > never really sure why. Turned middle-click paste back on, lo and behold, now > I can mark text in GTK text entry fields again. > > Tested with Pinta and DeaDBeeF on Plasma 5.26.3. > > This does not affect Firefox, however I'm not quite sure if Firefox is GTK > or Qt, or either. It seems like a bug in GTK exposed by https://invent.kde.org/plasma/kwin/-/merge_requests/3012/diffs Gtk seems to treat primary selection as the main selection :/ > Gtk seems to treat primary selection as the main selection :/
I have reported it now upstream.
Quoting Matthias Clasen @ https://gitlab.gnome.org/GNOME/gtk/-/issues/5372#note_1603916 > I don't have plasma installed, but when I simulate a system without primary selection by ignoring > zwp_primary_selection_device_manager_v1, Ctrl-a keeps working just fine. > Maybe that kde patch does something else that it should not do, > like still implementing that interface, but insisting that the selection is always empty... @Meven and Vladz, maybe you had overseen the following question from the comment above: Does the patch [1] implements the interface, but insists that the selection is always empty? Or does the selection->cancel() line [2] maybe cause this issue? [1] https://invent.kde.org/plasma/kwin/-/merge_requests/3012/diffs [2] https://invent.kde.org/plasma/kwin/-/merge_requests/3012/diffs#769a60050bb02c02c80901c0b0274fd40c633c49_1329_1339 I built the master version of kwin and can confirm that commenting out the line https://invent.kde.org/plasma/kwin/-/merge_requests/3012/diffs#769a60050bb02c02c80901c0b0274fd40c633c49_1329_1339 fixes the issue for me while also still keeping the middle click pasting disabled. A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/3298 A possibly relevant merge request was started @ https://invent.kde.org/qt/qt/qtwayland/-/merge_requests/62 Git commit da229ebe85ce9ae29b5014ee44658b5411d5313f by Vlad Zahorodnii. Committed on 16/12/2022 at 12:47. Pushed by vladz into branch 'master'. Revert "Disable PrimarySelection in seat setPrimarySelection" This reverts commit e60f26e0abd71d65044345675b64e45d7b3cd311. Cancelling the primary selection breaks text selection in applications such as gedit. In those apps, you can't select text neither with your mouse nor keyboard. M +1 -1 src/main_wayland.cpp M +1 -33 src/wayland/autotests/server/test_datacontrol_interface.cpp M +0 -15 src/wayland/seat_interface.cpp M +0 -2 src/wayland/seat_interface.h M +0 -1 src/wayland/seat_interface_p.h M +11 -2 src/wayland_server.cpp M +3 -0 src/wayland_server.h https://invent.kde.org/plasma/kwin/commit/da229ebe85ce9ae29b5014ee44658b5411d5313f Thanks! :) Git commit 07195af2b02a044f1ef39bf0b3c26aab58e19dca by Vlad Zahorodnii. Committed on 16/12/2022 at 13:44. Pushed by vladz into branch 'Plasma/5.26'. Revert "Disable PrimarySelection in seat setPrimarySelection" This reverts commit e60f26e0abd71d65044345675b64e45d7b3cd311. Cancelling the primary selection breaks text selection in applications such as gedit. In those apps, you can't select text neither with your mouse nor keyboard. (cherry picked from commit da229ebe85ce9ae29b5014ee44658b5411d5313f) M +1 -1 src/main_wayland.cpp M +1 -33 src/wayland/autotests/server/test_datacontrol_interface.cpp M +0 -15 src/wayland/seat_interface.cpp M +0 -2 src/wayland/seat_interface.h M +0 -1 src/wayland/seat_interface_p.h M +11 -2 src/wayland_server.cpp M +2 -0 src/wayland_server.h https://invent.kde.org/plasma/kwin/commit/07195af2b02a044f1ef39bf0b3c26aab58e19dca |