今のところ、コアプロットで描いた折れ線グラフは次のようになっています。
ご覧のとおり、プロットのラベルの一部が重なっています。(x軸のラベルが表示されているように)縦に表示できればいいと思いました。どうすればいいのですか?
これは、dataLabelForPlotのコードスニペットです。
-(CPTLayer *) dataLabelForPlot:(CPTPlot *)plot recordIndex:(NSUInteger)index {
NSString *currentlabel = [lineChartPlotXLabel objectAtIndex:index];
CPTMutableTextStyle *textStyle = [[CPTMutableTextStyle alloc] init];
textStyle.color = [CPTColor darkGrayColor];
textStyle.fontSize = 10.0f;
textStyle.fontName = @"Helvetica";
CPTLayer *layer = [[CPTLayer alloc]
initWithFrame:CGRectMake(0.0, 0.0, 70.0, 20.0)];
CPTTextLayer *newLayer = nil;
newLayer = [[CPTTextLayer alloc] initWithText:currentlabel style:textStyle];
[layer addSublayer:newLayer];
return layer;
}