Flutter Engine
The Flutter Engine
SkSVGAttribute.cpp
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
9
12
14 result.fFillOpacity.set(SkSVGNumberType(1));
17
20 result.fStrokeDashOffset.set(SkSVGLength(0));
21 result.fStrokeLineCap.set(SkSVGLineCap::kButt);
23 result.fStrokeMiterLimit.set(SkSVGNumberType(4));
24 result.fStrokeOpacity.set(SkSVGNumberType(1));
25 result.fStrokeWidth.set(SkSVGLength(1));
26
28
30 result.fColorInterpolation.set(SkSVGColorspace::kSRGB);
31 result.fColorInterpolationFilters.set(SkSVGColorspace::kLinearRGB);
32
33 result.fFontFamily.init("Sans");
35 result.fFontSize.init(SkSVGLength(24));
36 result.fFontWeight.init(SkSVGFontWeight::Type::kNormal);
37 result.fTextAnchor.init(SkSVGTextAnchor::Type::kStart);
38
39 result.fDisplay.init(SkSVGDisplay::kInline);
40
41 result.fStopColor.set(SkSVGColor(SK_ColorBLACK));
42 result.fStopOpacity.set(SkSVGNumberType(1));
43 result.fFloodColor.set(SkSVGColor(SK_ColorBLACK));
44 result.fFloodOpacity.set(SkSVGNumberType(1));
45 result.fLightingColor.set(SkSVGColor(SK_ColorWHITE));
46
47 return result;
48}
constexpr SkColor SK_ColorBLACK
Definition: SkColor.h:103
constexpr SkColor SK_ColorWHITE
Definition: SkColor.h:122
SkColor SkSVGColorType
Definition: SkSVGTypes.h:25
SkScalar SkSVGNumberType
Definition: SkSVGTypes.h:27
GAsyncResult * result
static SkSVGPresentationAttributes MakeInitial()