visual-studio-code

How to scroll without moving my cursor in Visual Studio Code from the Keyboard


I used to be able to scroll in Visual Studio 2015 using some keyboard shortcuts in Windows doing something like ctrlshiftdown. It would effectively behave like a line by line viewport bump that did not modify where my cursor was inserted at. This is much like how scrolling with a mouse wheel does not move the cursor except its achieved from the keyboard.

I can't figure out how to do this on Visual Studio Code on a Mac.


Solution

  • On my Mac Ctrl+fn+Up Arrow / Down Arrow works similar to mouse scroll. This doesn't affect the cursor position.

    2024 update: ctrl+page up/down, on MacOS (thanks @zzzgoo)