flutter_scatter
flutter_scatter copied to clipboard
I want the border to be a rectangle, not a circle how do I set that
I want the border to be a rectangle, not a circle how do I set that
Filename: circle.dart change the below mentioned line in 'Widget build(BuildContext context)' function to change the border elements.
@override
Widget build(BuildContext context) {
final TextStyle style = Theme.of(context).textTheme.body1.copyWith(
color: Colors.deepPurple,
);
return Container(
height: 40.0,
width: 40.0,
decoration: BoxDecoration(
shape: BoxShape.rectangle, //I have changed the shape here
color: index.isEven ? Colors.red : Colors.pink),
child: Center(
child: Text(
'$index',
style: style,
)),
);
}
thinks