draw method

  1. @override
void draw(
  1. Canvas canvas,
  2. FlSpot spot,
  3. Offset offsetInCanvas
)
override

Implementation of the parent class to draw the circle

Implementation

@override
void draw(Canvas canvas, FlSpot spot, Offset offsetInCanvas) {
  if (strokeWidth != 0.0 && strokeColor.opacity != 0.0) {
    canvas.drawCircle(
      offsetInCanvas,
      radius + (strokeWidth / 2),
      Paint()
        ..color = strokeColor
        ..strokeWidth = strokeWidth
        ..style = PaintingStyle.stroke,
    );
  }
  canvas.drawCircle(
    offsetInCanvas,
    radius,
    Paint()
      ..color = color
      ..style = PaintingStyle.fill,
  );
}