customPaint method
Widget
customPaint({
- required CustomPainter painter,
- Key? key,
- CustomPainter? foregroundPainter,
- Size size = Size.zero,
- bool isComplex = false,
- bool willChange = false,
A widget that provides a canvas on which to draw during the paint phase.
Implementation
Widget customPaint({
required CustomPainter painter,
Key? key,
CustomPainter? foregroundPainter,
Size size = Size.zero,
bool isComplex = false,
bool willChange = false,
}) {
return CustomPaint(
key: key,
painter: painter,
foregroundPainter: foregroundPainter,
size: size,
isComplex: isComplex,
willChange: willChange,
child: this,
);
}