A couple of minor appearance problems


Hi guys! I’m hoping that these are both really easy fixes and I’ve missed them in the documentation somewhere:

  1. How can I center the annontations over data points for a SChartCategoryAxis?
  2. How can I remove the 1 pixel white gap between the axis border and the columns?

Has anyone come across this before?


Hi Tony,

Did you attach an image of these issues you’re having? It looks like it didn’t work. Do you think you could try again, then we can have a look at what is going wrong?



Hi Chris, it should be right now.


Right, so I’ve got the labels aligning by subtracting (and adding) 0.2 to the x value of the annotation, and this seems to work for this specific setup.

I still can’t for the life of my work out how to get rid of the white line right above the x axis. Any help with that would be much appreciated.


Hi Tony,

I’ve managed to reproduce the issue you’ve been having by doing this:

_chart.plotAreaBorderColor = [UIColor whiteColor];
_chart.plotAreaBorderThickness = 2.0f;

Do you have any code like this in your project? If you just don’t set the plotAreaBorder thickness (it’s default is zero) then the problem should go away.

Let me know if this helps and if you still have issues then please let me know.



Hi Chris, I had a few calls setting plotAreaBorderThickness to 0.f, but nothing aside from that. Removing those calls makes no difference to the white, and I’ve verified that I’m not setting anything related to the plotAreaBorder, nor am I setting a default theme.


Okay, could you try setting your plotAreaBackgroundColor to red and see if there’s still a 1px gap? A screenshot of the result would probably help if possible! Thanks.


Here you go:


Hi Tony,

That’s really strange. I can’t see a way that would happen without setting the plotAreaBorder thickness. Do you think you could post your code that you use to style your chart? If you want to send it to info@shinobicontrols.com I’ll happily take a look at it for you and see what is going on here.

It would also be good to get a bit more information. Does it always happen? Does it only happen on Retina devices, Non-Retina or both? What happens if you do set the plotAreaBorder to 2 and give it a colour of blue? Is there still a gap?



Hi Chris, setting the plotAreaBorder to be 2px and blue results in the following:

So it looks like something else is causing the x-axis to “fall away” from the plot area…