mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-07 11:16:07 +02:00
TAChart: Relax condition to close polygon for TPolygonSeries in case of single polygons.
git-svn-id: trunk@64386 -
This commit is contained in:
parent
751852a44a
commit
78d7603454
@ -134,6 +134,20 @@ begin
|
|||||||
if nPoints = 0 then
|
if nPoints = 0 then
|
||||||
exit;
|
exit;
|
||||||
|
|
||||||
|
// Single polygon --> we can use the standard Polygon() routine
|
||||||
|
if nStart = 1 then
|
||||||
|
begin
|
||||||
|
SetLength(FPoints, nPoints);
|
||||||
|
ADrawer.SetBrush(FBrush);
|
||||||
|
ADrawer.SetPen(FPen);
|
||||||
|
ADrawer.Polygon(FPoints, 0, Length(FPoints));
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
|
||||||
|
// If we get here we have multiple polygons. We must add points for a
|
||||||
|
// "clean retreat" to the starting point, and then we fill the borderless
|
||||||
|
// polygon and draw the border separately.
|
||||||
|
|
||||||
// Use length of FStart array as last array element for easier calculation
|
// Use length of FStart array as last array element for easier calculation
|
||||||
SavePolygonStartIndex(nPoints);
|
SavePolygonStartIndex(nPoints);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user