21 if (
this == node.
get()) {
24 node->
render(localContext);
36 auto viewPort =
SkSize::Make(viewPortRect.width(), viewPortRect.height());
38 if (fViewBox.isValid()) {
39 const SkRect& viewBox = *fViewBox;
52 if (!contentMatrix.isIdentity()) {
88 this->setViewBox(*vb);
93 this->setPreserveAspectRatio(*par);
void concat(const SkMatrix &matrix)
static SkMatrix Translate(SkScalar dx, SkScalar dy)
void onRender(const SkSVGRenderContext &) const override
void setViewPort(const SkSize &viewport)
SkRect resolveRect(const SkSVGLength &x, const SkSVGLength &y, const SkSVGLength &w, const SkSVGLength &h) const
const SkSize & viewPort() const
SkScalar resolve(const SkSVGLength &, LengthType) const
void render(const SkSVGRenderContext &) const
static SkMatrix ComputeViewboxMatrix(const SkRect &, const SkRect &, SkSVGPreserveAspectRatio)
const SkSVGNode * get() const
SkSVGLengthContext * writableLengthContext()
BorrowedNode findNodeById(const SkSVGIRI &) const
SkCanvas * canvas() const
const SkSVGLengthContext & lengthContext() const
void onSetAttribute(SkSVGAttribute, const SkSVGValue &) override
SkSize intrinsicSize(const SkSVGLengthContext &) const
void renderNode(const SkSVGRenderContext &, const SkSVGIRI &iri) const
bool onPrepareToRender(SkSVGRenderContext *) const override
constexpr float height() const
constexpr float width() const
static constexpr SkSize Make(SkScalar w, SkScalar h)