Bug 1497802 - "Button" 3 no longer recognized on Dell Latitude 3570 touchpad
Summary: "Button" 3 no longer recognized on Dell Latitude 3570 touchpad
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Fedora
Classification: Fedora
Component: xorg-x11-drv-libinput
Version: 26
Hardware: Unspecified
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Peter Hutterer
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-10-02 17:26 UTC by Stuart D Gathman
Modified: 2017-12-19 04:19 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2017-12-19 04:19:36 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Stuart D Gathman 2017-10-02 17:26:39 UTC
Description of problem:
Libinput interprets pressing button 3 as button 1 as seen in xev

Version-Release number of selected component (if applicable):
xorg-x11-drv-libinput-0.26.0-1.fc26.x86_64

How reproducible:
always

Steps to Reproduce:
1. run xev
2. press right touchpad button
3.

Actual results:
xev reports button 1 pressed

Expected results:
xev reports button 3 pressed

Additional info:
Works correctly with xorg-x11-drv-synaptics-legacy.  This touchpad has only one physical button, and the driver decides whether to report button 3 based on the finger position when pressing the button.  Pressing both buttons simultaneously doesn't work with this scheme, so I use the 2 finger modifier to emulate button 2.  The pad does not detect 3 fingers, so I cannot use that to emulate button 3 with libinput.

Comment 1 Stuart D Gathman 2017-10-02 17:34:04 UTC
The synaptics driver does not support the 2 finger modifier.  So I can reboot with synaptics to use button 3, or reboot with libinput to use button 2.  Sigh.

Comment 2 Stuart D Gathman 2017-10-02 17:40:37 UTC
System info: https://paste.fedoraproject.org/paste/AJDGussWyfMii7sM2n7UUA

Comment 3 Stuart D Gathman 2017-10-02 18:00:59 UTC
When using the synaptics driver, the 2 finger modifier is triggered by using 3 fingers.  So configure touchpad for 2 fingers emulated middle click, and use 3 fingers instead for a fully functional touchpad with synaptics.

Comment 4 Peter Hutterer 2017-10-03 10:01:44 UTC
do you have left-handed mode enabled?

Comment 5 Stuart D Gathman 2017-10-03 13:06:04 UTC
No.  Left-handed mode is not enabled.

Comment 6 Peter Hutterer 2017-12-19 00:40:25 UTC
sorry, this kinda fell through the cracks. Is this still an issue?

please attach the output of xinput list-props "...device name..." so we can check if software buttons are actually enabled.

Also check the output from:
   gsettings get org.gnome.desktop.peripherals.touchpad  click-method
and if need be, run 
   gsettings set org.gnome.desktop.peripherals.touchpad  click-method 'areas'
to make sure we use software button areas.

Comment 7 Stuart D Gathman 2017-12-19 00:54:32 UTC
With synaptics driver (both buttons work):
# xinput list-props 13
Device 'DLL06F3:00 06CB:75DA Touchpad':
	Device Enabled (142):	1
	Coordinate Transformation Matrix (144):	1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
	Device Accel Profile (272):	1
	Device Accel Constant Deceleration (273):	2.500000
	Device Accel Adaptive Deceleration (274):	1.000000
	Device Accel Velocity Scaling (275):	12.500000
	Synaptics Edges (298):	48, 1176, 40, 704
	Synaptics Finger (299):	25, 30, 0
	Synaptics Tap Time (300):	180
	Synaptics Tap Move (301):	63
	Synaptics Tap Durations (302):	180, 180, 100
	Synaptics ClickPad (303):	1
	Synaptics Middle Button Timeout (304):	0
	Synaptics Two-Finger Pressure (305):	282
	Synaptics Two-Finger Width (306):	7
	Synaptics Scrolling Distance (307):	-28, -28
	Synaptics Edge Scrolling (308):	1, 0, 0
	Synaptics Two-Finger Scrolling (309):	1, 0
	Synaptics Move Speed (310):	1.000000, 1.750000, 0.139665, 0.000000
	Synaptics Off (311):	2
	Synaptics Locked Drags (312):	0
	Synaptics Locked Drags Timeout (313):	5000
	Synaptics Tap Action (314):	0, 0, 0, 0, 0, 0, 0
	Synaptics Click Action (315):	1, 3, 2
	Synaptics Circular Scrolling (316):	0
	Synaptics Circular Scrolling Distance (317):	0.100000
	Synaptics Circular Scrolling Trigger (318):	0
	Synaptics Circular Pad (319):	0
	Synaptics Palm Detection (320):	0
	Synaptics Palm Dimensions (321):	10, 200
	Synaptics Coasting Speed (322):	20.000000, 50.000000
	Synaptics Pressure Motion (323):	30, 160
	Synaptics Pressure Motion Factor (324):	1.000000, 1.000000
	Synaptics Grab Event Device (325):	0
	Synaptics Gestures (326):	1
	Synaptics Capabilities (327):	1, 0, 0, 1, 1, 0, 0
	Synaptics Pad Resolution (328):	12, 12
	Synaptics Area (329):	0, 0, 0, 0
	Synaptics Soft Button Areas (330):	612, 0, 610, 0, 0, 0, 0, 0
	Synaptics Noise Cancellation (331):	7, 7
	Device Product ID (262):	1739, 30170
	Device Node (263):	"/dev/input/event12"

Comment 8 Stuart D Gathman 2017-12-19 00:57:43 UTC
Synaptics driver:

$ gsettings get org.gnome.desktop.peripherals.touchpad  click-method
'default'
$ gsettings set org.gnome.desktop.peripherals.touchpad  click-method 'areas'

Comment 9 Stuart D Gathman 2017-12-19 01:24:35 UTC
With libinput:
$ xinput list-props 13
Device 'DLL06F3:00 06CB:75DA Touchpad':
	Device Enabled (142):	1
	Coordinate Transformation Matrix (144):	1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
	libinput Tapping Enabled (295):	0
	libinput Tapping Enabled Default (296):	0
	libinput Tapping Drag Enabled (297):	1
	libinput Tapping Drag Enabled Default (298):	1
	libinput Tapping Drag Lock Enabled (299):	0
	libinput Tapping Drag Lock Enabled Default (300):	0
	libinput Tapping Button Mapping Enabled (301):	1, 0
	libinput Tapping Button Mapping Default (302):	1, 0
	libinput Natural Scrolling Enabled (277):	1
	libinput Natural Scrolling Enabled Default (278):	0
	libinput Left Handed Enabled (279):	0
	libinput Left Handed Enabled Default (280):	0
	libinput Accel Speed (281):	0.000000
	libinput Accel Speed Default (282):	0.000000
	libinput Scroll Methods Available (286):	1, 1, 0
	libinput Scroll Method Enabled (287):	1, 0, 0
	libinput Scroll Method Enabled Default (288):	1, 0, 0
	libinput Click Methods Available (303):	1, 1
	libinput Click Method Enabled (304):	1, 0
	libinput Click Method Enabled Default (305):	1, 0
	libinput Middle Emulation Enabled (291):	0
	libinput Middle Emulation Enabled Default (292):	0
	libinput Send Events Modes Available (262):	1, 1
	libinput Send Events Mode Enabled (263):	0, 0
	libinput Send Events Mode Enabled Default (264):	0, 0
	libinput Disable While Typing Enabled (306):	1
	libinput Disable While Typing Enabled Default (307):	1
	Device Node (265):	"/dev/input/event18"
	Device Product ID (266):	1739, 30170
	libinput Drag Lock Buttons (293):	<no items>
	libinput Horizontal Scroll Enabled (294):	0

Comment 10 Stuart D Gathman 2017-12-19 01:33:37 UTC
Behaviour is different - progress?

Setting "Click Actions" to "Automatic" in settings makes button 1 and 3 work, but then I get no button 2.  Selecting "Multiple fingers for button 2 and 3" makes button 1 and 2 work, but then I get no button 3.

Selecting "Emulate mouse buttons" gives me buttons 1 and 3, but not 2 (same as "Automatic").

I have set Alt+CapsLock to toggle enable touchpad.  I could use another hotkey to toggle between having button 2 work or button 3 work with libinput driver.  That will give me (cumbersome) functionality while keeping libinput driver loaded, since synaptics driver is going away.

Is there a way to use a keyboard modifier to get button 2?

Comment 11 Stuart D Gathman 2017-12-19 01:43:47 UTC
With libinput, click-method behaves the same with both 'default' and 'areas'.  (As did legacy driver.)

Comment 12 Peter Hutterer 2017-12-19 03:06:32 UTC
this setting has no effect on the synaptics driver, should've mentioned that, sorry.

when you have the areas option enabled, then you should get a middle click in the center of the touchpad, see https://wayland.freedesktop.org/libinput/doc/latest/clickpad_softbuttons.html
If you want the emulation (left+right == middle) then you need to turn middle button emulation on (libinput Middle Emulation Enabled)

Comment 13 Stuart D Gathman 2017-12-19 03:30:34 UTC
Ah, yes button 2 is assigned a rather small area to the left of the center line.  I've marked the location.

I couldn't get Middle Emulation to work, but a small button 2 is probably better than that anyway. I suspect there is a way to shift the button 2 area with a setting, but I'm going to stick with just physically marking it.

Comment 14 Peter Hutterer 2017-12-19 03:35:01 UTC
if it's left of the center line then it's likely the touchpad dimensions are out, please run the touchpad-edge-detector tool and attach the output here, thanks.

Comment 15 Stuart D Gathman 2017-12-19 04:08:24 UTC
Not sure my measurement of the size should be taken over the kernel's, but..

# touchpad-edge-detector 105x65 /dev/input/event18
Touchpad DLL06F3:00 06CB:75DA Touchpad on /dev/input/event18
Move one finger around the touchpad to detect the actual edges
Kernel says:	x [0..1224], y [0..744]
Touchpad sends:	x [0..1224], y [0..744] |^C|

Touchpad size as listed by the kernel: 102x62mm
User-specified touchpad size: 105x65mm
Calculated ranges: 1224/744

Suggested udev rule:
# <Laptop model description goes here>
evdev:name:DLL06F3:00 06CB:75DA Touchpad:dmi:bvnDellInc.:bvr1.1.2:bd12/17/2015:svnDellInc.:pnLatitude3570:pvr:rvnDellInc.:rn0DV07V:rvrA00:cvnDellInc.:ct9:cvr:*
 EVDEV_ABS_00=0:1224:12
 EVDEV_ABS_01=0:744:11
 EVDEV_ABS_35=0:1224:12
 EVDEV_ABS_36=0:744:11
--------------------------------------------
However, I think it is fixed at this point.  When I first reported this, it wasn't detecting button 3, much less button 2.  And now it is working quite reasonably.  I suggest we change the status to "Fixed in current release"

Comment 16 Peter Hutterer 2017-12-19 04:19:36 UTC
> Not sure my measurement of the size should be taken over the kernel's, but..

some touchpads are out by 10mm or more, which means the buttons are in the wrong position, pointer acceleration is off, etc.

But in this case, the kernel is close enough and without floating point resolutions we can't get anywhere better anyway, so it's not worth changing anything here.

Closing the bug as requested, thanks for testing.


Note You need to log in before you can comment on or make changes to this bug.