libinput-gestures icon indicating copy to clipboard operation
libinput-gestures copied to clipboard

Don't recreate cursor movements in 3FD

Open daveriedstra opened this issue 6 years ago • 6 comments

Currently libinput eats cursor movements during gestures, so our 3-finger-drag technique recreates them using xdotool. This causes CPU usage to spike, bypasses pointer acceleration, and is generally an inferior experience. A better approach would be to allow cursor movement during gestures while still triggering mousedown / up at gesture beginning / end.

I'm not sure how to do this.

daveriedstra avatar Nov 26 '18 01:11 daveriedstra

I just pushed a small change that uses the accelerated cursor values, making this problem a little less noticeable. The cursor movement is still a little janky though, so the issue is still valid.

daveriedstra avatar Dec 08 '18 20:12 daveriedstra

Hello, first of all, thanks for the work to get the three finger drag working. I have tried it out and although it works, the problem is, that the drag speed is way to low. Is there any way to increase the speed?

The "problem" with the three finger drag is, that during any gesture the mouse course does not move. As you have stated it would be the best solution to simply allow courser movement during (three finger) gestures. Have you made any progress to finding out how to do that?

Takao-7 avatar Jan 30 '19 11:01 Takao-7

@Takao-7 not separately from regular (ie, non-dragging) cursor movement.

I haven't had any luck with allowing cursor movement during gestures, but I stumbled on evdev which could be a better way of recreating the cursor movement (since it doesn't require so much string parsing and it wouldn't be tied to X). I'd need to start it in a separate project though, and I haven't had the time recently.

daveriedstra avatar Feb 01 '19 22:02 daveriedstra

Here's that separate project: https://github.com/daveriedstra/draggy

daveriedstra avatar Feb 19 '19 21:02 daveriedstra

@daveriedstra Thanks for the work. I sadly had to send my new notebook (Matebook X Pro) back because of coil whine. Currently I don't have a Linux notebook, only my old MacBook, so I can't test it out. I will eventual buy a new notebook and put Linux on it, then I will definitive test it out.

Regarding libinput-gestures: Is it possible to use two finger gestures and use two different actions ("Back" and "horizontal drag"), depending on where I make the gesture on the trackpad?

Takao-7 avatar Feb 25 '19 11:02 Takao-7

Sorry to hear about the coil whine! I'm afraid of running into that in my next machine as well.

Splitting the trackpad gestures up as you describe is not possible with libinput-gestures. It's an interesting idea though.

daveriedstra avatar Feb 25 '19 17:02 daveriedstra