Vscode: 1.36 scrolling suddenly laggy - precision touchpads

Created on 4 Jul 2019  路  65Comments  路  Source: microsoft/vscode

Since updating to 1.36 the scrolling experience got bad.
I increased the multiplier to have the same speed, but it still feels "heavy" to scroll, not the same as before - what change could be the cause for this?

Same in the explorer view (with or without the new guides).
Here it looks like the renderer skips frames, jumpy and not calm (also the scroll multiplier does not seem to have an effect here, merely Alt).

I'm using a precision touchpad device (Dell) but this is not the old problem and cannot be solved by resizing the window.

It is especially annoying in the explorer tree, bordering close to the unusable level.
After trying for a while I will now downgrade to 1.35.x. This seamingly little handicap somehow greatly impacts productivity, at least for me, feels like having a slow computer.

Update: Yes, 1.35.1 is definitely faster and lighter to scroll (did you add some animation? my setting for 'smooth scrolling' is deactivated). I will have to stay on this version until this is fixed.

Cannot find anything in the release notes except "This is a major Electron release and comes with Chrome 69 and Node.js 10.11.0 (a major leap forward from our current version with Chrome 66 and Node.js 10.2.0)". I guess it won't be easy to locate the issue. However, the new version is not usable, for me (Windows 10, precision touchpad).

electron electron-4-update trackpascroll upstream windows

Most helpful comment

After updating Windows to version 2004 and updating VSCode to 1.49, scrolling lags also started. On version 1.48 everything is fine. I managed to defeat them by running VSCode as administrator. If you run VSCode without administrator rights, the lags will return. Maybe this method will help someone.

All 65 comments

I have the exact same problem!
It was fine before i update it to 1.36

I've started experiencing the same issue after the latest update.

I have always had editor.smoothScrolling: false, but after the update yesterday it doesn't really change anything... Be it true or false - no difference.

Wait, does anyone here have editor.smoothScrolling: true and now it is not smooth anymore or is it just not smooth anymore in general?

Is it only not smooth in the editor, or also on trees in the sidebar?

For me, it鈥檚 everywhere: editor, sidebar, settings.

@aloeugene what exact device and OS is that?

@bpasero It's everywhere. I have tried toggling editor.smoothScrolling but it has same results.

Device : Surface Laptop 2 - Intel Core i5-8250U
OS : Windows 10 Home - 64bit (With Windows Precision Touchpad)

smoothScrolling also doesn't have any noticeable difference for me, neither in 1.35.1 nor 1.36.
OS: Windows 10 Pro for Workstations
CPU: Intel Xeon E3-1505M v6 3GHz, 32 GB RAM, Precision Touchpad.

I didn't try using a mouse when I had 1.36 installed and can currently not verify it without updating again. Can somebody currently running 1.36 confirm that the issue persists when using an external mouse to scroll and has thus nothing to do with the precision touchpad device?
Then it can only be the new Chrome renderer or new Electron or new Node, granted, not an easy task to find the issue. If I can help testing things in case you cannot reproduce the effects, let me know.

Hm, now I just updated to 1.36 again and it looks smoother than yesterday (no frame-skipping, although I didn't restart or change anything), but definitely at first glance it is much slower (smooth but very heavy to scroll, a full swipe gets me a few animated centimeters far, not a screen as i used to. The precision touchpad always scrolls smooth, the external mouse does not (only when switching on smooth scrolling), but i guess that's alright, given that the mouse wheel scrolls are measured in lines.

I made videos (though they cannot capture the real 60fps+ experience one clearly sees and feels that 1.35.1 is light to scroll and 1.36 is heavy).
I made three short swipes and three long swipes in both directions, in the code editor, the explorer view and the settings window, compare how 1.36 is long and animated and hard to control, and the explorer view flickers (irrespective of the tooltip):
https://www.dropbox.com/s/zttomzencx8oz8m/vsc-precision-touchpad-v1.35.1.mp4?dl=1
https://www.dropbox.com/s/o3teeqtbcjwago2/vsc-precision-touchpad-v1.36.mp4?dl=1

I also used an external mouse wheel, here I don't see a difference at first glance, but then I never work with an external mouse.
https://www.dropbox.com/s/384kth1podeymie/vsc-wheel-v1.35.1.mp4?dl=1
https://www.dropbox.com/s/gw8fjlh20htxf8u/vsc-wheel-v-1.36.mp4?dl=1

Alright, I guess I can live with that now as it is, if I adjust the 'Mouse Wheel Scroll Sensitivity' to about 3x.
The long animation is a little annoying, but I will get used to it, apparently something changed in Chrome with respect to precision touchpads in a newer version. The explorer view is terribly slow to scroll because it does not care for the sensitivity setting, but workable (don't know why but yesterday it was not usable at all, I wonder what's different now, since I did not restart or update or even close anything, also no difference whether on battery or charging). So from my perspective it's does no longer look like a slower rendering with frame-skipping, but just more animation and different behaviour. I don't know about @yo-raff and @aloeugene, try installing 1.35.1 and again updating to 1.36, maybe that helps.

By this old page, chrome added support for precision touchpads with v68, if I read that right:
https://www.reddit.com/r/chrome/comments/98zglr/when_is_precision_touchpad_support_coming/
So if VSC now switched from v66 to v69, this would explain why there is a sudden change in scroll experience. maybe it can be tuned (and maybe it should be tested on laptops with such a touchpad, since that's the primary input device for most users having a Dell Precision/XPS or Microsoft Surface Laptops. According to this page (https://www.howtogeek.com/286905/what-is-a-precision-touchpad-on-windows-pcs/) it soon will be every Windows machine.

@bpasero, I鈥檓 currently on HP EliteBook 840 G4 with Intel core i5 7th gen, 16gb RAM. Windows 10 Enterprise.

Also, I鈥檓 always using touchpad, and it's the precision one, so I can鈥檛 say if this issue relates to mouse scrolling as well.

@frevds @yo-raff @aloeugene We are building exploration builds that use a much newer version of our UI framework (Electron version 6.0.x). I wonder if this issue reproduces with one of these builds, could you try? Download:

@bpasero, as for me on Windows, switching on/off smoothScrolling still doesn't change anything, scroll is always smooth.

However, it's not that laggy anymore, quite stable and is really smooth 馃槂

Actually, with smoothScrolling off, it's fine and cool. But when it's on, it becomes more laggy and twitchy.

Please do not configure the editor.smoothScrolling setting and try it outside the editor, I am only concerned about scrolling in general. Does Electron 6 improve things?

Well, it doesn't really change things for me.
Somehow, stable VSC build is behaving the same as Exploration build.

1.37 looks identical to me with respect to the scrolling behaviour, BUT it is very smooth (no skipping, no latency, generally usable). Just it is very animated (cannot be deactivated and scrolls out very long after letting go). Without setting the scroll sensitivity multiplicator it is too slow by default.
Also, the explorer view ignores the multiplicator and scrolls way too slow to use (only holding Alt helps).

@bpasero the new build has better animation when scrolling (smoother) than 1.36, but it's still worse than 1.35.1

the scrolling speed is too slow in 1.37 (new build) compared to 1.35.1 (both has same setting)

One more thing that happened to me couple times already, but I haven't really found steps to reproduce:
Sometimes scrolling with touchpad in editor just stops working. Scrolling with "pg up/down" buttons works, but not with two-finger scrolling. However, I still could easily scroll through sidebar menu...
Strange stuff's going on with this version.

And I do have frequent freezes with this version which I didn't have before, might have to do with code highlighting changes and long lines. Comes in arbitrary intervals and lasts as long as 3 seconds, complete main-thread blocks for a while.

I'm experiencing the same problems with VSCode 1.36.1 on Windows 10 1903 with Precision Trackpad hardware. What's bizarre is how just while typing this the scrolling has returned to normal. Although I switched Smooth Scrolling on and off, it didn't do anything in particular at the beginning. Now, with the option on I am working smoothly with short scripts, while anything over 100 lines is struggling to keep up.

My personal guess is Python Language Server, and the extreme CPU consumption when opening large projects, might contribute to the first extreme lag I notice. Testing with a short C# project seems to give positive results, without the CPU and memory hang.

Any updates regarding this issue?

2 finger touchpad scrolling on my Dell Precision randomly stops working. It just started happening recently, but I'm not sure which update did it. I'm running 1.36.1 on Windows 10 Pro build 1809. It has happened to me 4 times today, and the only thing that fixes it is to quit vscode and restart. I haven't made any changes to any scroll settings ever, so I believe I should be running all the defaults.

Any news? Such behavior is really annoying...
After couple hours in Atom it's very hard to return back to VSC with scrolling issues :)

Hi everyone!
Are there any updates? Is it going to be fixed somehow someday?

I will backport fixes from https://bugs.chromium.org/p/chromium/issues/detail?id=914914 into our electron 6 branch update https://github.com/microsoft/vscode/pull/81644 to see if there is any improvement. Will move on from there.

@frevds @yo-raff @aloeugene

Can you please try out our insiders build -- https://code.visualstudio.com/insiders/ -- and let us know if scrolling with the touchpad is working better?

@alexandrudima Hm no, exactly the same I would say, but I got used to it (the explorer tree is very slow and needs Alt to be pressed because it keeps ignoring the scroll multiplier, and the code view scrolls fine with the multiplier but has to be stopped since it will graciously and slowly scroll out over another screen height). The new electron versions don't solve the issue, I reckon it's a chrome issue with Precision Touchpads where you cannot do much. It's not bad, it's just not as good as before.

Yep, as @frevds said, it's exactly the same for me too. It's a shame scroll multiplier doesn't work for explorer tree, would be handy not to touch Alt key every time I try to find something :)
But it's true, you're just getting used to it and live with it... Scroll multiplier saves the situation for code editor, but it feels more like a workaround, not a solution.

Have the same issue here. Scrolling is jumpy, laggy, and all scroll events spike CPU usage to 40%. Past workarounds do not help (full screen mode). I'm having to set my laptop to "High performance Mode" for it to scroll better 馃槀.

@alexandrudima I'm not sure if it's the same problem, but I can easily reproduce the problem in the [email protected] on Chrome and MacOS 10.15 (Catalina).

Steps to reproduce:

Got to the playground: https://microsoft.github.io/monaco-editor/playground.html

Paste the following snippet and hit Run:

monaco.editor.create(document.getElementById("container"), {
    value: "function hello() {\n\talert('Hello world!');\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n}",
    language: "javascript",
    smoothScrolling: true
});

Try to scroll the editor, it won't be smooth. Using page-up and page-down to scroll will result in a smooth scrolling animation though.

Any updates on this? We're a few months further and it's still not resolved in 1.40.2. It a pretty annoying problem to deal with, when not using a mouse.

Firefox is completely responsive and super snappy. Even through my TV which has a pretty noticable input lag. On my main screen, with much lower input lag, VScode manages to lag so much that it's making me uneasy. I already have problem with scrolling, and lag is making it worse.

If this cannot be solved as part of performance improvements, it should be fixed as an accessibility problem. A code editor should not make a person literally sick.

@thany @alexdima

I can confirm this is still the case in 1.42.1, on macOS Catalina. I have more useful information, though: it appears to be tied to a (roughly) 5 second timeout. I noticed this because I have keyboard backlight auto-dim to 5 seconds, and trackpad activity wakes it up. This means it is visually easy to tell if it has been less than or more than 5 seconds since the last trackpad activity.

If i got into a text editor view, and use rapid two-finger scroll to bounce up and down a bit, and then wait for the keyboard to dim out, and do the two-finger dance again, it completely ignores that input for about 1 second, and then catches up. This is incredibly distracting and annoying, because it breaks the fundamental illusion that I can move the editor window around with my two fingers as if it was a piece of paper. But if I wait slightly less than five seconds: no problem.

So to clarify, the bug I can reproducibly see, and probably anyone with a mac can see, is scrolling jank after 5 seconds of inactivity. I would guess this is some kind of throttling of UI polling frequency that happens after 5 seconds to save battery life.

To turn on the auto-dim feature to help reproduce this bug: System Preferences > Keyboard > Keyboard pane > check "Turn keyboard backlight off after [ 5 seconds ] of inactivity".

@taliesinb Your issue is completely different. First of all, you're on macOS, so I pretty much guarantee you will not be using a Precision touchpad (and if you are, why??)

The lag has nothing to do with waking up. It's always there.

Even if the issue you described is what we're having, it would mean it's laggy in every application. But it's actually completely snappy and working perfectly everywhere. Except in VScode where is nauseatingly laggy.

Version: 1.43.2

i'm using macOS and vscode scrolling is even laggy more than pycharm now.
editor.smoothScrolling: false doesn't work

version 1.44.2
Fedora 31
Thinkpad L470 (Synaptics touchpad)
same jumpy scrolling, turning the option off or on has no effect.

_update:_
version 1.45
Fedora 32

Tried purging vscode completely before installing the new 1.45 update, but no luck.
What's interesting though is that scrolling is smooth on release notes page, but lags on every other source file, even with bare vscode before installing any extensions.

Yep, still the same in 1.44.2 and in the Insiders build 1.45 (commit 9328b320).

I wasn't exaggerating when I said nauseatingly laggy. I'm sensitive to input not matching up with the things I'm seeing on screen. Smooth scroll (by a "ticky" scrollwheel, when I can use a mouse) is therefor disabled. I really can't handle that 馃あ

Can anyone explain why this is not being worked on? Perhaps it's being brushed off internally, but it really is a problem in VScode. No other app has this problem.

Version: 1.44.2
OSX version: 10.15.4

Just moved from sublime text to vs code.
The scrolling lag is terrible.
I can see the obvious losing frames in vs code compared with sublime text.
Not working by setting smooth scrolling true or false.

Update:
Vscode is not as smooth as sublime in my ubuntu desktop, neither.

Version 1.44.2
Windows 10

Same scrolling stutter.

I'm also experiencing this in version 1.44.2 on Windows 10 1909 on a laptop with a precision touchpad. The issue is super anoying and the editor is really uncomfortable to use because of it. No other electron app I use (Notion and Slack) has this issue, so the root cause might not be in chromium/electron itself.

Same scrolling stutter.

Stutter? It's not stuttering for me. It's smooth as butter, but also lagging behind.

Suddenly a very noticeable issue after upgrading to Windows 10 2004.
VSC: 1.49.0-insider 2020-08-28

Lately scrolling or typing experience became very laggy for me, to the point where I had to move to the WebStorm until it's fixed.

My setup is:

Version: 1.49.1 (user setup)
Commit: 58bb7b2331731bf72587010e943852e13e6fd3cf
Date: 2020-09-16T23:27:51.792Z
Electron: 9.2.1
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Windows_NT x64 10.0.18363

Here is a preview of what it looks like, recorded at 30FPS (open image in new tab for better resolution).
Got all my extensions disabled, tested on plaintext tab to exclude potential issues. It's quite laggy, but one might live with that.
noextensions
It's just as laggy as with the extensions enabled
regular

However, when a file has long lines (the horizontal scrollbar appears), it gets really bad. The text is from https://loremipsum.io/ (took 10 paragraphs).

longlines

@lvkins Interesting, but I can't reproduce that (copied 4x 10 paragraphs). I have much bigger files with actual code highlighting (10000 lines and all quite long) without issues. Sure you have all extensions deactivated (what is this on the left in your status bar, i don't seem to have it) and your computer is not in any battery-saving mode (with the old version of VSCode there is no issue?)?
In any way, you should post this as a separate issue, since this issue here is more about Precision Touchpad scrolling lags and overanimation than text highlighting (you want to do that since nobody hears us here anyway; this ticket has been open for months (since v1.36) and nobody feels responsible and/or capable to solve it).

@frevds Extensions are disabled in the first GIF. It made no difference if I disabled them whatsoever so I decided to keep them turned on. The issue seem to be the VSCode itself. I had an old, bare version of VSCode Insiders that was v1.39 - no such issue there, with 1000s of lines... then I updated to the latest insiders v1.50 and the slideshow has started.

I'm aware that your issue is quite different. Will indeed open my own but looking at your case makes me think it's really a waste of time.

@lvkins You should pinpoint the exact version when things went wrong then. The older versions can all be downloaded. Our issue here is not easily fixed since it seems to involve Chrome itself, not Electron and not VSCode. Your issue however seems to be linked to processing syntax hilighting. Also check on other computers. I don't see bad performance when I try out your example.

@frevds What makes you think it's linked to syntax highlighting? I tested it on neutral, plaintext tab (i.e. no syntax highlight) in order to /among others/ - ensure it's not.

@lvkins Yes, not exactly syntax but the broader topic of line processing. There is a lot going on, especially with extensions and there has been done a lot and changed a lot since your v1.39. It would probably be benefitial to find out when things went wrong, i.e. which new feature or change causes this, which you can find out by installing older versions and then looking at their release notes when you notice differences. Reproducing the issue is not so easy either, hence you could be in a unique position to find the issue and they could improve on your feedback.

Having exactly the same issue on the latest 1.49.1 version.

Scrolling with the touchpad is very slow and keeps on scrolling after I take my fingers off the touchpad. Very annoying.

Version details:

Version 1.49.1 (user setup)
Electron: 9.2.1
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Windows_NT x64 10.0.19041

Should've probably built VScode on the Gecko engine 馃槑 because scrolling by Precision Touchpad in Firefox is absolutely realtime and buttery smooth. I don't use Chrome (the browser, that is) so I can't speak for that one.

I'm using vscode on linux but on a VM that I connect to remotely with x2go. Scrolling in chrome, even inside remote desktop to another windows (for internet - no internet on VM itself) is totally fine. Eclipse also totally fine on same machine, same code. Scrolling with the mousewheel or dragging the scrollbar is very slow in vscode.

Exactly the same issue - VSC is great but scrolling is horrible!!! I'm pretty sure it wasn't like that a while ago, I would have definitely noticed it as it's really annoying. Thanks in advance for looking into this. Windows 10 on ASUS Zenbook Pro - latest version of VSC.

PS: Disabling all extensions doesn't help in any way with this.

I have just done some testing with default settings and here are my findings - it mostly comes down to extensions and one specific scroll setting: editor.mouseWheelScrollSensitivity This setting made a huge difference in the overall perception of scrolling speed and fluidity (choppiness/sluggishness) for me - scrolling was butter smooth with defaults and all extensions disabled. After re-enabling user settings and extensions it is slightly worse but still very workable after changing this setting. Also, no longer do I notice the stuttery motion now so I hope it stays that way.

After updating Windows to version 2004 and updating VSCode to 1.49, scrolling lags also started. On version 1.48 everything is fine. I managed to defeat them by running VSCode as administrator. If you run VSCode without administrator rights, the lags will return. Maybe this method will help someone.

@mrtrashmind your suggestion for running as administrator worked! It's very smooth now. But it's a bit annoying to run as administrator all the time... Hope they fix this soon.

Version Details:

Version 1.49.1 (user setup)
Electron: 9.2.1
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Windows_NT x64 10.0.19041

Dell Inspiron 7460 with Precision Touchpad
i5 7200u 16gb RAM

Well, the original issue has nothing to do with extensions and also does not vanish in administrator mode. VSC is skipping frames (scrolling less smoothly than it could) and overscrolls (pushing once on the pad just scrolls on and on, pretty useless, one mustn't let go when scrolling). This behaviour is pretty much the same as scrolling in the Chrome browser. It used to be worse so one can work with it. But prior to 1.36 is used to be better. Hard to describe. One-push scroll was more rigid and the overall refresh rate was higher so everything felt much more fluent. I posted some videos up there (which due to the fps limitations don't show the true effects but give some idea).

This is a truly awful user experience now. Reviewing/searching 20k line log files with long lines is a 3fps task. Someone please shoot a flare in the air and promote this to high priority. For an example of what good looks like please look at the speed of EmEditor.

Running as administrator fixed this for me.

Run as administrator did reduce the lag but not entirely solve the problem since it is still persist

Edit
Running without administrator mode and disabling PHP Intelephense extension did solve the issue for me just in case that I am doing a code in PHP, the issue still persist when opening js and html scripts

Can not run as administrator on Linux. (Well could but that's bad practice).

For users that are running as administrator to fix the issue, its unrelated to this issue. What you are seeing is https://github.com/microsoft/vscode/issues/107016 and the current workaround is to launch with --disable-renderer-accessibility, please follow that issue for updates.

--disable-renderer-accessibility

This doesn't help for me.

Can not run as administrator on Linux. (Well could but that's bad practice).

It's bad practice on every OS 馃榾

Issue re-appeared after my previous comment about having solved it.

--disable-renderer-accessibility

I confirm this has resolved the scrolling issue for me now as well. 馃

Version: 1.50.1 (user setup)
Commit: d2e414d9e4239a252d1ab117bd7067f125afd80a
Date: 2020-10-13T15:06:15.712Z
Electron: 9.2.1
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Windows_NT x64 10.0.19041

Thank you!

Running as administrator on Windows helps.

Both fixes are workarounds, so this still needs a proper solution. Both fixes may help (whatever that means) for some, but do jack all for someone else. Fact of the matter is that scrolling is lag-free in virtually every program, except VScode. And in those program, no such workaround is needed.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mrkiley picture mrkiley  路  3Comments

sijad picture sijad  路  3Comments

chrisdias picture chrisdias  路  3Comments

VitorLuizC picture VitorLuizC  路  3Comments

biij5698 picture biij5698  路  3Comments