I am creating Linear Percent Indicator. I want to achieve rounded borders around it.
Expected Result Vs. Actual Result
My Code
LinearPercentIndicator(
linearStrokeCap: LinearStrokeCap.roundAll,
progressColor: Colors.blue[400],
backgroundColor: Colors.grey[300],
),
Error
Any Solution
Any solution to use barRadius as LinearStrokeCap?
CodePudding user response:
Use barRadius instead of linearStrokeCap. as LinearStrokeCap is deprecated they are suggesting to use barRadius.
Updated code :
LinearPercentIndicator(
lineHeight: 30,
percent: 0.7,
barRadius: const Radius.circular(16),
progressColor: Colors.blue[400],
backgroundColor: Colors.grey[300],
),
Output:



