Class TrGroupBox

Unit

Declaration

type TrGroupBox = class(TGroupBox)

Description

enhanced TGroupBox which provides new type of groupbox with following functions: - headline caption with definable colors and possition; - 4 types of frames with definable colors; - min max buttons with automatical and animated functions; - gradient background or background image; - support dropping of files to box; - support automatic resizing of children components

Hierarchy

  • TGroupBox
  • TrGroupBox

Overview

Methods

Public procedure RefreshAutoPosition;
Public procedure CheckAutoMinimize;
Public procedure SetAllChildren(SetChildrenValueType: TSetChildrenValueTypes; Value: variant; P: Pointer; ExcludeTag: integer);
Public function SetAutoResizeChildComponentPos(CompName: string; VerticalAlign: TrGroupBoxVerticalAlignment; ColumnIndexFrom, ColumnIndexTo, ReduceWidth: integer; HorizontalAlign: TrGroupBoxHorizontalAlignment; ReduceHeight: integer): string;
Public function GetAutoResizeChildComponentPos(CompName: string; var VerticalAlign: TrGroupBoxVerticalAlignment; var ColumnIndexFrom, ColumnIndexTo, ReduceWidth: integer; var HorizontalAlign: TrGroupBoxHorizontalAlignment; var ReduceHeight: integer): Boolean;

Properties

Public property ScaleRatio: double read FScaleRatio;
Public property DropFilesCount: integer read GetDropFilesCount;
Public property DropFileNames[I:integer]: string read GetDropFileNames;
Public property DropPoint: TPoint read FDropPoint;
Public property DropControl: TControl read GetDropControl;
Public property OriginSize: integer read FOriginSize write FOriginSize default 0;
Published property AutoEnableChildren: Boolean read FAutoEnableChildren write FAutoEnableChildren default true;
Published property AutoHint: Boolean read FAutoHint write FAutoHint default false;
Published property ClientRectTop: integer read FClientRectTop write SetClientRectTop default - 1;
Published property FrameType: TFrameType read FFrameType write SetFrameType default ft3D;
Published property FrameColor: TColor read FFrameColor write SetFrameColor default clWindowFrame;
Published property CaptionHeight: byte read FCaptionHeight write SetCaptionHeight stored StoreCaptionHeight;
Published property CaptionColor: TColor read FCaptionColor write SetCaptionColor stored StoreCaptionColor;
Published property CaptionFontColor: TColor read FCaptionFontColor write SetCaptionFontColor stored StoreCaptionFontColor;
Published property CaptionDisableFontColor: TColor read FCaptionDisableFontColor write SetCaptionDisableFontColor default clBtnShadow;
Published property CaptionFont: TFont read FCaptionFont write SetCaptionFont stored IsFontStored;
Published property CaptionParentFont: Boolean read FCaptionParentFont write SetCaptionParentFont default true;
Published property CaptionAlignment: TAlignment read FCaptionAlignment write SetCaptionAlignment default taCenter;
Published property CaptionPosition: TCaptionPosition read FCaptionPosition write SetCaptionPosition default cpTop;
Published property GradientColorFrom: TColor read FGradientColorFrom write SetGradientColorFrom default clBtnFace;
Published property GradientColorTo: TColor read FGradientColorTo write SetGradientColorTo default clBtnFace;
Published property GradientType: TGradientType read FGradientType write SetGradientType default gtNone;
Published property MinMaxBtnType: TMinMaxBtnType read FMinMaxBtnType write SetMinMaxBtnType default mmbNone;
Published property MinBtnPicture: TPicture read FMinBtnPicture write SetMinBtnPicture;
Published property MaxBtnPicture: TPicture read FMaxBtnPicture write SetMaxBtnPicture;
Published property BackgroundPicture: TPicture read FBackgroundPicture write SetBackgroundPicture;
Published property BackgroundPictureType: TBackgroundPictureType read FBackgroundPictureType write SetBackgroundPictureType default bkpNone;
Published property UseTabColor: Boolean read FUseTabColor write SetUseTabColor default false;
Published property Minimized: Boolean read FMinimized write SetMinimized default false;
Published property MinimizeAnimate: Boolean read FMinimizeAnimate write FMinimizeAnimate default false;
Published property AutoMinimizeTime: cardinal read FAutoMinimizeTime write FAutoMinimizeTime default 0;
Published property AutoMaximizeTime: cardinal read FAutoMaximizeTime write FAutoMaximizeTime default 0;
Published property ShowSizeGrip: Boolean read FShowSizeGrip write SetShowSizeGrip default false;
Published property AutoResizePos: TAutoResizePos read FAutoResizePos write FAutoResizePos;
Published property AutoResizeChild: TAutoResizeChild read FAutoResizeChild write FAutoResizeChild;
Published property OnRefreshAutoPosition: TNotifyEvent read FOnRefreshAutoPosition write FOnRefreshAutoPosition;
Published property OnMinimizeChange: TNotifyEvent read FOnMinimizeChange write FOnMinimizeChange;
Published property EnableDropFile: Boolean read FEnableDropFile write SetEnableDropFile default false;
Published property OnDropFiles: TDropFilesEvent read FOnDropFiles write FOnDropFiles;
Published property OnChangeScale: TChangeScaleEvent read FChangeScale write FChangeScale;

Description

Methods

Public procedure RefreshAutoPosition;

realign possition of all child controls

Public procedure CheckAutoMinimize;

check time and do minimize on Time, should be called by user in OnIdle event

Public procedure SetAllChildren(SetChildrenValueType: TSetChildrenValueTypes; Value: variant; P: Pointer; ExcludeTag: integer);

set value to SetChildrenValueType for all children components

Public function SetAutoResizeChildComponentPos(CompName: string; VerticalAlign: TrGroupBoxVerticalAlignment; ColumnIndexFrom, ColumnIndexTo, ReduceWidth: integer; HorizontalAlign: TrGroupBoxHorizontalAlignment; ReduceHeight: integer): string;

set auto resize setting for particular component

Public function GetAutoResizeChildComponentPos(CompName: string; var VerticalAlign: TrGroupBoxVerticalAlignment; var ColumnIndexFrom, ColumnIndexTo, ReduceWidth: integer; var HorizontalAlign: TrGroupBoxHorizontalAlignment; var ReduceHeight: integer): Boolean;

get auto resize setting for particular component

Properties

Public property ScaleRatio: double read FScaleRatio;

define actual scale ratio relative to original designed size

Public property DropFilesCount: integer read GetDropFilesCount;

The number of files dropped

Public property DropFileNames[I:integer]: string read GetDropFileNames;

The names of the dropped files

Public property DropPoint: TPoint read FDropPoint;

The mouse coordinates where the last files were dropped

Public property DropControl: TControl read GetDropControl;

The child control (if any) under the mouse when files are dropped - returns nil if no control under mouse

Public property OriginSize: integer read FOriginSize write FOriginSize default 0;

set size of not minimized box (stored automatically before minimize)

Published property AutoEnableChildren: Boolean read FAutoEnableChildren write FAutoEnableChildren default true;

switch on/off automatic enabling of all children control according enable state of the rGroupBox

Published property AutoHint: Boolean read FAutoHint write FAutoHint default false;

switch on/off showing of system hint in Caption, used for rGroupBox as status bar

Published property ClientRectTop: integer read FClientRectTop write SetClientRectTop default - 1;

define top of the client rect

Published property FrameType: TFrameType read FFrameType write SetFrameType default ft3D;

define type of the frame

Published property FrameColor: TColor read FFrameColor write SetFrameColor default clWindowFrame;

define color of the frame

Published property CaptionHeight: byte read FCaptionHeight write SetCaptionHeight stored StoreCaptionHeight;

define height of the caption rectangle

Published property CaptionColor: TColor read FCaptionColor write SetCaptionColor stored StoreCaptionColor;

define background color of the caption rectangle

Published property CaptionFontColor: TColor read FCaptionFontColor write SetCaptionFontColor stored StoreCaptionFontColor;

define font color of the caption rectangle

Published property CaptionDisableFontColor: TColor read FCaptionDisableFontColor write SetCaptionDisableFontColor default clBtnShadow;

define font color of the caption rectangle in disable state

Published property CaptionFont: TFont read FCaptionFont write SetCaptionFont stored IsFontStored;

define font of the caption rectangle

Published property CaptionParentFont: Boolean read FCaptionParentFont write SetCaptionParentFont default true;

define if the caption uses parent font

Published property CaptionAlignment: TAlignment read FCaptionAlignment write SetCaptionAlignment default taCenter;

define alignment of the caption text

Published property CaptionPosition: TCaptionPosition read FCaptionPosition write SetCaptionPosition default cpTop;

define position of the caption rectangle

Published property GradientColorFrom: TColor read FGradientColorFrom write SetGradientColorFrom default clBtnFace;

define start color of the background gradient

Published property GradientColorTo: TColor read FGradientColorTo write SetGradientColorTo default clBtnFace;

define end color of the background gradient

Published property GradientType: TGradientType read FGradientType write SetGradientType default gtNone;

define type of the background gradient

Published property MinMaxBtnType: TMinMaxBtnType read FMinMaxBtnType write SetMinMaxBtnType default mmbNone;

define type of the minimize button in caption rectangle

Published property MinBtnPicture: TPicture read FMinBtnPicture write SetMinBtnPicture;

define glyph for the minimize button

Published property MaxBtnPicture: TPicture read FMaxBtnPicture write SetMaxBtnPicture;

define glyph for the maximize button

Published property BackgroundPicture: TPicture read FBackgroundPicture write SetBackgroundPicture;

define background picture for the box

Published property BackgroundPictureType: TBackgroundPictureType read FBackgroundPictureType write SetBackgroundPictureType default bkpNone;

define type of background picture for the box

Published property UseTabColor: Boolean read FUseTabColor write SetUseTabColor default false;

define thet background has the same color as Tab background color

Published property Minimized: Boolean read FMinimized write SetMinimized default false;

define whether box is minimized

Published property MinimizeAnimate: Boolean read FMinimizeAnimate write FMinimizeAnimate default false;

define whether minimizing is animated

Published property AutoMinimizeTime: cardinal read FAutoMinimizeTime write FAutoMinimizeTime default 0;

define minimize step delay if minimizing is animated

Published property AutoMaximizeTime: cardinal read FAutoMaximizeTime write FAutoMaximizeTime default 0;

define maximize step delay if minimizing is animated

Published property ShowSizeGrip: Boolean read FShowSizeGrip write SetShowSizeGrip default false;

define whether size grip is shown at right bottom corner

Published property AutoResizePos: TAutoResizePos read FAutoResizePos write FAutoResizePos;

subcomponent define autoresize properties for the box

Published property AutoResizeChild: TAutoResizeChild read FAutoResizeChild write FAutoResizeChild;

subcomponent define autoresize properties for the children controls

Published property OnRefreshAutoPosition: TNotifyEvent read FOnRefreshAutoPosition write FOnRefreshAutoPosition;

event is called after AutoPosition refreshing

Published property OnMinimizeChange: TNotifyEvent read FOnMinimizeChange write FOnMinimizeChange;

event is called after minimize state change

Published property EnableDropFile: Boolean read FEnableDropFile write SetEnableDropFile default false;

switch on/off dropping of files

Published property OnDropFiles: TDropFilesEvent read FOnDropFiles write FOnDropFiles;

event called when files are dropped on the control; it identify sending control and the X and Y co-oridnates where files were dropped

Published property OnChangeScale: TChangeScaleEvent read FChangeScale write FChangeScale;

event is called when Scale is changed


Generated by PasDoc 0.15.0.