vscode-autoScroll icon indicating copy to clipboard operation
vscode-autoScroll copied to clipboard

Would Be Useful to Only Auto Scroll When At The Bottom Of The File

Open DougChandler opened this issue 2 years ago • 3 comments

A suggestion: If you are watching a log file and want to scroll up to see some of the history, you have to disable AS then go up. It would be very useful to only Auto-Scroll when viewing the end of the file, i.e. if I scroll up and not viewing the end of the file, don't auto-scroll, but then when I want to continue, ctrl+end to go to the bottom and then auto-scroll again... I've seen this in other software, can't remember which as it was some time ago, but it would be very useful.

DougChandler avatar Dec 22 '22 16:12 DougChandler

That is a great suggestion, I'm open to a PR for that. it must be a straightforward implementation with VsCode SelectionChange events.

PejmanNik avatar Dec 24 '22 14:12 PejmanNik

Came here to mention I want this feature as well..

Hipska avatar Mar 28 '24 10:03 Hipska

And checking if user manually scrolled up:

const isScrolledToBottom = elContainer.scrollTop === (elContainer.scrollHeight - elContainer.offsetHeight)

(don't really need onscroll event handler)

vanowm avatar Jun 02 '24 15:06 vanowm