Skip to content
This repository has been archived by the owner on Mar 3, 2023. It is now read-only.

Precision scrolling on Linux with Wayland #18592

Closed
1 task done
ssfrr opened this issue Dec 17, 2018 · 3 comments
Closed
1 task done

Precision scrolling on Linux with Wayland #18592

ssfrr opened this issue Dec 17, 2018 · 3 comments
Labels
linux Issues that occur on Linux but not on other platforms. stale

Comments

@ssfrr
Copy link

ssfrr commented Dec 17, 2018

Prerequisites

Description

First to clarify some definitions that often get conflated:

  • smooth scrolling - adding animated transitions between scroll positions to smooth out the document motion. This is usually the best you can do with mouse wheels, which themselves usually have fixed rotation increments.
  • Precision scrolling - touchpads can provide scroll events that are tied directly to your finger position, so the user has continuous control of the document position. This is also sometimes called "pixel-perfect" scrolling (but that seems like a misnomer to me because there isn't a 1-to-1 mapping from touchpad pixels to screen pixels, and AFAICT scroll events are reported as floating-point values).

This issue is about precision scrolling, not smooth scrolling.

There's an issue that's mostly focused on "smooth scrolling", but I wanted to try to extract the precision scrolling, which is a separate issue.

In this comment @damianmoore says that precision scrolling is working on Linux but that he hasn't tested Wayland. I'm using Wayland and it does not seem to be working.

If you're interested in how Wayland / GTK handle scroll events I did a pretty deep dive here. Not sure how much is relevant to Atom though.

Steps to Reproduce

  1. Set up a linux machine with Gnome-Shell / Wayland (I'm using Arch Linux)
  2. Install atom
  3. scroll a document with a touchpad

Expected behavior: scrolling should precisely follow my fingers

Actual behavior: document scrolls in fixed step sizes

Reproduces how often: 100%

Versions

$ atom --version
Atom    : 1.33.0
Electron: 3.0.11
Chrome  : 66.0.3359.181
Node    : 10.2.0

Wayland 1.16.0
Gnome-shell 3.30.2

@rsese
Copy link
Contributor

rsese commented Mar 20, 2019

Just looking through some issues that haven't had a reply yet - thanks for the definitions for precision vs. smooth scrolling, it's not something I pay much attention to to be honest but I know others do 👍

One initial comment though:

Atom : 1.33.0
Electron: 3.0.11

Based on this version information, we can see that you're currently using an unofficial build or distribution of Atom (i.e. the current release version of Atom, 1.35.1 is on Electron. Often these customized versions of Atom are modified versions of the Stable branch of Atom with mismatched versions of built-in components. These updated components are taken from the Beta channel or master branch and then injected into the Stable version and a new Atom package is generated. Because of the way Atom is constructed, using these mismatched components can cause mysterious and hard-to-diagnose problems. You can find out more about why we chose to not support unofficial distributions here.

I believe on Arch people have mentioned that the atom-editor-bin package from the AUR at least uses the correct Electron version - does using this version make any difference?

@rsese rsese added linux Issues that occur on Linux but not on other platforms. more-information-needed labels Mar 20, 2019
@ssfrr
Copy link
Author

ssfrr commented Mar 21, 2019

Thanks for the extra info, that's totally reasonable.

I installed using the AUR as you recommended and am still not seeing precision scrolling, the scroll jumps by discrete increments.

Here are my current versions:

Atom    : 1.35.1
Electron: 2.0.18
Chrome  : 61.0.3163.100
Node    : 8.9.3

@stale
Copy link

stale bot commented Mar 20, 2020

Thanks for your contribution!

This issue has been automatically marked as stale because it has not had recent activity. Because the Atom team treats their issues as their backlog, stale issues are closed. If you would like this issue to remain open:

  1. Verify that you can still reproduce the issue in the latest version of Atom
  2. Comment that the issue is still reproducible and include:
    • What version of Atom you reproduced the issue on
    • What OS and version you reproduced the issue on
    • What steps you followed to reproduce the issue

Issues that are labeled as triaged will not be automatically marked as stale.

@stale stale bot added the stale label Mar 20, 2020
@stale stale bot closed this as completed Apr 3, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
linux Issues that occur on Linux but not on other platforms. stale
Projects
None yet
Development

No branches or pull requests

2 participants