Sign in Join
FPDoc Onlineexperiment

TSizeConstraints.AutoAdjustLayout procedure

Member of TSizeConstraintspublicIn unit Controls

Adjusts width and height values in the class using the specified scaling factors.

Declaration

pascal
procedure AutoAdjustLayout(const AXProportion: Double; 
 const AYProportion: Double)

Arguments

AXProportion

Scaling factor applied to width values.

AYProportion

Scaling factor applied to height values.

Description

AutoAdjustLayout ensures that assigned (non-zero) values in MinHeight, MaxHeight, MinWidth, and MaxWidth are scaled by the corresponding scaling factor. If any of the property values are scaled, the Change method is called to notify the associated Control that it should adjust it size. The OnChange event is signalled (when assigned).

AutoAdjustLayout is called from the DoAutoAdjustLayout method in Control, and occurs after values in BorderSpacing have been scaled. It occurs before the new height and width for the Control are calculated and applied to its BaseBounds.

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.