flutter_scatter icon indicating copy to clipboard operation
flutter_scatter copied to clipboard

I want the border to be a rectangle, not a circle how do I set that

Open hlovingness opened this issue 6 years ago • 2 comments

I want the border to be a rectangle, not a circle how do I set that

hlovingness avatar Nov 22 '19 08:11 hlovingness

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,
      )),
    );
  }

anikkcah avatar Feb 21 '20 02:02 anikkcah

thinks

hlovingness avatar Mar 04 '20 01:03 hlovingness