Add support for custom pointer acceleration
This patch adds support for the new custom pointer acceleration method in libinput, see libinput/libinput!775 (merged).
Adds new properties and xorg.conf entries for setting the acceleration function's points and step.
AccelProfile
option can now accept custom
value.
Add 4 new options which only apply when AccelProfile
is custom
:
- Add
AccelPointsFallback
option for setting the points of the Fallback acceleration function. Points values are represented by a space-separated list, e.g. "0.0 1.0 2.4 2.5". - Add
AccelStepFallback
option for setting the step of the Fallback acceleration function. When a step of 0.0 is provided, libinput default Fallback acceleration function is used. - Add
AccelPointsMotion
andAccelStepMotion
options, which are equivalent toAccelPointsFallback
andAccelStepFallback
options, but apply to the Motion acceleration function.
Based on !38 (closed).
Have been using the new custom profile on my machine for a while now, awaiting public testing.
Merge request reports
Activity
- Resolved by Yinon Burgansky
- Resolved by Yinon Burgansky
- Resolved by Peter Hutterer
- Resolved by Peter Hutterer
- Resolved by Peter Hutterer
- Resolved by Yinon Burgansky
- Resolved by Yinon Burgansky
- Resolved by Yinon Burgansky
- Resolved by Yinon Burgansky
- Resolved by Yinon Burgansky
- Resolved by Yinon Burgansky
Let me know if you want to take the changes to !38 (closed) or should I organize this MR?
Consider !38 (closed) dead, I just pushed that one so you have most of the things in place and don't need to figure everything out by yourself.
As for code style: it's mostly the same as libinput without line limits because it's virtually impossible to fit everything on one line otherwise ;)
mentioned in merge request !38 (closed)
This ist just a comment for the archives, cc @carlosg: I looked into whether mutter will be happy with changes to the acceleration profile property and the answer is: yes. Mutter's code is in
src/backends/x11/meta-input-settings-x11.c
and the helper isget_property()
. With the changes here mutter will continue to request a 2-sized property, receive a 3-sized one, warn about it but otherwise be fine. So, afaict from a code review only, there are no changes needed to mutter until it wants to actually support the custom pointer accel method.
- Resolved by Peter Hutterer