Hello,
i trying get R G B values of system color "clBackground" (and others). So i use ColorToRGB function (app compiled with gtk2 widget set), but I get values that differs from actual color of form face. I found that these values match to values defined in unit "GTKGlobals" in array "SysColorMap". Is this function not yet implemented or this is a bug?
Lazarus svn 15819; fpc 2.2.0 i386; Linux i386 Kubuntu 8.04
P.S.
I tried get rgb values with code:
function SpalvaToRGB(const color: TColor): TColor;
var
drobe: TBitmap;
begin
drobe:=TBitmap.Create;
drobe.Height:=1;
drobe.Width:=1;
drobe.Canvas.Brush.Color:=color;
drobe.Canvas.FillRect(0, 0, 1, 1);
result:=drobe.Canvas.Pixels[0, 0];
drobe.Free;
end;but when I every time call this function passing clBackground, clForm or clColorDesktop as "color" i get random value. Why?
