【发布时间】:2012-05-29 11:25:02
【问题描述】:
我正在尝试从Class A 调用绘图方法,例如,位于Class B 的方法,正在调用该方法但没有绘图发生。
- (void)drawIt
{
CGContextRef context = UIGraphicsGetCurrentContext();
CGContextSetFillColorWithColor(context, [UIColor whiteColor].CGColor);
NSString *string = [NSString stringWithString:@"TEXT"];
[string drawAtPoint:CGPointMake(12, 51) withFont:[UIFont fontWithName:@"Helvetica" size:35.0f]];
}
为什么我可以从其他类调用这个方法?
【问题讨论】:
标签: iphone ios objective-c quartz-graphics quartz-2d