-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
Saving/restoring character attributes (and DECSCNM)? #8913
Comments
Huh. Could be two things:
I bet we could write a test for this fairly easily... |
I'm using reading/filling attributes for the whole viewport, all at once (specifically reading/filling every cell, or so I thought). Are you saying that, even so, what you described is happening in each row? |
I think I know what this is. When I added the At the time, @DHowett and I decided it was a fairly obscure edge case, so we thought we could leave it broken and probably nobody would notice. It seems we were wrong. 😄 |
Oh gosh, you're totally right. I'm also willing to call this P3 and say "DECSCNM's most common use is visual belling, so if it happens to look funny for a small number of milliseconds it's okay." 😄 |
Do you really think so? I see there's a PR about flashing the pane on BEL. Will it use the same inversion as DECSCNM? That can get pretty hideous looking, especially if there's colored text (and those colors may be auto-extended to EOL on the inverted screen). Negative feedback wouldn't surprise me. |
We've explicitly designed the visual bell implementation to do something only the Terminal UI can do-- nothing that looks like an application-controlled attribute :) |
Are you saying that pane-flashing will not be the same as DECSCNM and that it's really nifty? If so, I can't wait to see it! |
Microsoft Windows 10 Pro for Workstations
10.0.19042.746 (2009, 20H2)
WindowsTerminalPreview_1.5.3242.0_x64
I have a VBEEP command (visual beep, plugin for TCC.EXE from JPSoft). It saves the character attributes in the viewport like this.
Then it momentarily changes all attributes to the reverse of the default, like this.
Then it restores the original attributes, like this.
WriteConsoleOutputAttribute(con.h, attrs_original, dwSize, {0,0}, &dwWritten); // back to original attributes
But, as I hope can be seen below, After executing VBEEP, the attributes of previously displayed text seem to have changed. Check out the display of the previous "echos ..." commands before/after the "vbeep" command; lines that were half yellow before the vbeep, are all yellow afterward.
27.00.18.4588.v__.2021-01-27.12-39-39.mp4
The text was updated successfully, but these errors were encountered: