path.moveTo(size.width / 2, 0); // ... lines ... path.close(); final paint = Paint() ..color = color ..style = PaintingStyle.fill; canvas.drawPath(path, paint);