I’ve been annoyed for a while that Firefox only supports the kind of two finger scrolling where moving the fingers on the touch pad a decent amount emits a scroll wheel event. I just now found out that if you start Firefox with the environment variable MOZ_USE_XINPUT2 set to 1, it will use xinput 2, and support actual smooth touch pad scrolling.
I know this works for Firefox 55 or newer, but don’t know the earliest version which supports it. I assume it will be enabled by default at some point, but it isn’t yet in Firefox 58 (the current nightly).
Run this command:
echo MOZ_USE_XINPUT2=1 | sudo tee /etc/profile.d/use-xinput2.sh
Log out and back in.
Firefox should now use xinput 2.
(optional) Open Firefox and go to about:preferences -> Advanced (or about:preferences -> Browsing for Firefox Nightly), and uncheck “Use smooth scrolling”. This disables the old style “smooth scrolling”, which just causes an annoying delay when using xinput2 style scrolling imo.
On a separate note: it’s really encouraging to see Firefox finally become a great browser. Firefox 57 is looking to be an amazing release.
PSA for FreeBSD -CURRENT users: you can get that pixel precise scrolling too :)
Build the kernel with
options EVDEV_SUPPORT, setsysctl kern.evdev.rcpt_mask=12, buildxorg-serverwith udev support, installxf86-input-libinput, enjoy.Note that if you use xinput2 and synclient to reverse scrolling, it won’t be reversed. You have to remap the 4 5 buttons instead. Discovered this when chromium switched to xinput2 a while back. (Details fuzzy and subject to wrongness.)
(Looking again at my .xinitrc, I believe I did get the details backwards. You must use a negative scroll delta instead of remapping buttons.)
Just noticed a typo; it should be
echo export MOZ_USE_XINPUT2=1 | sudo tee /etc/profile.d/use-xinput2.sh. I can’t seem to edit the post.Heh. That’s why it’s better to write the actual content elsewhere and just link to it here ;-p