TPieChart constructor
const
TPieChart({
- Key? key,
- required String title,
- required List<
PieChartData> data, - VoidCallback? optionTap,
- bool showLegends = true,
- bool showOption = true,
- double? height = 300,
Creates a TPieChart instance.
title: The title of the pie chart.data: A list ofPieChartDatarepresenting chart values.optionTap: An optional callback when the options button is tapped.showLegends: A flag to control the visibility of legends.showOption: A flag to control the visibility of the options button.height: The height of the pie chart.
Implementation
const TPieChart({
super.key,
required this.title,
required this.data,
this.optionTap,
this.showLegends = true,
this.showOption = true,
this.height = 300,
});