Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
55
Customizing the Axis
posted

Hi,

I have a couple of issues:

1. I was looking into customizing the axis strokes but setting the colors doesn't seem to work. 

    IGCategoryAxisBase* axis = [[[IGCategoryXAxis class] allocinitWithKey:key];

    [axis setOverlap:self.model.graph.overlap];

    [axis setGap:self.model.graph.gap];

    [axis setMajorStrokeThickness:7.0f];

    [axis setMinorStrokeThickness:3.0f];

    [axis setStrokeThickness:5.0f];

    [axis setLabelsVisible:YES];

    [axis setMinorStroke:[[IGBrush alloc] initWithColor:[UIColor redColor]]];

    [axis setStroke:[[IGBrush alloc] initWithColor:[UIColor purpleColor]]];

    [axis setMajorStroke:[[IGBrush alloc] initWithColor:[UIColor blueColor]]];

    [axis setTickLength:0.0f];

2. In Android, there is a way to not display the first label in the axis using: axis.setShowFirstLabel(false);, but the method doesn't seem to be available in iOS. Is there a way that this can be achieved in iOS?

3. In Android, there is a way to customize the axis label using: axis.setLabelTextSize(16);, but the method doesn't seem to be available in iOS. Is there a way that this can be achieved in iOS?