Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ANSI control sequence ESC M uses incorrect default background color (Windows Console Host) #4182

Closed
12Me21 opened this issue Jan 11, 2020 · 3 comments
Labels
Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.

Comments

@12Me21
Copy link

12Me21 commented Jan 11, 2020

Environment

Microsoft Windows [Version 10.0.18362.535]

Steps to reproduce

Screen background is set to any color other than 0:
image

From bash in WSL:

clear
echo -e "\e[H\e[1T"

image
The control sequence ESC [ 1 T scrolls down 1 line, and fills the new line with the background color
image

clear
echo -e "\e[H\eM"

image
The control sequence ESC M also scrolls down 1 line, but uses color 0 instead of the background color
image

Applications like less, man, and vim all use ESC M for scrolling, and scrolling upwards causes new lines to be filled with the wrong background color:
image

ESC [ L (insert lines) appears to have the same problem.

Additionally, this only happens when the current background color is set to the default. otherwise, ESC M acts correctly (try inserting \e[41m after the H in the command)

Expected behavior

Both control sequences should have the same behavior

Actual behavior

ESC M uses color 0 instead of the default color, when the background color is set to the default

@ghost ghost added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Jan 11, 2020
@12Me21 12Me21 closed this as completed Jan 11, 2020
@12Me21 12Me21 reopened this Jan 11, 2020
@12Me21 12Me21 changed the title ANSI control sequence ESC M uses incorrect default background color ANSI control sequence ESC M uses incorrect default background color (Windows Console Host) Jan 11, 2020
@j4james
Copy link
Collaborator

j4james commented Jan 12, 2020

I believe this was fixed by PR #2987.

@zadjii-msft
Copy link
Member

This sure does look like that bug to me as well. Thanks for finding the dupe @j4james!

/dup #2702

@ghost
Copy link

ghost commented Jan 13, 2020

Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report!

@ghost ghost closed this as completed Jan 13, 2020
@ghost ghost added Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing. and removed Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Jan 13, 2020
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.
Projects
None yet
Development

No branches or pull requests

3 participants