Unit 'Controls' Package
[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] [#lcl]


Sets the value for the Color property.


Source position: controls.pp line 2245

protected procedure TWinControl.SetColor(

  Value: TGraphicsColor

); override;


SetColor is an overridden method in TWinControl used to set the value for the Color property. It calls the inherited method on entry, and ensures that the new property value is applied to the internal TBrush instance used in the control. This includes translating the value clDefault to the actual brush color used for the platform.

If the Handle has been allocated for the control, the widgetset class is updated. Otherwise, control flags are updated to include the value wcfColorChanged.

The NotifyControls method is called to send the CM_PARENTCOLORCHANGED control message to the child controls.

See also



The background color of the control.



Sets the value for the Color property.

CT Web help

CodeTyphon Studio