ANSI double-height 2️⃣ lines line-wrap several columns too early #22536

Open
opened 2026-01-31 08:16:06 +00:00 by claunia · 0 comments
Owner

Originally created by @ClaireCJS on GitHub (Nov 12, 2024).

Windows Terminal version

1.21.2911.0

Windows build number

10.0.19045.5011

Other Software

TCC command line 31.01.15 x64

Steps to reproduce

First off, I don't know how to change my cmd.exe profile in WT to make ANSI render in CMD, so i can only make this bug happen in TCC.
If someone can tell me how to get CMD to render ANSI, i could reproduce this in CMD.

set BIG_TOP=%@char[27]#3
set BIG_BOT=%@char[27]#4
set message=foo bar baz hello world
echo %BIG_TOP%%message%  %+  echo %BIG_BOT%%message%

^ This displays double-height message:
Image

The bug manifestation depends on how many columns you have in your terminal, so it has to be "found" by repeating this:

set message=%message% 1234567890
echo %BIG_TOP%%message% ^ echo %BIG_BOT%%message%

Image

Eventually, the bug will manifest once you've reached what i call "The cursed column".
(It's a column near the last column, but not the last column, and the offset seems to change based on # of columns)

Image

Basically, there exists a message length such that a blank line occurs PRIOR to reaching the last column, and it happens at a specific column.
One column less, and it doesn't happen. Here is an example of me adding one character to a message ("!") to manifest the bug:

![Image](https://github.com/user-attachments/assets/998d22d2-a786-4e ]6d-8593-d1c88940312d)

[ Now honestly, this may be a TCC bug. But if it is, how can I explain it to them in a way they will understand and accept? They're a bit stubborn over there. They've been in their own non-windows-terminal world for almost 40 years and aren't as deep into it as me. ]

Expected Behavior

For the line to not actually wrap into a blank line unless we actually manage to get our cursor past the end of the line, which was not happening here :)

Actual Behavior

See above.

Originally created by @ClaireCJS on GitHub (Nov 12, 2024). ### Windows Terminal version 1.21.2911.0 ### Windows build number 10.0.19045.5011 ### Other Software TCC command line 31.01.15 x64 ### Steps to reproduce First off, I don't know how to change my cmd.exe profile in WT to make ANSI render in CMD, so i can only make this bug happen in TCC. If someone can tell me how to get CMD to render ANSI, i could reproduce this in CMD. ``` set BIG_TOP=%@char[27]#3 set BIG_BOT=%@char[27]#4 set message=foo bar baz hello world echo %BIG_TOP%%message% %+ echo %BIG_BOT%%message% ``` ^ This displays double-height message: ![Image](https://github.com/user-attachments/assets/e8479b1f-259a-45a9-8988-5dda2d5701dd) The bug manifestation depends on how many columns you have in your terminal, so it has to be "found" by repeating this: ``` set message=%message% 1234567890 echo %BIG_TOP%%message% ^ echo %BIG_BOT%%message% ``` ![Image](https://github.com/user-attachments/assets/df4eb6fb-cbe4-4849-ba23-3eb9b0d27c02) Eventually, the bug will manifest once you've reached what i call "The cursed column". (It's a column near the last column, but not the last column, and the offset seems to change based on # of columns) ![Image](https://github.com/user-attachments/assets/97ae290d-045c-40c0-b2e7-0e3a9ce456e4) Basically, there exists a message length such that a blank line occurs PRIOR to reaching the last column, and it happens at a _specific_ column. One column less, and it doesn't happen. Here is an example of me adding one character to a message ("!") to manifest the bug: ![Image](https://github.com/user-attachments/assets/998d22d2-a786-4e ]6d-8593-d1c88940312d) [ Now honestly, this may be a TCC bug. But if it is, how can I explain it to them in a way they will understand and accept? They're a bit stubborn over there. They've been in their own non-windows-terminal world for almost 40 years and aren't as deep into it as me. ] ### Expected Behavior For the line to not actually wrap into a blank line unless we actually manage to get our cursor past the end of the line, which was not happening here :) ### Actual Behavior See above.
claunia added the Needs-TriageIssue-Bug labels 2026-01-31 08:16:06 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#22536