Scenario: ResizeWithReflow and related issues in Windows Terminal #5883

Closed
opened 2026-01-31 00:24:22 +00:00 by claunia · 5 comments
Owner

Originally created by @zadjii-msft on GitHub (Jan 13, 2020).

Originally assigned to: @zadjii-msft on GitHub.

The Terminal has a lot of problems resizing right now. I'm going to use this issue to try and track them all, and make sure we get holistic solutions.

  • #1465 Bug: resizing doesn't work properly in Windows Terminal (PR #4741)
    • This is "scrollback doesn't reflow on resize, it instead gets clamped/cut off"
    • Scrollback not rewrapped on resize #3491
  • #1245 linewrap then backspace produces unexpected visuals, missing characters
    • Generally related to linewrapping in the Terminal
    • Also related to the original #357
  • #3494 Maintain scrollbar position during resize
  • Closing a pane does not reset the PowerShell text position #2432
    • 3/17: I believe this is actually a PSReadline bug, so I'm removing it from this todo list

Bucket of horrible conpty resizing chaos

  • #3490 Flattening the window loses scrollback lines (PR #4354) (PR #4741)
    • This one has kinda spiraled out of control
    • #4771 Possibly a dupe? "Visual artefacts in splitted window"
  • MSYS2 bash: Cursor display doesn't follow arrow keys after running Emacs #2697
  • Bug Report Zooming causes the second line to act strange #2211
  • Curses programming: cursor handled incorrectly #4102
  • Emacs cursor displayed incorrectly #2642
  • Cursor position seems to be mispositioned when using WLS2 & git rebase #4644

Conpty needs to emit lines of text so that a terminal emulator can wrap them

  • MSFT:16485846 [conpty] Wrapped lines should not render a \r\n
    • And regression: MSFT:18123777: lines that are wrapped are also moved up by one row
    • I'm sure there's a GH issue that's the equivalent of that issue, but I haven't found it yet.
      • maybe "#405 Text Wrapping with ConPTY"
  • #3088 WSL Terminal Line Endings
    • This looks related - probably some combo of "conpty doesn't emit wrapped lines" and "Terminal doesn't mark lines as wrapped correctly"
    • 3/17: I no longer believe that this is part of the same ResizeWithReflow madness, and that this was instead a bug that's existed in conhost for a while now.
  • #3367 Make sure WT can copy wrapped lines as a single line

Bugs in the wake of #4741

  • #4955 Reflow with long input loses cursor
    • Turns out we couldn't repro this one.
  • #5029 Alt+Enter rendering error
  • #5178 Terminal background color has the wrong color applied when terminal is snapped
    • this was actually #3848, so we're punting it

Some alt-buffer things that we're punting till v1.x

  • #3492 Alternate screen shouldn't write to scrollback or normal screen
  • #3493 Consider not wrapping the alternate screen on resize
  • #381 ConPTY: pass through requests for the alt buffer
    • This is also #4676 Lines scrolled up by less command remain to exist after quitting the command
Originally created by @zadjii-msft on GitHub (Jan 13, 2020). Originally assigned to: @zadjii-msft on GitHub. The Terminal has a lot of problems resizing right now. I'm going to use this issue to try and track them all, and make sure we get holistic solutions. * [x] #1465 Bug: resizing doesn't work properly in Windows Terminal (PR #4741) - This is "scrollback doesn't reflow on resize, it instead gets clamped/cut off" - Scrollback not rewrapped on resize #3491 * [x] #1245 linewrap then backspace produces unexpected visuals, missing characters - Generally related to linewrapping in the Terminal - Also related to the original #357 * [x] #3494 Maintain scrollbar position during resize * Closing a pane does not reset the PowerShell text position #2432 - **3/17**: I believe this is actually a PSReadline bug, so I'm removing it from this todo list ## Bucket of horrible conpty resizing chaos * [x] #3490 Flattening the window loses scrollback lines ~~(PR #4354)~~ (PR #4741) - This one has kinda spiraled out of control - [x] #4771 Possibly a dupe? "Visual artefacts in splitted window" ## Conpty cursor visibility bugs, that aren't _actually_ related to resizing but found in the meantime * [x] MSYS2 bash: Cursor display doesn't follow arrow keys after running Emacs #2697 * [x] Bug Report Zooming causes the second line to act strange #2211 * [x] Curses programming: cursor handled incorrectly #4102 * [x] Emacs cursor displayed incorrectly #2642 * [x] Cursor position seems to be mispositioned when using WLS2 & git rebase #4644 ## Conpty needs to emit lines of text so that a terminal emulator can wrap them * [x] MSFT:16485846 \[conpty\] Wrapped lines should not render a \r\n - And regression: MSFT:18123777: lines that are wrapped are also moved up by one row - I'm sure there's a GH issue that's the equivalent of that issue, but I haven't found it yet. - maybe "#405 Text Wrapping with ConPTY" * #3088 WSL Terminal Line Endings - This looks related - probably some combo of "conpty doesn't emit wrapped lines" and "Terminal doesn't mark lines as wrapped correctly" - **3/17**: I no longer believe that this is part of the same ResizeWithReflow madness, and that this was instead a bug that's existed in conhost for a while now. * [x] #3367 Make sure WT can copy wrapped lines as a single line ## Bugs in the wake of #4741 * #4955 Reflow with long input loses cursor - Turns out we couldn't repro this one. * [x] #5029 Alt+Enter rendering error * #5178 Terminal background color has the wrong color applied when terminal is snapped - this was actually #3848, so we're punting it ## Some alt-buffer things that we're punting till v1.x * [ ] #3492 Alternate screen shouldn't write to scrollback or normal screen * [ ] #3493 Consider not wrapping the alternate screen on resize * [ ] #381 ConPTY: pass through requests for the alt buffer - This is also #4676 Lines scrolled up by `less` command remain to exist after quitting the command
Author
Owner

@ghost commented on GitHub (Jan 13, 2020):

Hi! Thanks for attempting to open an issue. Unfortunately, you didn't write anything in the body which makes it impossible to understand your concern. You are welcome to fix up the issue and try again by opening another issue with the body filled out.

@ghost commented on GitHub (Jan 13, 2020): Hi! Thanks for attempting to open an issue. Unfortunately, you didn't write anything in the body which makes it impossible to understand your concern. You are welcome to fix up the issue and try again by opening another issue with the body filled out.
Author
Owner

@zadjii-msft commented on GitHub (Jan 13, 2020):

(uhg fat-fingered the enter key. why did github even let me open a blank issue?)

@zadjii-msft commented on GitHub (Jan 13, 2020): (uhg fat-fingered the enter key. _why did github even let me open a blank issue_?)
Author
Owner

@miniksa commented on GitHub (Jan 13, 2020):

(uhg fat-fingered the enter key. why did github even let me open a blank issue?)

Shhh. No one saw that.

@miniksa commented on GitHub (Jan 13, 2020): > (uhg fat-fingered the enter key. _why did github even let me open a blank issue_?) Shhh. No one saw that.
Author
Owner

@riverar commented on GitHub (Feb 16, 2020):

I'm growing worried Terminal will reach 1.0 without this getting fixed. Please reassure me this will block 1.0 release!

@riverar commented on GitHub (Feb 16, 2020): I'm growing worried Terminal will reach 1.0 without this getting fixed. Please reassure me this will block 1.0 release!
Author
Owner

@zadjii-msft commented on GitHub (Apr 14, 2020):

With the majority of these bugs getting resolved in 0.10 and 0.11, I'm officially marking this one as complete.

The other linked issues were either

  • Related to resizing in the alt buffer, which the Terminal doesn't truly support in 1.0
  • Unrelated to the root problem of reflowing the Terminal buffer.

We'll still address those issues, but in a future release.

@zadjii-msft commented on GitHub (Apr 14, 2020): With the majority of these bugs getting resolved in 0.10 and 0.11, I'm officially marking this one as complete. The other linked issues were either * Related to resizing in the alt buffer, which the Terminal doesn't _truly_ support in 1.0 * Unrelated to the root problem of reflowing the Terminal buffer. We'll still address those issues, but in a future release.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#5883