RxFPC:fix bg color in RxTollbar setup dialog

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3960 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
alexs75
2015-02-24 11:53:08 +00:00
parent 97ddec5e62
commit 88d00ecb4d

View File

@ -121,8 +121,10 @@ var
P:TToolbarItem;
BtnRect:TRect;
Cnv:TCanvas;
C: TColor;
begin
Cnv:=(Control as TListBox).Canvas;
C:=Cnv.Brush.Color;
Cnv.FillRect(ARect); { clear the rectangle }
P:=TToolbarItem((Control as TListBox).Items.Objects[Index]);
if Assigned(P) then
@ -147,6 +149,7 @@ begin
Offset:=BtnRect.Right;
end;
Offset := Offset + 6;
Cnv.Brush.Color:=C;
Cnv.TextOut(ARect.Left + Offset, (ARect.Top + ARect.Bottom - Cnv.TextHeight('W')) div 2, TCustomAction(P.Action).Caption); { display the text }
end;
end;