6

I’m using Windows 10 for my current project after more than a decade on macOS / Linux. cmd seems to have come on a bit from Windows XP days, but I’m having one particular problem.

On macOS’s Terminal if I scroll back up to check something, when I want to go back I can fling the scroll in the other direction and it will stop at the end of the current text where the cursor is. If I do the same in Command Prompt it turns out there’s thousands of lines of blank text at the bottom beyond the cursor and I need to carefully scroll back through it to get back to the cursor. Typing something will refocus to the correct line, but only if there’s a cursor; if I’m running my test suite it waits for commands without dropping back to the shell, and won’t scroll to the correct point on typing.

I’ve been through the settings and can’t see anything obvious to change. Is there any way I can change the behaviour to match macOS’s Terminal, or am I going to have to relearn my muscle memory?

3 Answers 3

7

As of Windows 10 build 18298 and up you can go to properties and enable the "Disable Scroll-Forward" checkbox

Disable Scroll Forward in properties

Disable Scroll Forward:

When cleared (default state), the Console can to scroll anywhere within the Console’s buffer, even below the most recent row of text displayed When checked, the Console will not allow scrolling below the last line output, similar to how most *NIX terminals work

3
  • Thanks! Changed this to be the accepted answer. Apr 2, 2019 at 6:54
  • To get to this dialog box of "Command prompt properties" you have to right click on the top bar of the window.
    – bomben
    Jun 27, 2020 at 20:03
  • @Ben there are so many ways to access that dialog: left click on the icon on the top left, press Alt+Space or right click inside the console when quick edit mode is disabled
    – phuclv
    Jun 28, 2020 at 2:31
1

If you go to %AppData%\Roaming\Microsoft\Windows\Start Menu\Programs\System Tools, right click it go to properties, go to layout, change the Screen Buffer Size height to 12 or something that will do it.

5
  • Its still possible to scroll trough the prompt after applying this setting.
    – doenoe
    Dec 1, 2017 at 11:12
  • it is working for me did you change the window size or the screen buffer size?
    – user829537
    Dec 1, 2017 at 11:17
  • Changed to wrong setting, its working now.
    – doenoe
    Dec 1, 2017 at 11:28
  • 1
    So that seems to limit going back in history to 12 (or whatever) lines as well. I’m looking for a solution that lets me go far as far as I want (or at least within reason), but doesn’t have a load of blank lines past current prompt / end of text. Dec 1, 2017 at 12:29
  • You could try to put it at what you think you need or alternatively you might be able to use ">" with the commands like so: "ping 8.8.8.8 -n 500 > output.txt".
    – user829537
    Dec 1, 2017 at 12:51
1

You can't currently do this, however there's an open bug at Microsoft to fix it.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .