2016-07-27 01:46:34 +00:00
|
|
|
/*
|
|
|
|
* Copyright 2016 Google Inc.
|
|
|
|
*
|
|
|
|
* Use of this source code is governed by a BSD-style license that can be
|
|
|
|
* found in the LICENSE file.
|
|
|
|
*/
|
|
|
|
|
2019-04-23 17:05:21 +00:00
|
|
|
#include "experimental/svg/model/SkSVGAttribute.h"
|
2016-07-27 01:46:34 +00:00
|
|
|
|
2016-08-11 16:16:29 +00:00
|
|
|
SkSVGPresentationAttributes SkSVGPresentationAttributes::MakeInitial() {
|
|
|
|
SkSVGPresentationAttributes result;
|
2016-07-27 01:46:34 +00:00
|
|
|
|
2016-08-11 16:16:29 +00:00
|
|
|
result.fFill.set(SkSVGPaint(SkSVGColorType(SK_ColorBLACK)));
|
|
|
|
result.fFillOpacity.set(SkSVGNumberType(1));
|
2016-12-01 18:35:11 +00:00
|
|
|
result.fFillRule.set(SkSVGFillRule(SkSVGFillRule::Type::kNonZero));
|
2017-10-10 15:22:08 +00:00
|
|
|
result.fClipRule.set(SkSVGFillRule(SkSVGFillRule::Type::kNonZero));
|
2016-07-27 01:46:34 +00:00
|
|
|
|
2016-08-11 16:16:29 +00:00
|
|
|
result.fStroke.set(SkSVGPaint(SkSVGPaint::Type::kNone));
|
2017-10-13 18:07:44 +00:00
|
|
|
result.fStrokeDashArray.set(SkSVGDashArray(SkSVGDashArray::Type::kNone));
|
2017-10-13 22:18:32 +00:00
|
|
|
result.fStrokeDashOffset.set(SkSVGLength(0));
|
2016-08-11 16:16:29 +00:00
|
|
|
result.fStrokeLineCap.set(SkSVGLineCap(SkSVGLineCap::Type::kButt));
|
|
|
|
result.fStrokeLineJoin.set(SkSVGLineJoin(SkSVGLineJoin::Type::kMiter));
|
2017-10-09 16:57:41 +00:00
|
|
|
result.fStrokeMiterLimit.set(SkSVGNumberType(4));
|
2016-08-11 16:16:29 +00:00
|
|
|
result.fStrokeOpacity.set(SkSVGNumberType(1));
|
|
|
|
result.fStrokeWidth.set(SkSVGLength(1));
|
2016-07-27 01:46:34 +00:00
|
|
|
|
2017-10-12 15:33:28 +00:00
|
|
|
result.fVisibility.set(SkSVGVisibility(SkSVGVisibility::Type::kVisible));
|
|
|
|
|
2016-08-11 16:16:29 +00:00
|
|
|
return result;
|
2016-07-27 01:46:34 +00:00
|
|
|
}
|