unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, themes; type TGroupBox = class(StdCtrls.TGroupBox) //declare this before of your form definition public procedure Paint; override; end; type TForm1 = class(TForm) GroupBox1: TGroupBox; private { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} procedure TGroupBox.Paint; var H: Integer; R: TRect; Flags: Longint; CaptionRect, OuterRect: TRect; Size: TSize; Box: TThemedButton; Details: TThemedElementDetails; begin with Canvas do begin Font := Self.Font; if ThemeControl(Self) then begin if Text <>...