File tree Expand file tree Collapse file tree 1 file changed +12
-10
lines changed
src/cascadia/TerminalSettingsEditor Expand file tree Collapse file tree 1 file changed +12
-10
lines changed Original file line number Diff line number Diff line change @@ -699,21 +699,23 @@ namespace winrt::Microsoft::Terminal::Settings::Editor::implementation
699
699
}
700
700
}
701
701
702
- if (!isMicaAvailable)
703
- {
704
- return ;
705
- }
706
702
const auto & theme = _settingsSource.GlobalSettings ().CurrentTheme ();
707
- const auto & requestedTheme = (theme.Settings () != nullptr ) ? theme.Settings ().RequestedTheme () : theme.RequestedTheme ();
703
+ const bool hasThemeForSettings{ theme.Settings () != nullptr };
704
+ const auto & appTheme = theme.RequestedTheme ();
705
+ const auto & requestedTheme = (hasThemeForSettings) ? theme.Settings ().RequestedTheme () : appTheme;
708
706
709
707
RequestedTheme (requestedTheme);
710
708
711
- if (!isMicaAvailable)
712
- {
713
- return ;
714
- }
709
+ // Mica gets it's appearance from the app's theme, not necessarily the
710
+ // Page's theme. In the case of dark app, light settings, mica will be a
711
+ // dark color, and the text will also be dark, making the UI _very_ hard
712
+ // to read. (and similarly in the inverse situation).
713
+ //
714
+ // To mitigate this, don't set the transparent background in the case
715
+ // that our theme is different than the app's.
716
+ const bool actuallyUseMica = isMicaAvailable && (appTheme == requestedTheme);
715
717
716
- const auto bgKey = (theme.Window () != nullptr && theme.Window ().UseMica ()) ?
718
+ const auto bgKey = (theme.Window () != nullptr && theme.Window ().UseMica ()) && actuallyUseMica ?
717
719
L" SettingsPageMicaBackground" :
718
720
L" SettingsPageBackground" ;
719
721
You can’t perform that action at this time.
0 commit comments