Flutter Engine
The Flutter Engine
SkSVGCircle.h
Go to the documentation of this file.
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
13
14struct SkPoint;
15
16class SK_API SkSVGCircle final : public SkSVGShape {
17public:
19
23
24protected:
25 bool parseAndSetAttribute(const char*, const char*) override;
26
27 void onDraw(SkCanvas*, const SkSVGLengthContext&, const SkPaint&,
28 SkPathFillType) const override;
29
30 SkPath onAsPath(const SkSVGRenderContext&) const override;
31
32 SkRect onObjectBoundingBox(const SkSVGRenderContext&) const override;
33
34private:
36
37 // resolve and return the center and radius values
38 std::tuple<SkPoint, SkScalar> resolve(const SkSVGLengthContext&) const;
39
40 using INHERITED = SkSVGShape;
41};
42
43#endif // SkSVGCircle_DEFINED
#define SK_API
Definition: SkAPI.h:35
SkPathFillType
Definition: SkPathTypes.h:11
#define INHERITED(method,...)
Definition: SkRecorder.cpp:128
#define SVG_ATTR(attr_name, attr_type, attr_default)
Definition: SkSVGNode.h:210
Definition: SkPath.h:59
static sk_sp< SkSVGCircle > Make()
Definition: SkSVGCircle.h:18
float SkScalar
Definition: extension.cpp:12
#define R(r)
Definition: ref_ptr.h:256