Vertical cursor movement stops working when terminal runs out of vertical space #11185

Closed
opened 2026-01-31 02:40:58 +00:00 by claunia · 4 comments
Owner

Originally created by @patriksvensson on GitHub (Oct 27, 2020).

Environment

Windows build number: 10.0.19041.0
Windows Terminal version (if applicable): 1.3.2651.0

Steps to reproduce

  1. Open a new PowerShell terminal tab
  2. Make sure that there are plenty of vertical space available
  3. Run Write-Output "$([char]27)[5BHELLO WORLD"
  4. Notice the 5 empty lines before HELLO WORLD. All is fine.
  5. Continue running Write-Output "$([char]27)[5BHELLO WORLD" until you run out of vertical space

Expected behavior

I expect the 5 empty lines to continue showing (since we moved the cursor 5 lines down)

Actual behavior

The 5 empty lines are not shown, the cursor is not moved.

image

Originally created by @patriksvensson on GitHub (Oct 27, 2020). # Environment ```none Windows build number: 10.0.19041.0 Windows Terminal version (if applicable): 1.3.2651.0 ``` # Steps to reproduce 1. Open a new PowerShell terminal tab 2. Make sure that there are plenty of vertical space available 3. Run `Write-Output "$([char]27)[5BHELLO WORLD"` 4. Notice the 5 empty lines before `HELLO WORLD`. All is fine. 5. Continue running `Write-Output "$([char]27)[5BHELLO WORLD"` until you run out of vertical space # Expected behavior I expect the 5 empty lines to continue showing (since we moved the cursor 5 lines down) # Actual behavior The 5 empty lines are not shown, the cursor is not moved. <!-- What's actually happening? --> ![image](https://user-images.githubusercontent.com/357872/97360263-3e0ef880-189e-11eb-81f0-7775e382580e.png)
claunia added the Issue-QuestionNeeds-Tag-FixResolution-Answered labels 2026-01-31 02:40:58 +00:00
Author
Owner

@DHowett commented on GitHub (Oct 27, 2020):

CUD—Cursor Down
This control function moves the cursor down a specified number of lines in the same column. The cursor stops at the bottom margin. If the cursor is already below the bottom margin, then the cursor stops at the bottom line.

@DHowett commented on GitHub (Oct 27, 2020): > CUD—Cursor Down > This control function moves the cursor down a specified number of lines in the same column. **The cursor stops at the bottom margin. If the cursor is already below the bottom margin, then the cursor stops at the bottom line.**
Author
Owner

@DHowett commented on GitHub (Oct 27, 2020):

(per https://vt100.net/docs/vt510-rm/CUD.html)

@DHowett commented on GitHub (Oct 27, 2020): (per https://vt100.net/docs/vt510-rm/CUD.html)
Author
Owner

@zadjii-msft commented on GitHub (Oct 27, 2020):

I'm pretty sure that's exactly how the cursor up/down/left/right sequences work - they're constrained by the size of the Terminal viewport. @j4james sanity check me?

EDIT: That's like the 3rd time in as many days that Dustin's sniped me

@zadjii-msft commented on GitHub (Oct 27, 2020): I'm pretty sure that's exactly how the cursor up/down/left/right sequences work - they're constrained by the size of the Terminal viewport. @j4james sanity check me? EDIT: That's like the 3rd time in as many days that Dustin's sniped me
Author
Owner

@patriksvensson commented on GitHub (Oct 27, 2020):

Ok, my bad. I misunderstood how it was supposed to work. Thank you for the explanation.

@patriksvensson commented on GitHub (Oct 27, 2020): Ok, my bad. I misunderstood how it was supposed to work. Thank you for the explanation.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#11185