paint method

  1. @override
void paint(
  1. Context context
)
override

Draw itself and its children, according to the calculated box.offset

Implementation

@override
void paint(Context context) {
  super.paint(context);

  context.canvas
    ..setStrokeColor(color)
    ..moveTo(box!.x, box!.y)
    ..lineTo(box!.right, box!.top)
    ..moveTo(box!.x, box!.top)
    ..lineTo(box!.right, box!.y)
    ..drawBox(box!)
    ..setLineWidth(strokeWidth)
    ..strokePath();
}