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

Side by Side Diff: experimental/svg/model/SkSVGAttribute.h

Issue 2222793002: [SVGDom] Add <svg> viewBox support (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: typo Created 4 years, 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | experimental/svg/model/SkSVGAttribute.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2016 Google Inc. 2 * Copyright 2016 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef SkSVGAttribute_DEFINED 8 #ifndef SkSVGAttribute_DEFINED
9 #define SkSVGAttribute_DEFINED 9 #define SkSVGAttribute_DEFINED
10 10
11 #include "SkSVGTypes.h" 11 #include "SkSVGTypes.h"
12 #include "SkTLazy.h" 12 #include "SkTLazy.h"
13 13
14 class SkSVGRenderContext;
15
14 enum class SkSVGAttribute { 16 enum class SkSVGAttribute {
15 kD, 17 kD,
16 kFill, 18 kFill,
17 kHeight, 19 kHeight,
18 kStroke, 20 kStroke,
19 kTransform, 21 kTransform,
22 kViewBox,
20 kWidth, 23 kWidth,
21 kX, 24 kX,
22 kY, 25 kY,
23 26
24 kUnknown, 27 kUnknown,
25 }; 28 };
26 29
27 class SkSVGRenderContext;
28
29 class SkSVGPresentationAttributes { 30 class SkSVGPresentationAttributes {
30 public: 31 public:
31 SkSVGPresentationAttributes(); 32 SkSVGPresentationAttributes();
32 33
33 void setFill(const SkSVGColor&); 34 void setFill(const SkSVGColorType&);
34 void setStroke(const SkSVGColor&); 35 void setStroke(const SkSVGColorType&);
35 36
36 void applyTo(SkTCopyOnFirstWrite<SkSVGRenderContext>&) const; 37 void applyTo(SkSVGRenderContext*) const;
37 38
38 private: 39 private:
39 // Color only for now. 40 // Color only for now.
40 SkSVGColor fFill; 41 SkSVGColorType fFill;
41 SkSVGColor fStroke; 42 SkSVGColorType fStroke;
42 43
43 unsigned fFillIsSet : 1; 44 unsigned fFillIsSet : 1;
44 unsigned fStrokeIsSet : 1; 45 unsigned fStrokeIsSet : 1;
45 }; 46 };
46 47
47 #endif // SkSVGAttribute_DEFINED 48 #endif // SkSVGAttribute_DEFINED
OLDNEW
« no previous file with comments | « no previous file | experimental/svg/model/SkSVGAttribute.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698