Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2155)

Unified Diff: Source/platform/graphics/StrokeData.h

Issue 597053003: Move color/gradient/pattern out of StrokeData (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/platform/graphics/GraphicsContextState.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/graphics/StrokeData.h
diff --git a/Source/platform/graphics/StrokeData.h b/Source/platform/graphics/StrokeData.h
index 7e8fb423a6731d7aea20d94af3414b455325f0ab..4dccbf78c1446b67899d84311d4ad3dd57b7bea6 100644
--- a/Source/platform/graphics/StrokeData.h
+++ b/Source/platform/graphics/StrokeData.h
@@ -41,14 +41,13 @@
namespace blink {
-// Encapsulates stroke painting information.
+// Encapsulates stroke geometry information.
// It is pulled out of GraphicsContextState to enable other methods to use it.
class PLATFORM_EXPORT StrokeData {
public:
StrokeData()
: m_style(SolidStroke)
, m_thickness(0)
- , m_color(Color::black)
, m_lineCap(SkPaint::kDefault_Cap)
, m_lineJoin(SkPaint::kDefault_Join)
, m_miterLimit(4)
@@ -61,17 +60,6 @@ public:
float thickness() const { return m_thickness; }
void setThickness(float thickness) { m_thickness = thickness; }
- Color color() const { return m_color; }
- void setColor(const Color& color) { m_color = color; }
-
- Gradient* gradient() const { return m_gradient.get(); }
- void setGradient(const PassRefPtr<Gradient> gradient) { m_gradient = gradient; }
- void clearGradient() { m_gradient.clear(); }
-
- Pattern* pattern() const { return m_pattern.get(); }
- void setPattern(const PassRefPtr<Pattern> pattern) { m_pattern = pattern; }
- void clearPattern() { m_pattern.clear(); }
-
LineCap lineCap() const { return (LineCap)m_lineCap; }
void setLineCap(LineCap cap) { m_lineCap = (SkPaint::Cap)cap; }
@@ -97,9 +85,6 @@ public:
private:
StrokeStyle m_style;
float m_thickness;
- Color m_color;
- RefPtr<Gradient> m_gradient;
- RefPtr<Pattern> m_pattern;
SkPaint::Cap m_lineCap;
SkPaint::Join m_lineJoin;
float m_miterLimit;
« no previous file with comments | « Source/platform/graphics/GraphicsContextState.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698