strokePath method

  1. @override
void strokePath(
  1. List path,
  2. PStyle style, {
  3. bool closePath = false,
})
override

Stroke a path of points.

Implementation

@override
void strokePath(List path, PStyle style, {bool closePath = false}) {
  var points = _toPoints(path, closePath);
  if (points.length < 2) return;

  var clip = _clip;
  if (clip != null) {
    var box = points.boundingBox;

    if (box == null || !clip.containsRectangle(box)) return;

    _callClipped(clip, box, () => _strokePathImpl(points, style));
  } else {
    _strokePathImpl(points, style);
  }
}