Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Flutter – while using (dotted border package) unable to round the border (radius values are not working)

even after changing the radius value border still remains the same

Widget AddTask() {
  return DottedBorder(
      borderType: BorderType.Rect,
      radius: const Radius.circular(30),
      dashPattern: const [10, 10],
      color: Colors.grey,
      strokeWidth: 2,
      child: const Center(
        child: Text(
          "+ Add",
          style: TextStyle(fontSize: 18, fontWeight: FontWeight.bold),
        ),
      ));
}

>Solution :

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

Use borderType: BorderType.RRect, instead of borderType: BorderType.Rect, please note Rect has an R prefix. R stands for rounded.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading