-
Notifications
You must be signed in to change notification settings - Fork 115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can not swap mouse button (emulate libinput input properties) #251
Comments
Hi @liang16 Could you add a lot more context please. What are you trying to do, and what doesn't work exactly? |
Hi @matt335672
thinks. |
I've had a good look into this, and it doesn't seem to be possible at the moment. The main problem is that the xrdp mouse driver doesn't support the libinput "Left Handed Enabled" property. If I use Device 'spice vdagent tablet': Device Enabled (124): 1 Coordinate Transformation Matrix (126): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000 libinput Natural Scrolling Enabled (264): 0 libinput Natural Scrolling Enabled Default (265): 0 libinput Middle Emulation Enabled (266): 0 libinput Middle Emulation Enabled Default (267): 0 libinput Calibration Matrix (268): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000 libinput Calibration Matrix Default (269): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000 libinput Left Handed Enabled (270): 0 libinput Left Handed Enabled Default (271): 0 libinput Send Events Modes Available (247): 1, 0 libinput Send Events Mode Enabled (248): 0, 0 libinput Send Events Mode Enabled Default (249): 0, 0 Device Node (250): "/dev/input/event4" Device Product ID (251): 0, 0 libinput Drag Lock Buttons (272): libinput Horizontal Scroll Enabled (273): 1 libinput High Resolution Wheel Scroll Enabled (274): 1 Toggling the GNOME control above changes Using
I've tried messing about with The same happens with the VNC backend. The RDP protocol itself has no way to communicate the user's preference from the RDP client that I can find. So I don't think a solution at the xrdp level is right here either. I'm going to mark this as a 'feature request'. At the moment I can't see the best way to implement this. Anyone have any suggestions? |
As it happens, I've made some progress on this. The issues I had with Create # -*- sh -*-
# Xsession.d script to set handedness for a GNOME XRDP session mouse
#
# This file is sourced by Xsession(5), not executed.
if [ -n "$XRDP_SESSION" ]; then
case "`/usr/bin/dconf read \
/org/gnome/desktop/peripherals/mouse/left-handed`" in
true) /usr/bin/xmodmap -e "pointer = 3 2 1" ;;
*) /usr/bin/xmodmap -e "pointer = 1 2 3"
esac
fi The required utilities are installed with @liang16 - do you want to try this and report back? In the longer term, we could go down the route of emulating the libinput-specific device parameters for the xorgxrdp driver. These are text strings defined by the xorg-xf86-input-libinput driver in include/libinput-properties.h. This might work - I haven't tried it yet. Disadvantage of this technique is it only works for the xorgxrdp backend. |
@liang16 - did you manage to try this? |
@matt335672 I've tested your above config and it works correctly, with the expected caveat that a full log-off/log-on is required to toggle the setting. FWIW The |
Thanks for reporting back @BruceJL The missing package looks like it's called I'll move this to a feature request on |
Is there a solution for left-handed people?
thanks!
The text was updated successfully, but these errors were encountered: