2
0
Эх сурвалжийг харах

Fix dark mode UpdatePanel colors.

Martijn Laan 2 сар өмнө
parent
commit
906455c267

+ 1 - 0
Projects/Src/IDE.MainForm.dfm

@@ -372,6 +372,7 @@ object MainForm: TMainForm
     BevelOuter = bvNone
     BevelOuter = bvNone
     TabOrder = 1
     TabOrder = 1
     Visible = False
     Visible = False
+    StyleName = 'Windows'
     object UpdatePanelClosePaintBox: TPaintBox
     object UpdatePanelClosePaintBox: TPaintBox
       AlignWithMargins = True
       AlignWithMargins = True
       Left = 330
       Left = 330

+ 4 - 3
Projects/Src/IDE.MainForm.pas

@@ -6480,9 +6480,10 @@ begin
   SetHelpFileDark(FTheme.Dark);
   SetHelpFileDark(FTheme.Dark);
 
 
   { For MainForm the active style only impacts message boxes and tooltips: FMemos, ToolbarPanel,
   { For MainForm the active style only impacts message boxes and tooltips: FMemos, ToolbarPanel,
-    SplitPanel, StatusBar and the 4 ListBoxes all ignore it because their StyleName property is set
-    to 'Windows' always. Additionally, for scrollbars and StatusBar, MainForm's StyleElements is
-    empty. Menus ignore it because shMenus is removed from TStyleManager.SystemHooks at startup. }
+    UpdatePanel, SplitPanel and the 4 ListBoxes all ignore it because their StyleName property is set
+    to 'Windows' always, either by the .dfm or by code. Additionally, for scrollbars and StatusBar,
+    MainForm's StyleElements is empty. Menus ignore it because shMenus is removed from
+    TStyleManager.SystemHooks at startup. }
   if FTheme.Dark then
   if FTheme.Dark then
     TStyleManager.TrySetStyle('Windows11 Modern Dark')
     TStyleManager.TrySetStyle('Windows11 Modern Dark')
   else
   else