Bug 99703 - Trackpad accidental two-finger touch stops cursor movement too early
Summary: Trackpad accidental two-finger touch stops cursor movement too early
Status: RESOLVED FIXED
Alias: None
Product: Wayland
Classification: Unclassified
Component: libinput (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Wayland bug list
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 98802 99268 104734 105265
  Show dependency treegraph
 
Reported: 2017-02-07 10:45 UTC by Christophe de Dinechin
Modified: 2018-02-27 06:40 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Christophe de Dinechin 2017-02-07 10:45:26 UTC
On macOS and Windows, when you move the cursor around at high enough speed, an accidental second finger touch on the trackpad does not stop the cursor. Instead, the second finger is ignored, and cursor movement continues. This is very comfortable, as it allows one to rest fingers on the trackpad while doing large mouse movements, e.g. crossing the screen.

Linux, however, immediately switches to two-finger touch (i.e. scroll) as soon as you touch the trackpad, irrespective of current cursor speed. This results in frequent, inconvenient, accidental missed targets or random scrolls where the intent was really mouse movement. This is especially annoying for people who switch back and forth between Linux and other platforms.

If the cursor is presently moving at high enough speed, it is unlikely that the person wants to immediately convert that movement to fast scrolling in the same direction. It seems much more likely that the second finger is simply touching the trackpad because it's a natural resting position.

Suggestion: Define a speed threshold above which an incoming second touch is ignored. This could be an option if some people really prefer the current behaviour.
Comment 1 Peter Hutterer 2017-02-08 00:17:39 UTC
Can you test macos and/or windows to figure out the parameters they're using? Would be useful to have a writeup of what you think happens there, mainly for comparision/inspriration.
Comment 2 Christophe de Dinechin 2017-02-08 11:18:30 UTC
(In reply to Peter Hutterer from comment #1)
> Can you test macos and/or windows to figure out the parameters they're
> using? Would be useful to have a writeup of what you think happens there,
> mainly for comparision/inspriration.

On macOS, if I move the mouse cursor with one finger, and then drop a second finger while the cursor is on a window that can scroll, I observe the following (test done by moving the cursor from top to bottom):

# If my mouse cursor is travelling at about 100px/s or more, the second finger has no visible effect. The cursor keeps moving.

# If my mouse cursor is moving at 20px/s or less, then the second finger immediately activates scrolling much like in Linux.

It's hard to measure the threshold precisely. I don't know of a tool for that.

I'll do a test under Windows if I can revive my last PC laptop.
Comment 3 Christophe de Dinechin 2017-02-08 11:48:02 UTC
(In reply to Peter Hutterer from comment #1)
> Can you test macos and/or windows to figure out the parameters they're
> using? Would be useful to have a writeup of what you think happens there,
> mainly for comparision/inspriration.

I may have been somewhat optimistic about Windows doing the right thing ;-)

I just tested on a HP Envy dv6, and apparently, the behavior is similar to Linux. I probably did not pay much attention because the trackpad on this machine is so small you tend to naturally have the second finger outside of the tracking area anyways. It was actually quite hard to reach any kind of speed with such a tiny tracking area.
Comment 4 Peter Hutterer 2017-02-10 03:50:30 UTC
Any chance you want to work on this feature? :)
Comment 5 Christophe de Dinechin 2017-02-10 08:47:54 UTC
(In reply to Peter Hutterer from comment #4)
> Any chance you want to work on this feature? :)

I can try to take a look, but I'm not familiar at all with the code that deals with that.
Comment 6 Peter Hutterer 2017-06-21 04:44:33 UTC
Ok, I have a preliminary patch for this feature available now for testing:
https://github.com/whot/libinput/tree/wip/ignore-moved-touches

Let me know how you go, it still needs a bit of tuning but I think that's roughly the behaviour we want?
Comment 7 Peter Hutterer 2017-09-01 06:12:33 UTC
branch has been updated, and the patchset is on the list

https://lists.freedesktop.org/archives/wayland-devel/2017-September/034897.html
Comment 8 Peter Hutterer 2017-09-11 00:10:46 UTC
commit de5246dae0201ea951715f62da806f90321978c5 
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Wed Jun 21 12:29:52 2017 +1000

    touchpad: use motion speed to ignore accidental 2fg touches
Comment 9 Nate Graham 2017-10-26 12:57:30 UTC
This change fixes the issue for me!


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.