cupertino_superellipse 1.0.0
cupertino_superellipse: ^1.0.0 copied to clipboard
Flutter Cupertino Superellipse
Flutter Cupertino Superellipse #
Formula-based superellipse implementation for Flutter. Compared to traditional BorderRadius it provides more optically balanced shape:

Usage #
1. Depend
Add this to you package's pubspec.yaml file:
dependencies:
cupertino_superellipse: ^1.0.0
2. Install
Run command:
$ flutter packages get
3. Import
Import in Dart code:
import 'packages:cupertino_superellipse/cupertino_superellipse.dart';
4. Usage example
// n: superellipse n>2 property
// corners: square/rounded corners (BR, BL, TL, TR)
new Material(
clipBehavior: Clip.antiAlias,
shape: SuperEllipse(
n: 4,
corners: [true, true, true, true],
),
color: Colors.white,
child: new Container(
height: 300,
width: 300,
),
),