Display label outside of Pie chart


I read this post
but I’m getting crash at getSliceCenter for “index 0 beyond bounds for empty array”
I’m wondering if there’s any Swift version I can refer to


Hi spikereg,

If you’re trying to add spokes to your pie chart then, since v2.8.0 of shinobicharts, there’s a much easier way than that described in the blog post. Spokes are now supported out-of-the-box and are enabled by setting style.spokeStyle.showSpokes = YES on the pie/donut series’ style object.

There’s a more detailed explanation of how to use spokes in the shinobicharts userguide.

I hope that helps.



Thanks for your answer! The problem is, that certain slices could have the same background color since these can be assigned by the users. This means that users can no longer distinguish which one which is.


Hi @klimbo23,

If you have multiple slices that are the same color, then adding data point labels should help distinguish them. You can read more about adding labels to pie or donut charts at https://www.shinobicontrols.com/docs/ios/shinobicharts/latest/labels-and-legends.html

I hope that helps.