UiPaint.stroke constructor

UiPaint.stroke({
  1. int? color,
  2. double? strokeWidth,
  3. MapCap? cap,
  4. MapJoin? join,
  5. List<double>? strokeDasharray,
})

Creates a new paint object for stroking paths.

Implementation

UiPaint.stroke({int? color, double? strokeWidth, MapCap? cap, MapJoin? join, List<double>? strokeDasharray})
  : _paint = ui.Paint()..style = ui.PaintingStyle.stroke {
  if (color != null) _paint.color = Color(color);
  if (strokeWidth != null) _paint.strokeWidth = strokeWidth;
  if (cap != null) setStrokeCap(cap);
  if (join != null) setStrokeJoin(join);
  if (strokeDasharray != null) _strokeDasharray = strokeDasharray;
}