This is a migrated thread and some comments may be shown as answers.

Labels for PieChart

2 Answers 85 Views
General Discussion
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Shahir
Top achievements
Rank 1
Shahir asked on 17 Mar 2014, 04:50 PM
I have started working with the pie charts and I'm happy with the way they look. However, I have been having trouble figuring out how to add labels to a pie chart. I found a class "PieSeriesLabelRenderer" which seems like the answer to my problem, but there are no examples or tutorials on how to use it.

Any help is appreciated.

2 Answers, 1 is accepted

Sort by
0
Accepted
Todor
Telerik team
answered on 18 Mar 2014, 07:10 AM
Hi Shahir,

Thank you for your interest in RadChartView for Android.

Here's an article that explains how to use the labels in RadChartView. First of all, in order to display them, you need:
pieSeries.setShowLabels(true);

Then you can customize the appearance as shown in the Customization section of the article. In addition to the listed methods which are applicable for all types of series, with PieSeries, you can use setLabelOffset(double), which allows you to define the distance between the label and the border line of the pie. PieSeriesLabelRenderer is the renderer that we use by default while drawing labels for the chart, but if it doesn't suit you, you can provide your own LabelRenderer implementation as shown in the example.

I hope this information helps. Let us know if you have further questions.

Regards,
Todor
Telerik
 

DevCraft Q1'14 is here! Watch the online conference to see how this release solves your top-5 .NET challenges. Watch on demand now.

 
0
Shahir
Top achievements
Rank 1
answered on 18 Mar 2014, 06:54 PM
Thank you for the reply. Very helpful.
Tags
General Discussion
Asked by
Shahir
Top achievements
Rank 1
Answers by
Todor
Telerik team
Shahir
Top achievements
Rank 1
Share this question
or