Android PieChart Scrolling


#1

Hi there,

I trying create a shinobi pie chart, But I am facing some problems. Pls tell me how can I solve this.
Problems  are

1. Pie chart legent is coming over char so chart is not completely visible. So how can I make it scrollable or display legend below chart?

2. How can I show %ge on pie section? Will it make it itsellf or i have calculate it ?

3.Pie chart legend is not srolling horizontally. Despite I have set the Horizontal scrollbar property to true.


#2

Hi.

Our API does offer some control over position and placement of the legend in relation to the plot area and the chart. You can control the position of the legend relative to its chart using the following API:

https://www.shinobicontrols.com/docs/ShinobiControls/ShinobiChartsAndroid/1.7.2/Premium/Normal/apidocs/docs/reference/com/shinobicontrols/charts/Legend.html#setPosition(com.shinobicontrols.charts.Legend.Position)

You can control the placement of the legend relative to the chart’s plot area using the following API:

https://www.shinobicontrols.com/docs/ShinobiControls/ShinobiChartsAndroid/1.7.2/Premium/Normal/apidocs/docs/reference/com/shinobicontrols/charts/Legend.html#setPlacement(com.shinobicontrols.charts.Legend.Placement)

To show custom labels on your PieChart, please see the following blog post:

This should help you add a percentage figure to your labels.

Please note that the chart will not calculate percentage figures for you, you would need to calculate this yourself.

Our current Legend does not offer vertical scrolling, it is in fact quite a basic implementation, which does tend to be suitable for most cases. We do have an item in our backlog which covers the improvement of our Legend class, to include features such as vertical scrolling. What we have found is that the current demand for such features is quite low, as most customers who require a more advanced Legend tend to add their own custom implementation. 

What I will do is add to our backlog item your interest in this feature. If you would like us to inform you if and when such a feature becomes available, please contact us at info@shinobicontrols.com


#3

Hi, Thanks for replying to my first post. But the solution you suggested didn’t work. Leave my chart, even your sample chart is unable to display legend and pie. I have tried many things, I tried with the different position for the legend. No matter what legend always comes either over the pie or truncates. I have downloaded the sample from here, https://github.com/shinobicontrols/charts-pie-chart-labels-android. Legend always looks ugly on the mobile device. Btw I tried your sample in moto g4. 


#4

Hi, Thanks for replying to my first post. But the solution you suggested didn’t work. Leave my chart, even your sample chart is unable to display legend and pie. I have tried many things, I tried with the different position for the legend. No matter what legend always comes either over the pie or truncates. I have downloaded the sample from here, https://github.com/shinobicontrols/charts-pie-chart-labels-android. Legend always looks ugly on the mobile device. Btw I tried your sample in moto g4. 


#5

Hi.

Could you please post some screen shots of your issue? Ideally, also please post a snippet of the code which you are using to set up your PieSeries and Legend?

Thanks,

Kai