MCPcopy Create free account
hub / github.com/Snapchat/Valdi / onInitialize

Method onInitialize

snap_drawing/src/snap_drawing/cpp/Layers/ShapeLayer.cpp:16–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

14ShapeLayer::~ShapeLayer() = default;
15
16void ShapeLayer::onInitialize() {
17 _strokePaint.setAntiAlias(true);
18 _strokePaint.setStroke(true);
19 _fillPaint.setAntiAlias(true);
20 _fillPaint.setStroke(false);
21
22 setStrokeCap(PaintStrokeCapButt);
23 setStrokeJoin(PaintStrokeJoinMiter);
24 setFillColor(Color::transparent());
25 setStrokeColor(Color::transparent());
26 setStrokeWidth(1);
27}
28
29void ShapeLayer::onDraw(DrawingContext& drawingContext) {
30 const auto& path = getActivePath();

Callers

nothing calls this directly

Calls 2

setAntiAliasMethod · 0.80
setStrokeMethod · 0.45

Tested by

no test coverage detected