2.5.4. PieChart
The PieChart component allows you to create pie/donut charts.
Figure 17. PieChart
XML name of the component: chart:pieChart.
- Data binding:
-
-
Using a data container.
You can assign a
CollectionContainerto the chart and then define thetitleFieldandvalueFieldattributes for thepieChartelement:<chart:pieChart id="pieChart" dataContainer="countryLitresDc" height="100%" titleField="country" valueField="litres" width="100%"/> -
Using the chart:data element.
-
-
PieChartevent listeners: -
-
ChartClickListener– click on the canvas. -
ChartRightClickListener– right click on the canvas. -
SliceClickListener– click on a slice in a pie chart. -
SlicePullInListener– shift of a slice of a pie chart into the chart. -
SlicePullOutListener– shift of a slice of a pie chart out of the chart. -
SliceRightClickListener– right-click on a slice in a pie chart.
-
For more details, see AmCharts documentation.