onPaint method

  1. @override
void onPaint(
  1. Canvas canvas
)
override

Draws segment in series bounds.

Implementation

@override
void onPaint(Canvas canvas) {
  final RangeAreaSeries<dynamic, dynamic> _series =
      this._series as RangeAreaSeries<dynamic, dynamic>;
  _pathRect = _path.getBounds();
  canvas.drawPath(
      _path, (_series.gradient == null) ? fillPaint! : getFillPaint());
  strokePaint = getStrokePaint();
  if (strokePaint!.color != Colors.transparent) {
    _drawDashedLine(
        canvas,
        _series.dashArray,
        strokePaint!,
        _series.borderDrawMode == RangeAreaBorderMode.all
            ? _path
            : _borderPath!);
  }
}