RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TTabControl.OnResize Event

Occurs immediately after the control is resized.

Pascal
property OnResize: TNotifyEvent;
C++
__property TNotifyEvent OnResize;

Use OnResize to make any final adjustments after a control is resized. 

To modify the way a control responds when an attempt is made to resize it, use OnCanResize or OnConstrainedResize.

Note: Some controls call this event handler when the control is first created.
 

Delphi Examples: 

 

{
The following code keeps the right edge on Button1 against
the right edge of Form1 when Form1 is resized.
} 
procedure TForm1.FormResize(Sender: TObject);
begin
  Button1.Left := Form1.ClientWidth-Button1.Width;
end;

 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!