[PR #12460] [MERGED] Manually set the colors of the TabViewBackground #29053

Open
opened 2026-01-31 09:32:29 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/12460
Author: @zadjii-msft
Created: 2/10/2022
Status: Merged
Merged: 2/15/2022
Merged by: @undefined

Base: mainHead: dev/migrie/b/12356-attempt-3


📝 Commits (3)

  • ef932cd why does this work but the others don't?
  • 82dd0e7 comments before I try something stupid
  • 2e36459 more comments

📊 Changes

2 files changed (+18 additions, -5 deletions)

View changed files

📝 src/cascadia/TerminalApp/App.xaml (+18 -4)
📝 src/cascadia/TerminalApp/TerminalPage.cpp (+0 -1)

📄 Description

This has been a saga.

Basically, any resources in App.xaml aren't going to be able to reference other theme-aware resources. We can't change the theme of the app at runtime, only elements within the app. So we can't use ApplicationPageBackgroundThemeBrush in app.xaml, because it will ALWAYS be evaluated as the OS theme version of that brush.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/12460 **Author:** [@zadjii-msft](https://github.com/zadjii-msft) **Created:** 2/10/2022 **Status:** ✅ Merged **Merged:** 2/15/2022 **Merged by:** [@undefined](undefined) **Base:** `main` ← **Head:** `dev/migrie/b/12356-attempt-3` --- ### 📝 Commits (3) - [`ef932cd`](https://github.com/microsoft/terminal/commit/ef932cd789ef8aeaf075cc16511b2466954e009c) why does this work but the others don't? - [`82dd0e7`](https://github.com/microsoft/terminal/commit/82dd0e7c43489e917fe22d4b40063b7de6bbfb4d) comments before I try something stupid - [`2e36459`](https://github.com/microsoft/terminal/commit/2e36459c76d0c54adec3d704fde4b284de382e02) more comments ### 📊 Changes **2 files changed** (+18 additions, -5 deletions) <details> <summary>View changed files</summary> 📝 `src/cascadia/TerminalApp/App.xaml` (+18 -4) 📝 `src/cascadia/TerminalApp/TerminalPage.cpp` (+0 -1) </details> ### 📄 Description This has been a saga. Basically, any resources in `App.xaml` aren't going to be able to reference other theme-aware resources. We can't change the theme of the app at runtime, only elements within the app. So we can't use `ApplicationPageBackgroundThemeBrush` in app.xaml, because it will ALWAYS be evaluated as the OS theme version of that brush. * regressed in #12326 * See also #10864 * #3917 CANNOT be fixed in the same way. We're lucky here that the TabView uses a `{ThemeResource TabViewBackground}` in markup to set the bg. We're not similarly lucky with the Pane one. * [x] closes #12356 * [x] Tested manually. You can confirm, my eyes are bleeding from the OS-wide light mode --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:32:29 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#29053