SUMMARY On laptops screen rotation is only rotating the scree, but not the touchscreen, so touch input remains unrotated. STEPS TO REPRODUCE 1. goto Settings > Display > Rotate the screen by 180° on laptops that have devices with duplicate names (e.g. Lenovo Yoga 900s) OBSERVED RESULT Screen and touchpad are rotated, but touchscreen coordinates are not rotated. EXPECTED RESULT Coordinate Transformation Matrix must be applied for touchscreen as well. ADDITIONAL INFORMATION This happens because Settings is executing the following command: xrandr -o inverted xinput set-prop "ELAN21EF:00 04F3:2283" --type=float "Coordinate Transformation Matrix" -1 0 1 0 -1 1 0 0 1 xinput set-prop "Synaptics TM2714-003" --type=float "Coordinate Transformation Matrix" -1 0 1 0 -1 1 0 0 1 This leads to the following error: "Warning: There are multiple devices matching 'ELAN21EF:00 04F3:2283'. To ensure the correct one is selected, please use the device ID, or prefix the device name with 'pointer:' or 'keyboard:' as appropriate. unable to find device ELAN21EF:00 04F3:2283" So instead, settings should call the following (notice the pointer arg): xrandr -o inverted xinput set-prop "pointer:ELAN21EF:00 04F3:2283" --type=float "Coordinate Transformation Matrix" -1 0 1 0 -1 1 0 0 1 xinput set-prop "pointer:Synaptics TM2714-003" --type=float "Coordinate Transformation Matrix" -1 0 1 0 -1 1 0 0 1
I noticed this as well. I'm currently adding auto rotation support, but that's primarily aimed at Wayland. See series at https://phabricator.kde.org/D26038. To be frank I don't know if I find the time to look into adding the rotation matrix for input devices to libkscreen's RandR backend. If you want to take a look at it feel free to submit a patch.
*** Bug 446165 has been marked as a duplicate of this bug. ***
*** Bug 431851 has been marked as a duplicate of this bug. ***
*** Bug 325520 has been marked as a duplicate of this bug. ***
Git commit 09b988e6628093e7d4c8b92cd8a0a1fe2da2f77e by Marco Martin. Committed on 04/03/2022 at 09:05. Pushed by mart into branch 'master'. X11: align touchscreen to internal display On Wayland is the compositor itself that keeps the touchscreen coordinates mapped to the size and position of the internal screen, also keeping rotation into account. on X11, needs to be done via XInput, do it when KScreen actually applies a configuration. M +19 -0 CMakeLists.txt A +3 -0 config-X11.h.cmake M +7 -1 kded/CMakeLists.txt M +192 -0 kded/daemon.cpp M +4 -0 kded/daemon.h https://invent.kde.org/plasma/kscreen/commit/09b988e6628093e7d4c8b92cd8a0a1fe2da2f77e
Git commit 579358f501ae978aa527a25eb3ef9dd42557db46 by Marco Martin. Committed on 15/03/2022 at 15:02. Pushed by mart into branch 'Plasma/5.24'. X11: align touchscreen to internal display On Wayland is the compositor itself that keeps the touchscreen coordinates mapped to the size and position of the internal screen, also keeping rotation into account. on X11, needs to be done via XInput, do it when KScreen actually applies a configuration. M +19 -0 CMakeLists.txt A +3 -0 config-X11.h.cmake M +7 -1 kded/CMakeLists.txt M +192 -0 kded/daemon.cpp M +4 -0 kded/daemon.h https://invent.kde.org/plasma/kscreen/commit/579358f501ae978aa527a25eb3ef9dd42557db46
*** Bug 428760 has been marked as a duplicate of this bug. ***
*** Bug 451495 has been marked as a duplicate of this bug. ***