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

Suppressed application title overwritten after screen lock #15732

Closed
geluk opened this issue Jul 20, 2023 · 1 comment · Fixed by #16004
Closed

Suppressed application title overwritten after screen lock #15732

geluk opened this issue Jul 20, 2023 · 1 comment · Fixed by #16004
Assignees
Labels
Area-Settings Issues related to settings and customizability, for console or terminal In-PR This issue has a related PR Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Tag-Fix Doesn't match tag requirements Product-Terminal The new Windows Terminal.

Comments

@geluk
Copy link

geluk commented Jul 20, 2023

Windows Terminal version

1.17.11461.0

Windows build number

10.0.22000.0

Other Software

No response

Steps to reproduce

  1. Open a new terminal, and override the application title:
wt --suppressApplicationTitle --title example powershell
  1. Observe that the terminal has a tab named example
  2. Lock your screen (Windows + L)
  3. Sign back in
  4. Observe that the tab name has changed from example to Windows PowerShell

Expected Behavior

After unlocking, I would expect the tab name to be unchanged.

Actual Behavior

After unlocking, the tab name is changed from example to Windows PowerShell.

Note: This only happens when using the commandline to set the tab title. If you manually override it by double-clicking the tab and entering something there, the tab will keep its name after locking and unlocking.

@geluk geluk added Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Jul 20, 2023
@carlos-zamora carlos-zamora added this to the Terminal v1.19 milestone Aug 2, 2023
@carlos-zamora carlos-zamora added Area-Settings Issues related to settings and customizability, for console or terminal Product-Terminal The new Windows Terminal. and removed Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Aug 2, 2023
@zadjii-msft
Copy link
Member

Another obvious way of triggering this is setting a fontFace to garbage or some other non-existent font, then opening a admin application. The UAC will trigger a "desktop change"1. That'll do the same thing as a lock screen.

Debugger shows that we get another "ImmersiveColorSet" message, with wparam=0. Great. We're using that as a signal that the OS theme changed. When we get that, we reload the whole settings.2

A stackoverflow post pointed me at maybe UISettings.ColorValuesChanged

related, but not actually: #11522

Footnotes

  1. okay that's not exactly what's happening, on mobile so can't look up the right term.

  2. reloading the settings overwrites the title from the NewTabArgs. That's not great, but I think that's technically tracked in

zadjii-msft added a commit that referenced this issue Sep 19, 2023
@microsoft-github-policy-service microsoft-github-policy-service bot added the In-PR This issue has a related PR label Sep 19, 2023
carlos-zamora pushed a commit that referenced this issue Sep 20, 2023
`ImmersiveColorSet` gets sent more often than just on a theme change. It notably gets sent when the PC is locked, or the UAC prompt opens.

## Validation Steps Performed

Tested manually by setting the font to `garbo`and:
* locking, then logging back in. No dialog ✅ 
* UAC via run dialog + `regedit`. No dialog ✅ 
* Actually changing the OS theme. Dialog ✅  

Closes #15732
@microsoft-github-policy-service microsoft-github-policy-service bot added the Needs-Tag-Fix Doesn't match tag requirements label Sep 20, 2023
DHowett pushed a commit that referenced this issue Sep 22, 2023
`ImmersiveColorSet` gets sent more often than just on a theme change. It notably gets sent when the PC is locked, or the UAC prompt opens.

## Validation Steps Performed

Tested manually by setting the font to `garbo`and:
* locking, then logging back in. No dialog ✅
* UAC via run dialog + `regedit`. No dialog ✅
* Actually changing the OS theme. Dialog ✅

Closes #15732

(cherry picked from commit c1bdcf8)
Service-Card-Id: 90600308
Service-Version: 1.18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Settings Issues related to settings and customizability, for console or terminal In-PR This issue has a related PR Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Tag-Fix Doesn't match tag requirements Product-Terminal The new Windows Terminal.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants