summaryrefslogtreecommitdiffstats
path: root/WebCore/platform/graphics/cg/GraphicsContextCG.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/platform/graphics/cg/GraphicsContextCG.cpp')
-rw-r--r--WebCore/platform/graphics/cg/GraphicsContextCG.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/WebCore/platform/graphics/cg/GraphicsContextCG.cpp b/WebCore/platform/graphics/cg/GraphicsContextCG.cpp
index a65874c..2de4d14 100644
--- a/WebCore/platform/graphics/cg/GraphicsContextCG.cpp
+++ b/WebCore/platform/graphics/cg/GraphicsContextCG.cpp
@@ -469,16 +469,24 @@ void GraphicsContext::drawConvexPolygon(size_t npoints, const FloatPoint* points
CGContextSetShouldAntialias(context, shouldAntialias());
}
-void GraphicsContext::clipConvexPolygon(size_t numPoints, const FloatPoint* points)
+void GraphicsContext::clipConvexPolygon(size_t numPoints, const FloatPoint* points, bool antialias)
{
if (paintingDisabled())
return;
if (numPoints <= 1)
return;
+
+ CGContextRef context = platformContext();
+
+ if (antialias != shouldAntialias())
+ CGContextSetShouldAntialias(context, antialias);
- addConvexPolygonToContext(platformContext(), numPoints, points);
+ addConvexPolygonToContext(context, numPoints, points);
clipPath(RULE_NONZERO);
+
+ if (antialias != shouldAntialias())
+ CGContextSetShouldAntialias(context, shouldAntialias());
}
void GraphicsContext::applyStrokePattern()