OLD | NEW |
(Empty) | |
| 1 /* |
| 2 * Copyright 2016 Google Inc. |
| 3 * |
| 4 * Use of this source code is governed by a BSD-style license that can be |
| 5 * found in the LICENSE file. |
| 6 */ |
| 7 |
| 8 #ifndef SkSVGAttribute_DEFINED |
| 9 #define SkSVGAttribute_DEFINED |
| 10 |
| 11 #include "SkColor.h" |
| 12 #include "SkTLazy.h" |
| 13 |
| 14 enum class SkSVGAttribute { |
| 15 d, |
| 16 fill, |
| 17 stroke, |
| 18 transform, |
| 19 }; |
| 20 |
| 21 class SkSVGRenderContext; |
| 22 |
| 23 class SkSVGPresentationAttributes { |
| 24 public: |
| 25 SkSVGPresentationAttributes(); |
| 26 |
| 27 void setFill(SkColor); |
| 28 void setStroke(SkColor); |
| 29 |
| 30 void applyTo(SkTCopyOnFirstWrite<SkSVGRenderContext>&) const; |
| 31 |
| 32 private: |
| 33 // Color only for now. |
| 34 SkColor fFill; |
| 35 SkColor fStroke; |
| 36 |
| 37 unsigned fFillIsSet : 1; |
| 38 unsigned fStrokeIsSet : 1; |
| 39 }; |
| 40 |
| 41 #endif // SkSVGAttribute_DEFINED |
OLD | NEW |