From e358f1d96e605376aff0f8ee85b1dfba290307f0 Mon Sep 17 00:00:00 2001
From: kirkpatc ImageIndex CalculatePreferredSize - find default/preferred height and width Calculates the default/preferred width and height for a control, which is used
+ CalculatePreferredSize - find default/preferred height and width procedure TControl.CalculatePreferredSize (var PreferredWidth, PreferredHeight: integer; WithThemeSpace: Boolean); Calculates the default/preferred width and height for a control, which is used
by the LCL autosizing algorithms as default size. Only positive values are
valid. Negative or 0 are treated as undefined and the LCL uses other sizes
- instead. TWinControl overrides this and asks the interface for theme dependent values.
- See TWinControl.CalculatePreferredSize for more information. WithThemeSpace: If true, adds space for stacking. For example: TRadioButton has a minimum size. But for stacking multiple TRadioButtons there should be
- some space around. This space is theme dependent, so the parameter is passes to the widgetset TWinControl overrides this and asks the interface for theme dependent values.
+ See TWinControl.CalculatePreferredSize for more information. WithThemeSpace: If true, adds space for stacking. For example: TRadioButton has a minimum size. But for stacking multiple TRadioButtons there should be
+ some space around. This space is theme dependent, so the parameter is passed to the widgetset ParentShowHint TControl.AdjustSize calls DoAutoSize in a smart fashion. During loading and handle creation the calls are delayed. This method initially does the same as TWinControl.DoAutoSize. But since DoAutoSize is commonly overriden by descendant components, it is not useful to perform all tests, which can result in too much overhead. To reduce this the LCL calls AdjustSizeprocedure TControl.CalculatePreferredSize
- (var PreferredWidth, PreferredHeight: integer;
- WithThemeSpace: Boolean);
This method initially does the same as TWinControl.DoAutoSize. But since DoAutoSize is commonly overriden by descendant components, it is not useful to perform all tests, which can result in too much overhead. To reduce this the LCL calls AdjustSize instead.
@@ -5594,11 +5596,13 @@ mrLast=mrYesToAll=10TControl.EditingDone -
Called when user has finished editing. This procedure can be used by data links to commit the changes
. -For example:
TControl.EditingDone
+Called when user has finished editing. This procedure can be used by data links to commit the changes
. +For example:
+It's totally up to the control, what events will commit.
It's totally up to the control, what events will commit.
To keep things optimal, LCL implementations should always override RealGet/SetText. Get/SetTextBuf is only kept for compatibility.