Martijn Laan 1 месяц назад
Родитель
Сommit
583f0fab7c

+ 19 - 0
Projects/Src/IDE.HelperFunc.pas

@@ -131,6 +131,21 @@ begin
 end;
 
 function InitFormTheme(const Form: TForm): Boolean;
+
+{$IF CompilerVersion >= 36.0}
+  procedure HideGroupBoxFrames(const ParentControl: TWinControl);
+  begin
+    for var I := 0 to ParentControl.ControlCount-1 do begin
+      const Control = ParentControl.Controls[I];
+      if Control is TGroupBox then
+        (Control as TGroupBox).ShowFrame := False;
+
+      if Control is TWinControl then
+        HideGroupBoxFrames(Control as TWinControl);
+    end;
+  end;
+{$ENDIF}
+
 { Assumes forms other then MainForm call this function only once during creation, and assumes they
   don't need any styling if the theme is non dark. Always styles MainForm. Returns True if it did
   style, False otherwise. }
@@ -149,6 +164,10 @@ begin
       DwmSetWindowAttribute(Form.Handle, DWMWA_USE_IMMERSIVE_DARK_MODE, @value, SizeOf(value));
     end;
   end;
+
+{$IF CompilerVersion >= 36.0}
+  HideGroupBoxFrames(Form);
+{$ENDIF}
 end;
 
 function InitFormThemeGetBkColor(const WindowColor: Boolean): TColor;

+ 0 - 6
Projects/Src/IDE.MsgBoxDesignerForm.dfm

@@ -103,7 +103,6 @@ object MsgBoxDesignerForm: TMsgBoxDesignerForm
     Height = 81
     Anchors = [akLeft, akTop, akRight]
     Caption = ' Message '
-    ShowFrame = False
     TabOrder = 0
     DesignSize = (
       532
@@ -125,7 +124,6 @@ object MsgBoxDesignerForm: TMsgBoxDesignerForm
     Width = 240
     Height = 60
     Caption = ' Type'
-    ShowFrame = False
     TabOrder = 6
     object cb_Suppressible: TCheckBox
       Left = 14
@@ -165,7 +163,6 @@ object MsgBoxDesignerForm: TMsgBoxDesignerForm
     Height = 60
     Anchors = [akLeft, akTop, akRight]
     Caption = ' Flags '
-    ShowFrame = False
     TabOrder = 7
     object NewStaticText1: TNewStaticText
       Left = 14
@@ -214,7 +211,6 @@ object MsgBoxDesignerForm: TMsgBoxDesignerForm
     Height = 174
     Anchors = [akLeft, akTop, akBottom]
     Caption = ' Icon '
-    ShowFrame = False
     TabOrder = 8
     DesignSize = (
       160
@@ -422,7 +418,6 @@ object MsgBoxDesignerForm: TMsgBoxDesignerForm
     Height = 174
     Anchors = [akLeft, akTop, akBottom]
     Caption = ' Buttons '
-    ShowFrame = False
     TabOrder = 9
     DesignSize = (
       169
@@ -502,7 +497,6 @@ object MsgBoxDesignerForm: TMsgBoxDesignerForm
     Height = 174
     Anchors = [akLeft, akTop, akBottom]
     Caption = ' Return values '
-    ShowFrame = False
     TabOrder = 10
     object cb_IDOK: TCheckBox
       Left = 16

+ 0 - 3
Projects/Src/IDE.OptionsForm.dfm

@@ -26,7 +26,6 @@ object OptionsForm: TOptionsForm
     Height = 314
     Anchors = [akLeft, akTop, akBottom]
     Caption = ' Miscellaneous '
-    ShowFrame = False
     TabOrder = 0
     object StartupCheck: TCheckBox
       Left = 8
@@ -141,7 +140,6 @@ object OptionsForm: TOptionsForm
     Height = 57
     Anchors = [akLeft, akBottom]
     Caption = ' File Associations '
-    ShowFrame = False
     TabOrder = 1
     DesignSize = (
       281
@@ -164,7 +162,6 @@ object OptionsForm: TOptionsForm
     Height = 372
     Anchors = [akLeft, akTop, akBottom]
     Caption = ' Editor '
-    ShowFrame = False
     TabOrder = 2
     object AutoAutoCompleteCheck: TCheckBox
       Left = 8

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

@@ -25,7 +25,6 @@ object SignToolsForm: TSignToolsForm
     Height = 201
     Anchors = [akLeft, akTop, akRight, akBottom]
     Caption = ' Sign Tools '
-    ShowFrame = False
     TabOrder = 0
     DesignSize = (
       561

+ 0 - 2
Projects/Src/IDE.StartupForm.dfm

@@ -270,7 +270,6 @@ object StartupForm: TStartupForm
     Height = 61
     Anchors = [akLeft, akTop, akRight]
     Caption = ' New file '
-    ShowFrame = False
     TabOrder = 0
     DesignSize = (
       563
@@ -313,7 +312,6 @@ object StartupForm: TStartupForm
     Height = 303
     Anchors = [akLeft, akTop, akRight, akBottom]
     Caption = ' Open file '
-    ShowFrame = False
     TabOrder = 1
     DesignSize = (
       563

+ 0 - 2
Projects/Src/IDE.Wizard.WizardFileForm.dfm

@@ -60,7 +60,6 @@ object WizardFileForm: TWizardFileForm
     Width = 333
     Height = 149
     Caption = ' Destination '
-    ShowFrame = False
     TabOrder = 0
     object DestRootDirLabel: TNewStaticText
       Left = 12
@@ -112,7 +111,6 @@ object WizardFileForm: TWizardFileForm
     Width = 333
     Height = 93
     Caption = ' Source '
-    ShowFrame = False
     TabOrder = 3
     object SourceLabel: TNewStaticText
       Left = 12

+ 1 - 1
Projects/Src/Shared.TaskDialogFunc.pas

@@ -129,7 +129,7 @@ begin
 
   { Set ButtonIDs and TDCommonButtons }
   const NButtonLabelsAvailable = Length(ButtonLabels);
-  var ButtonIDs: array of Integer;
+  var ButtonIDs: TArray<Integer>;
   var TDCommonButtons: Cardinal;
   case Buttons of
     MB_OK, MB_OKCANCEL: