TCustomFrame.CalculatePreferredSize procedure
Gets the preferred height and width for the control used during auto-sizing.
Declaration
procedure CalculatePreferredSize(var PreferredWidth: Integer;
var PreferredHeight: Integer;
WithThemeSpace: Boolean); overrideArguments
PreferredWidth | Preferred width for the control. |
PreferredHeight | Preferred height for the control. |
WithThemeSpace | True if additional space is reserved in the width or height for theme details. |
Description
CalculatePreferredSize is an overridden method in
TCustomFrame. It ensures that the inherited method is
not
called when the frame is an un-parented component and visible on the form
designer. This allows the dimensions to be freely resized on the design
surface. Values in the PreferredWidth, PreferredHeight, and WithThemeSpace
arguments are not modified at design-time.
If the frame has an Owner (parent form) at run-time, the inherited method is called to get the values used in the LCL auto-sizing algorithms.
See also
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
