summaryrefslogtreecommitdiff
path: root/basegfx
diff options
context:
space:
mode:
authorArmin Le Grand (Collabora) <Armin.Le.Grand@me.com>2020-02-06 18:53:12 +0100
committerArmin Le Grand <Armin.Le.Grand@me.com>2020-02-07 18:49:18 +0100
commit5f61c9fe99ac93087b898adddbb4d4733f1fcd07 (patch)
tree50e5e98702db8a12eba1e4f5dc730e76db2cca1e /basegfx
parent1fb4887613f2487be6081dd62c4df30f6170e2c0 (diff)
tdf#130478 Enhance Dashed line drawing on all systems
For more info and explanation including state of process information and discussion(s) see task please. Adding corrections for gerrit build Change-Id: Ie10fb8093a86459dee80db5ab4355b47e46c1f8c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88130 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
Diffstat (limited to 'basegfx')
-rw-r--r--basegfx/source/polygon/b2dlinegeometry.cxx23
1 files changed, 17 insertions, 6 deletions
diff --git a/basegfx/source/polygon/b2dlinegeometry.cxx b/basegfx/source/polygon/b2dlinegeometry.cxx
index 0f602eb6241e..72c25f0c0593 100644
--- a/basegfx/source/polygon/b2dlinegeometry.cxx
+++ b/basegfx/source/polygon/b2dlinegeometry.cxx
@@ -848,7 +848,8 @@ namespace basegfx
css::drawing::LineCap eCap,
double fMaxAllowedAngle,
double fMaxPartOfEdge,
- double fMiterMinimumAngle)
+ double fMiterMinimumAngle,
+ basegfx::triangulator::B2DTriangleVector* pTriangles)
{
if(fMaxAllowedAngle > F_PI2)
{
@@ -958,7 +959,7 @@ namespace basegfx
fHalfLineWidth,
eJoin,
fMiterMinimumAngle,
- nullptr));
+ pTriangles));
}
else if(aOrientation == B2VectorOrientation::Negative)
{
@@ -975,7 +976,7 @@ namespace basegfx
fHalfLineWidth,
eJoin,
fMiterMinimumAngle,
- nullptr));
+ pTriangles));
}
}
@@ -994,7 +995,7 @@ namespace basegfx
bLast && eCap == css::drawing::LineCap_ROUND,
bFirst && eCap == css::drawing::LineCap_SQUARE,
bLast && eCap == css::drawing::LineCap_SQUARE,
- nullptr));
+ pTriangles));
}
else
{
@@ -1006,7 +1007,7 @@ namespace basegfx
false,
false,
false,
- nullptr));
+ pTriangles));
}
// prepare next step
@@ -1029,7 +1030,17 @@ namespace basegfx
aCandidate.getB2DPoint(0),
fHalfLineWidth));
- aRetval.append(aCircle);
+ if(nullptr != pTriangles)
+ {
+ const basegfx::triangulator::B2DTriangleVector aResult(
+ basegfx::triangulator::triangulate(
+ aCircle));
+ pTriangles->insert(pTriangles->end(), aResult.begin(), aResult.end());
+ }
+ else
+ {
+ aRetval.append(aCircle);
+ }
}
return aRetval;