mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-06-22 09:08:15 +02:00
gtk2: allocate background color in TextOut when drawing opaque text (same as what was done for ExtTextOut in rev 38758 #06660654be). Issue #31187
git-svn-id: trunk@53838 -
This commit is contained in:
parent
42132a8872
commit
9108c60199
@ -9593,14 +9593,9 @@ begin
|
|||||||
EnsureGCColor(DC, dccCurrentTextColor, True, False);
|
EnsureGCColor(DC, dccCurrentTextColor, True, False);
|
||||||
|
|
||||||
BackGroundColor := nil;
|
BackGroundColor := nil;
|
||||||
if Assigned(DevCtx.GDIObjects[gdiBrush]) and (DevCtx.BkMode = OPAQUE) and
|
if DevCtx.BkMode = OPAQUE then
|
||||||
Assigned(DevCtx.CurrentBackColor.Colormap) then
|
|
||||||
begin
|
begin
|
||||||
EnsureGCColor(DC, dccCurrentBackColor, DevCtx.GDIObjects[gdiBrush]^.GDIBrushFill = GDK_SOLID, True);
|
AllocGDIColor(DC, @DevCtx.CurrentBackColor);
|
||||||
//do not set BackGroundColor if CurrentBrush.Color = CurrentBackColor.
|
|
||||||
//issue #22719
|
|
||||||
if TGDKColorToTColor(DevCtx.CurrentBackColor.Color) <>
|
|
||||||
TGDKColorToTColor(DevCtx.GetBrush^.GDIBrushColor.Color) then
|
|
||||||
BackGroundColor := @DevCtx.CurrentBackColor.Color;
|
BackGroundColor := @DevCtx.CurrentBackColor.Color;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user