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

Method drawForeground

snap_drawing/src/snap_drawing/cpp/Layers/Layer.cpp:190–204  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

188}
189
190void Layer::drawForeground(Scalar width, Scalar height) {
191 DrawingContext drawingContext(width, height);
192
193 if (_borderWidth != 0) {
194 Paint paint;
195 paint.setStroke(true);
196 paint.setColor(_borderColor);
197 paint.setStrokeWidth(_borderWidth);
198 paint.setAntiAlias(true);
199
200 drawingContext.drawPaint(paint, _borderRadius, _lazyPath);
201 }
202
203 _cachedForeground = drawingContext.finish();
204}
205
206bool Layer::hasOverlappingRendering() const {
207 return getChildrenSize() > 0;

Callers

nothing calls this directly

Calls 6

setAntiAliasMethod · 0.80
drawPaintMethod · 0.80
setStrokeMethod · 0.45
setColorMethod · 0.45
setStrokeWidthMethod · 0.45
finishMethod · 0.45

Tested by

no test coverage detected