[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'Controls' (#lcl)


If true, the Color of the control will be the same as the one from the Parent. Default is true.


Source position: controls.pp line 1361

protected property TControl.ParentColor: Boolean
  read FParentColor
  write SetParentColor
  default true;


While this property is True, all changes to the Color of the parent will be also done to the Color of the control, syncronizing them and keeping them with the same value. If the Color of the control is changed by the application, then ParentColor will be automatically set to False. The combination of ParentColor with clDefault can cause problems in resolving clDefault. To obtain the Color property of a control while taking into account clDefault and ParentColor one whould use TControl.GetColorResolvingParent. This method might return a non-RGB color, but will never return clDefault. To obtain a purely RGB result use TColor.GetRGBColorResolvingParent

See also



The background color of the control.



Returns the color of the control while resolving clDefault and ParentColor



Returns a RGB value for the color of the control

This page is hosted on Get Lazarus Code and Component Repository at SourceForge.net. Fast, secure and Free Open Source software downloads