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 SkSVGCircle_DEFINED |
| 9 #define SkSVGCircle_DEFINED |
| 10 |
| 11 #include "SkSVGShape.h" |
| 12 #include "SkSVGTypes.h" |
| 13 |
| 14 class SkSVGCircle final : public SkSVGShape { |
| 15 public: |
| 16 virtual ~SkSVGCircle() = default; |
| 17 static sk_sp<SkSVGCircle> Make() { return sk_sp<SkSVGCircle>(new SkSVGCircle
()); } |
| 18 |
| 19 void setCx(const SkSVGLength&); |
| 20 void setCy(const SkSVGLength&); |
| 21 void setR(const SkSVGLength&); |
| 22 |
| 23 protected: |
| 24 void onSetAttribute(SkSVGAttribute, const SkSVGValue&) override; |
| 25 |
| 26 void onDraw(SkCanvas*, const SkSVGLengthContext&, const SkPaint&) const over
ride; |
| 27 |
| 28 private: |
| 29 SkSVGCircle(); |
| 30 |
| 31 SkSVGLength fCx = SkSVGLength(0); |
| 32 SkSVGLength fCy = SkSVGLength(0); |
| 33 SkSVGLength fR = SkSVGLength(0); |
| 34 |
| 35 typedef SkSVGShape INHERITED; |
| 36 }; |
| 37 |
| 38 #endif // SkSVGCircle_DEFINED |
OLD | NEW |