dependencies: pie_chart: <latest version>
import 'package:pie_chart/pie_chart.dart';
Map<String, double> dataMap = new Map();
dataMap.putIfAbsent("Flutter", () => 5);
dataMap.putIfAbsent("React", () => 3);
dataMap.putIfAbsent("Xamarin", () => 2);
dataMap.putIfAbsent("Ionic", () => 2);
PieChart(
dataMap: dataMap,
legendFontColor: Colors.blueGrey[900],
legendFontSize: 14.0,
legendFontWeight: FontWeight.w500,
animationDuration: Duration(milliseconds: 800),
chartLegendSpacing: 32.0,
chartRadius: MediaQuery
.of(context)
.size
.width / 2.7,
showChartValuesInPercentage: true,
showChartValues: true,
chartValuesColor: Colors.blueGrey[900].withOpacity(0.9),
)
Android Studio Setup Open Android Studio and select Configure->Plugins 2. Click Browse repositories… ...