Bug 70198

Summary: [Mac] "Smooth scrolling" is not very smooth with scroll wheel
Product: WebKit Reporter: jean peccoud <jeanpeccoud>
Component: WebKit2Assignee: Simon Fraser (smfr) <simon.fraser>
Status: NEW ---    
Severity: Normal CC: andersca, ap, bdakin, billdillensrevenge, sam, simon.fraser, thorton
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Mac (Intel)   
OS: OS X 10.7   
See Also: https://bugs.webkit.org/show_bug.cgi?id=228159

Description jean peccoud 2011-10-16 00:53:43 PDT
(first bug, I'm not sure if the section is appropriate)

When you enable Smooth Scrolling in the general system preferences, 3 things are supposed to change:
- clicking the scroll rail no longer makes the view jump, it moves gently
- same thing when you hit the space bar
- Scrolling with a standard scroll wheel gets smoother (I suppose it doesn't make a difference with the peculiar scroll ball of the mighty mouse).
The first 2 changes are implemented in Webkit, but no the latter. 
It's irritating to the eye. 


Steps to Reproduce:
Use a mouse with a standard scroll wheel (e.g. not a mighty mouse)
Enable smooth scrolling in the general system preferences
open a webpage in Safari (or the latest chrome), its content should not be entirely visible
Scroll with the scroll wheel

Expected Results:
Scrolling should be smoother than it is with smooth scrolling turned off

Actual Results:
Scrolling isn't smoother.

Regression:

Notes:
Mail and the App Store, both using webkit I believe, support smooth scrolling fully.
Comment 1 jean peccoud 2011-10-16 00:58:38 PDT
The issue can be reproduced with arrow keys instead of a scroll wheel.
Comment 2 jean peccoud 2011-10-17 12:22:49 PDT
Upon further examination, it may get a bit smoother with the arrow keys. It's still much less smooth than in Firefox or Opera.
Comment 3 Simon Fraser (smfr) 2021-12-04 15:24:51 PST
The plan for keyboard-driven scrolling is bug 228159. I'll repurpose this to focus on mouse wheel scrolling.
Comment 4 Will 2021-12-05 20:59:05 PST
Sorry for the long comment but I think the Webkit folks are taking a look at this now and I thought I should share some observations about smooth scrolling for notched mouse wheels that might be helpful.

Even though trackpad type scrolling is probably just overall the superior way of scrolling (or Magic Mouse scrolling, which I believe works the same way as a trackpad scrolling), a huge amount of people scroll with a notched mouse wheel and I really don't see that changing any time soon, so making it as good as it can be is definitely worth the extra effort.
 
Basically, smooth scrolling for notched mouse wheels isn't necessarily an improvement compared to "non-smooth" scrolling! For example, the notched mouse wheel smooth scrolling in Edge for Windows is just hard on the eyes and a bad experience compared to Chrome. I think the "impulse-style" scroll animation they're using in Edge might be to blame. Scrolling looks juddery/stuttery, and I'm pretty sure it's not because of any type of framerate issue (Chrome and Edge are both Chromium and Chrome doesn't have this problem). My guess is, when rolling another notch of the wheel interrupts a scroll animation that's already in progress, the scroll movement speed of the animations aren't the same, so you get this almost "micro" judder/stutter effect (fast/slow/fast/slow). It doesn't look smooth or natural.

On the other hand, scrolling in Chrome looks basically just as smooth as trackpad-style scrolling, even though I'm using a notched mouse wheel (at least on Windows it does. For whatever reason, using the exact same mouse in Chrome for macOS isn't as good as it is on Windows). I don't know exactly how the Chrome team have done this or how it all works, but the end result looks pretty similar to trackpad scrolling (and I say this as a person who's really sensitive to things like scrolling). This is quite a feat! If the Webkit team could do whatever Chrome for Windows is doing, that would be amazing and I think users would really appreciate it.
 
(I'm using a Logitech M325 mouse)
Comment 5 Will 2021-12-07 16:06:25 PST
Sorry for the double post but if you're looking to investigate these differences in smooth scrolling you should probably do it on a Windows computer too because Edge for macOS doesn't yet have that "impulse" scroll animation that I suspect is the reason it's mouse wheel scrolling is so awful on Windows (https://bugs.chromium.org/p/chromium/issues/detail?id=1076127). And also, like I said in the above post, for some reason scrolling in Chrome for macOS just isn't as smooth as it is in Chrome for Windows. It's honestly surprising just how smooth and excellent the mouse wheel smooth scrolling is in Chrome for Windows, I wonder if they're doing something special that somehow isn't in Edge
Comment 6 Will 2021-12-10 17:23:54 PST
And some helpful docs about Chromium's smooth scrolling I forgot to include in original post (we can see why Edge's mouse wheel smooth scrolling isn't actually smooth, but Chrome's is)
https://docs.google.com/document/d/1A3VmlY3ZR6UtJt3QQ5uuqaCOgPjV6vCMxvkpvPBe0g0/edit?usp=sharing
https://docs.google.com/document/d/1JQ6jLy-r7vw_I9s3rtWAIK137fMpF_OFVtfVsgOaoTA/edit?usp=sharing
https://docs.google.com/document/d/1ygLvYSnRprmgOcTlezdAEHls2v0NI3Q3UFwgsAu1ISE/edit?usp=sharing
Comment 7 Will 2022-01-27 13:49:35 PST
Sorry to comment yet again but since the new "ProMotion" Macbook Pro's were released a lot of people have been paying extra attention to scrolling and I've noticed a lot of people are saying Safari's scrolling isn't as smooth as Chrome's, but I suspect most of the people saying this are using a notched mouse wheel (and they are conflating browsers ProMotion support with smooth scrolling for notched mouse wheels). Just another good reason to bump this in priority. 

Also, apparently some animations in Safari are capped at 60 FPS even on "ProMotion" devices? Would this also be the case with this notched mouse wheel smooth scrolling? That would be a real shame because ProMotion could really help this type of smooth scrolling look and feel faster/smoother