From 38dc251fd1fc6ad679adced9c1a3e91ca87d95e7 Mon Sep 17 00:00:00 2001 From: kudit Date: Mon, 17 Mar 2014 10:20:19 -0400 Subject: [PATCH] remove warnings Updated drawAtPoint to use the non-deprecated withAttributes: version instead of the withFont: version. Also removed unused yvalueoffset variable. --- OVGraphView/OVGraphView/OVGraphPlotView.m | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/OVGraphView/OVGraphView/OVGraphPlotView.m b/OVGraphView/OVGraphView/OVGraphPlotView.m index a6f2621..d42cf62 100644 --- a/OVGraphView/OVGraphView/OVGraphPlotView.m +++ b/OVGraphView/OVGraphView/OVGraphPlotView.m @@ -157,9 +157,7 @@ - (void)drawRect:(CGRect)rect{ CGContextStrokePath(context); CGContextRestoreGState(context); - [point.xlabel drawAtPoint:CGPointMake(xpoint, self.frame.size.height-20) withFont:[UIFont fontWithName:@"Futura" size:12]]; - int yvalueoffset; - yvalueoffset=0-30; + [point.xlabel drawAtPoint:CGPointMake(xpoint, self.frame.size.height-20) withAttributes:@{NSFontAttributeName:[UIFont fontWithName:@"Futura" size:12]}]; OVGraphYIndicatorView *ind=[[OVGraphYIndicatorView alloc]initWithFrame:CGRectMake(xpoint-15, ypoint-30, 40, 28)]; ind.yValueLabel.text=[point.yvalue stringValue];