问题
In Visual Studio Code, is there any way to force the auto-scrolling option of the Output panel permanently enabled? At the moment I have to click on the lock button every time I build my project to disable the scroll lock or better to say enable the auto-scrolling feature and this is so annoying.
I took a look at the settings but couldn't find any relevant parameter there.
Any ideas?
回答1:
An option to turn off the smart scroll feature was included in one of the recent updates (probably in the March 2020 update, I didn't find it in the changelog), see more: issue #69480
Since then, I've been able to "save" the scroll state, try this:
- Go to File > Preferences > Settings (or Ctrl + ,)
- In Features > Output, disable Smart Scroll option (or search output.smartScroll.enabled)
Tested with VSCode version 1.45.1 and CodeRunner 0.10.0
Hope this works for you!
回答2:
Smart scrolling allows you to lock scrolling automatically when you click in the output view and unlocks when you click in the last line
So clicking on the last line will auto scroll to the last line. I made a habit of doing that. Of course disabling Smart Scrolling is the permanent solution.
来源:https://stackoverflow.com/questions/58855587/vscode-turn-auto-scrolling-permanently-on