Class TTitleButton (unit CapBar)

Inherits from

TComponent

the definition for the buttons in the titlebar

Constructors


constructor Create(AOwner: TComponent);

constructor for the buttons


Functions

destructor Destroy;

*************************************************************** *** *** *** procedures for the buttons *** *** *** *****************************************************************} { destructor for the buttons

procedure SetCaption(Value: TCapStr);

event assigned to button } { events used for defining the button

define caption and recalculate width if FAutoSize is true


procedure SetFont(Value: TFont);

define font for button

Properties

property Active : boolean

the properties shown in the objectinspector

property Alignment : TButAlign


property AutoSize : boolean


property Caption : TCapStr


property ColorButtonDisabled : TColor


property ColorButtonEnabled : TColor


property ColorTextDisabled : TColor


property ColorTextEnabled : TColor


property Enabled : boolean


property Font : TFont


property Index : integer

i have to define this property because FIdx has to be saved with the sourcecode to provide the right order of the buttons in the titlebar.

property Rounded : boolean


property Style : TButtonStyle


property Width : integer


Events

event OnClick : TNotifyEvent


Variables

Down : boolean;

font for caption

FActBCol : TColor;


FActive : boolean;

resize button when changing caption

FActTCol : TColor;

width of button

FAlign : TButAlign;

the index to define the order of the buttons

FAutoSize : boolean;

side the button belongs to

FCaption : TCapStr;


FEnabled : boolean;

show/hide button

FFont : TFont;

colors of inactive button

FIdx : integer;

the string shown on the button

FInActBCol : TColor;


FInActTCol : TColor;

colors of active button (text/background)

FOnClick : TNotifyEvent;

shape of button

FRound : boolean;

style of button (bsAutoDetect,bsNew,bsWin31

FStyle : TButtonStyle;

bounding rectangle of button

FWidth : integer;

button enabled/disabled

Rec : TRect;

pressed or released


Constructors


constructor Create(AOwner: TComponent);

constructor for the buttons


Functions


destructor Destroy;

*************************************************************** *** *** *** procedures for the buttons *** *** *** *****************************************************************} { destructor for the buttons


procedure SetCaption(Value: TCapStr);

event assigned to button } { events used for defining the button

define caption and recalculate width if FAutoSize is true


procedure SetFont(Value: TFont);

define font for button


Properties


property Active : boolean

the properties shown in the objectinspector


property Alignment : TButAlign


property AutoSize : boolean


property Caption : TCapStr


property ColorButtonDisabled : TColor


property ColorButtonEnabled : TColor


property ColorTextDisabled : TColor


property ColorTextEnabled : TColor


property Enabled : boolean


property Font : TFont


property Index : integer

i have to define this property because FIdx has to be saved with the sourcecode to provide the right order of the buttons in the titlebar. if anyone knows another way to save this value with the component without having to let it show in the objectinspector then let me know.


property Rounded : boolean


property Style : TButtonStyle


property Width : integer


Events


event OnClick : TNotifyEvent


Variables


Down : boolean;

font for caption


FActBCol : TColor;


FActive : boolean;

resize button when changing caption


FActTCol : TColor;

width of button


FAlign : TButAlign;

the index to define the order of the buttons


FAutoSize : boolean;

side the button belongs to


FCaption : TCapStr;


FEnabled : boolean;

show/hide button


FFont : TFont;

colors of inactive button


FIdx : integer;

the string shown on the button


FInActBCol : TColor;


FInActTCol : TColor;

colors of active button (text/background)


FOnClick : TNotifyEvent;

shape of button


FRound : boolean;

style of button (bsAutoDetect,bsNew,bsWin31


FStyle : TButtonStyle;

bounding rectangle of button


FWidth : integer;

button enabled/disabled


Rec : TRect;

pressed or released