Summary: | Reduce/remove two-finger scrolling threshold | ||
---|---|---|---|
Product: | Wayland | Reporter: | Cyril B. <lagoon42> |
Component: | libinput | Assignee: | Wayland bug list <wayland-bugs> |
Status: | RESOLVED FIXED | QA Contact: | |
Severity: | normal | ||
Priority: | medium | CC: | elreydetodo, peter.hutterer |
Version: | unspecified | ||
Hardware: | Other | ||
OS: | All | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Bug Depends on: | 93503 | ||
Bug Blocks: | |||
Attachments: |
3 normal scrolls
0001-touchpad-if-the-second-finger-is-within-20x5mm-bias-.patch |
Description
Cyril B.
2015-12-25 16:54:15 UTC
Please run the touchpad-edge-detector tool an post the output here, together with the output of sudo evemu-describe for the touchpad device. # touchpad-edge-detector /dev/input/event9 Touchpad DLL0704:01 06CB:76AD Touchpad on /dev/input/event9 Move one finger around the touchpad to detect the actual edges Kernel says: x [0..1216], y [0..680] Touchpad sends: x [0..1216], y [0..680] |\-\ ^C Touchpad size as listed by the kernel: 101x56mm Calculate resolution as: x axis: 1216/<width in mm> y axis: 680/<height in mm> Suggested udev rule: # <Laptop model description goes here> evdev:name:DLL0704:01 06CB:76AD Touchpad:dmi:bvnDellInc.:bvr1.1.7:bd11/27/2015:svnDellInc.:pnXPS139350:pvr:rvnDellInc.:rn07TYC2:rvrA01:cvnDellInc.:ct9:cvr:* EVDEV_ABS_00=0:1216:<x resolution> EVDEV_ABS_01=0:680:<y resolution> EVDEV_ABS_35=0:1216:<x resolution> EVDEV_ABS_36=0:680:<y resolution> # evemu-describe /dev/input/event9 # EVEMU 1.3 # Kernel: 4.4.0-1-ARCH # DMI: dmi:bvnDellInc.:bvr1.1.7:bd11/27/2015:svnDellInc.:pnXPS139350:pvr:rvnDellInc.:rn07TYC2:rvrA01:cvnDellInc.:ct9:cvr: # Input device name: "DLL0704:01 06CB:76AD Touchpad" # Input device ID: bus 0x18 vendor 0x6cb product 0x76ad version 0x100 # Supported events: # Event type 0 (EV_SYN) # Event code 0 (SYN_REPORT) # Event code 1 (SYN_CONFIG) # Event code 2 (SYN_MT_REPORT) # Event code 3 (SYN_DROPPED) # Event code 4 ((null)) # Event code 5 ((null)) # Event code 6 ((null)) # Event code 7 ((null)) # Event code 8 ((null)) # Event code 9 ((null)) # Event code 10 ((null)) # Event code 11 ((null)) # Event code 12 ((null)) # Event code 13 ((null)) # Event code 14 ((null)) # Event type 1 (EV_KEY) # Event code 272 (BTN_LEFT) # Event code 325 (BTN_TOOL_FINGER) # Event code 330 (BTN_TOUCH) # Event code 333 (BTN_TOOL_DOUBLETAP) # Event code 334 (BTN_TOOL_TRIPLETAP) # Event type 3 (EV_ABS) # Event code 0 (ABS_X) # Value 991 # Min 0 # Max 1216 # Fuzz 0 # Flat 0 # Resolution 12 # Event code 1 (ABS_Y) # Value 180 # Min 0 # Max 680 # Fuzz 0 # Flat 0 # Resolution 12 # Event code 47 (ABS_MT_SLOT) # Value 2 # Min 0 # Max 2 # Fuzz 0 # Flat 0 # Resolution 0 # Event code 53 (ABS_MT_POSITION_X) # Value 0 # Min 0 # Max 1216 # Fuzz 0 # Flat 0 # Resolution 12 # Event code 54 (ABS_MT_POSITION_Y) # Value 0 # Min 0 # Max 680 # Fuzz 0 # Flat 0 # Resolution 12 # Event code 57 (ABS_MT_TRACKING_ID) # Value 0 # Min 0 # Max 65535 # Fuzz 0 # Flat 0 # Resolution 0 # Properties: # Property type 0 (INPUT_PROP_POINTER) # Property type 2 (INPUT_PROP_BUTTONPAD) N: DLL0704:01 06CB:76AD Touchpad I: 0018 06cb 76ad 0100 P: 05 00 00 00 00 00 00 00 B: 00 0b 00 00 00 00 00 00 00 B: 01 00 00 00 00 00 00 00 00 B: 01 00 00 00 00 00 00 00 00 B: 01 00 00 00 00 00 00 00 00 B: 01 00 00 00 00 00 00 00 00 B: 01 00 00 01 00 00 00 00 00 B: 01 20 64 00 00 00 00 00 00 B: 01 00 00 00 00 00 00 00 00 B: 01 00 00 00 00 00 00 00 00 B: 01 00 00 00 00 00 00 00 00 B: 01 00 00 00 00 00 00 00 00 B: 01 00 00 00 00 00 00 00 00 B: 01 00 00 00 00 00 00 00 00 B: 02 00 00 00 00 00 00 00 00 B: 03 03 00 00 00 00 80 60 02 B: 04 00 00 00 00 00 00 00 00 B: 05 00 00 00 00 00 00 00 00 B: 11 00 00 00 00 00 00 00 00 B: 12 00 00 00 00 00 00 00 00 B: 14 00 00 00 00 00 00 00 00 B: 15 00 00 00 00 00 00 00 00 B: 15 00 00 00 00 00 00 00 00 A: 00 0 1216 0 0 12 A: 01 0 680 0 0 12 A: 2f 0 2 0 0 0 A: 35 0 1216 0 0 12 A: 36 0 680 0 0 12 A: 39 0 65535 0 0 0 how big is your touchpad in mm? the kernel data says 102x57mm - is this correct? According to my measurements, it's 105x60mm, so mostly correct. can you judge how far you have to move the finger for scrolling to trigger? the threshold is now 1 mm, and it triggers based on time and partially on finger position too. if you have to move it more than 1mm, then that's a bug somewhere, if it's within 1mm then that's a drawback of the gesture detection code. It's no more than 1mm, so I guess that's expected. Have you re-run that with the no-hysteresis patch from bug 93503? Does that make it better? Yes, and it didn't noticeably help. I have patched libinput to set a move threshold to 0.2mm, and the scrolls are now basically instantaneous. The pinch gesture doesn't really work anymore (tested with libinput-debug-events), but since I never use it (and don't even know what applications do support it), I'm fine with that. evemu-record yourself doing a couple of 'normal' scroll motions please. I wonder if there's some bias we can put into the system depending on the finger position. if not, there isn't much we can do about the threshold, unfortunately. We have the ability to cancel a gesture we cannot cancel a scroll motion. So we could start a pinch, cancel and switch to scroll but we can't go the other way round. Created attachment 121614 [details]
3 normal scrolls
Here's a capture of 3 normal scrolls.
Data analysis of the initial finger data: Touchpad dimensions: 101x56mm (1216x680 units) New 2fg touch: distance 13mm (h 13mm v 2mm) New 2fg touch: distance 13mm (h 13mm v 2mm) New 2fg touch: distance 13mm (h 13mm v 2mm) Max distance: 13mm, 166 units Min distance 13mm, 162 units Max distance: 13mm horiz 2mm vert Min distance 13mm horiz, 2mm vert the low vertical spread means we can add something to bias towards 2fg scrolling here. Let's see what I can come up with. Created attachment 121661 [details] [review] 0001-touchpad-if-the-second-finger-is-within-20x5mm-bias-.patch This is really perfect, the scrolls do start immediately. It feels even better than my ugly patch that set the threshold to 0.2mm. Thanks! ok, this patch breaks (swipe) gestures pretty badly, I'll have to recall that. it's hard now to trigger a gesture without scroll events, something that will become a problem when gestures actually do something on the desktop. We'll need to find a different solution here. The main problem is: for a swipe gesture, the fingers are effectively in the same position as for a two-finger scroll event. If the fingers are set down in separate event frames (likely) we transition from 1 to 2 to 3 fingers in the gesture state machine. When we hit two fingers we go to scrolling and send the current state before transitioning to 3 fingers and stopping the scrolling again. Pinch gestures can be similarly affected if the two top fingers are set down before the thumb. I think we'll need a scroll cancel event to work around this. https://lists.freedesktop.org/archives/wayland-devel/2016-August/030325.html not reducing the actual threshold, but still a step in the right direction I hope commit a5450e99de680155b3ae9ebf84b8f196caa31c27 Author: Peter Hutterer <peter.hutterer@who-t.net> Date: Wed Aug 3 18:30:05 2016 +1000 gestures: reduce the 2fg scroll timeout to 150ms Can you give libinput with this patch a try please and see if that improves things? Calling it fixed based on a5450e99 and the silence thereafter, please reopen if it's still an issue |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.