title: How to clip the corners of Positioned widget in flutter
body: <p>Here is the output which I am getting:</p>
  <p><a href="https://i.stack.imgur.com/baWUb.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/baWUb.png" alt="enter image description here" /></a></p>
  <p>I want to clip the green Positioned widget on corners with that of grey Container's rounded corners.
  Any Help will be highly appreciated.</p>
  <p>My current code:</p>
  <pre><code>import 'package:flutter/material.dart';
  
  void main() {
    runApp(MyApp());
  }
  
  class MyApp extends StatelessWidget {
    @override
    Widget build(BuildContext context) {
      return MaterialApp(
        title: 'Flutter Demo',
        theme: ThemeData(
          primarySwatch: Colors.blue,
        ),
        home: CustomCard(
            title: 'Custom Card', percentage: 50.0, color: Colors.green),
      );
    }
  }
  
  class CustomCard extends StatelessWidget {
    final String title;
    final double percentage;
    final Color color;
    CustomCard(
        {required this.title, required this.percentage, required this.color});
    @override
    Widget build(BuildContext context) {
      double width = MediaQuery.of(context).size.width;
      return Scaffold(
        appBar: AppBar(
          title: Text(title),
        ),
        body: Padding(
          padding: const EdgeInsets.all(8.0),
          child: Stack(clipBehavior: Clip.antiAliasWithSaveLayer, children: [
            Container(
              height: 100.0,
              width: width,
              decoration: BoxDecoration(
                borderRadius: BorderRadius.circular(10),
                color: Colors.grey,
              ),
            ),
            Positioned(
              left: -(percentage / 100) * width,
              top: -(percentage / 100) * width,
              child: Container(
                height: (percentage / 100) * width * 2,
                width: (percentage / 100) * width * 2,
                decoration: BoxDecoration(
                  borderRadius:
                      BorderRadius.circular(((percentage / 100) * width)),
                  color: color,
                ),
              ),
            ),
          ]),
        ),
      );
    }
  }
  </code></pre>
  <p>Thank You.</p>