[Lazarus] How to obtain the color of a component?

Felipe Monteiro de Carvalho felipemonteiro.carvalho at gmail.com
Wed Oct 26 17:23:15 CEST 2011


On Fri, Oct 21, 2011 at 10:43 AM, Felipe Monteiro de Carvalho
<felipemonteiro.carvalho at gmail.com> wrote:
> function TControl.GetColorResolvingParent: TColor;
> begin
>  if Color = clDefault then
>    Result := GetDefaultColor(dctBrush)
>  else
>    Result := Color;
> end;
>
> function TControl.GetRGBColor: TColor;
> begin
>    Result := ColorToRGB(GetColorResolvingParent);
> end;

These now exist in rev 33093

-- 
Felipe Monteiro de Carvalho




More information about the Lazarus mailing list