title: (Flutter) Curved edge to a CustomPaint Widget
body: <p>This is what I want to build:</p>
  
  <p>(Just see the shape of the <code>appBar</code> and not the contents)</p>
  
  <p><a href="https://i.stack.imgur.com/jM2aC.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/jM2aC.png" alt="enter image description here"></a></p>
  
  <p>This is what I have:</p>
  
  <p><a href="https://i.stack.imgur.com/9rxX6m.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/9rxX6m.jpg" alt="enter image description here"></a></p>
  
  <p>I want the edge to be curved, and not so sharp.</p>
  
  <p>Here is my code for the <code>CustomPaint</code>:</p>
  
  <pre><code>class LogoPainter extends CustomPainter {
    @override
    void paint(Canvas canvas, Size size) {
      Paint paint = Paint();
      paint.color = Colors.blue;
      var path = Path();
      path.lineTo(0, size.height - size.height / 5);
      path.lineTo(size.width / 1.2, size.height);
      path.lineTo(size.width, size.height - size.height / 5);
      path.lineTo(size.width, 0);
      path.close();
      canvas.drawPath(path, paint);
    }
  
    @override
    bool shouldRepaint(CustomPainter oldDelegate) {
      return true;
    }
  }
  </code></pre>
  
  <p><strong>How do I achieve this curved edge?</strong></p>
  
  <p>I have tried <code>point.arcToPoint()</code> and <code>point.quadraticBezierTo()</code>, but no success.</p>