mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-06-03 10:18:17 +02:00
Gtk2: fixed offset in Gtk2 polygon drawer. issue #23359
git-svn-id: trunk@39326 -
This commit is contained in:
parent
2316eaf3f4
commit
27b6c1f3a2
@ -6676,7 +6676,7 @@ var
|
||||
i: integer;
|
||||
PointArray: PGDKPoint;
|
||||
Tmp, RGN : hRGN;
|
||||
ClipRect : TRect;
|
||||
R, ClipRect : TRect;
|
||||
DCOrigin: TPoint;
|
||||
OldNumPts: integer;
|
||||
begin
|
||||
@ -6733,13 +6733,15 @@ begin
|
||||
DevCtx.TransfNormalize(ClipRect.Left, ClipRect.Right);
|
||||
DevCtx.TransfNormalize(ClipRect.Top, ClipRect.Bottom);
|
||||
end;
|
||||
|
||||
// draw polygon area
|
||||
DevCtx.FillRect(ClipRect, HBrush({%H-}PtrUInt(DevCtx.GetBrush)), False);
|
||||
R := ClipRect;
|
||||
LPtoDP(DC, R, 2);
|
||||
DevCtx.FillRect(R, HBrush({%H-}PtrUInt(DevCtx.GetBrush)), False);
|
||||
// restore old clipping
|
||||
SelectClipRGN(DC, Tmp);
|
||||
DeleteObject(Tmp);
|
||||
end
|
||||
else
|
||||
end else
|
||||
begin
|
||||
DevCtx.SelectBrushProps;
|
||||
gdk_draw_polygon(DevCtx.Drawable, DevCtx.GC, 1, PointArray, NumPts);
|
||||
|
Loading…
Reference in New Issue
Block a user