UIKitのデバッグに使えるものを集めました。

四角形を描く

- (void)addSquare:(CGPoint) origin
{
   UIView *view = [[[UIView alloc]initWithFrame:CGRectMake(origin.x, origin.y, 10, 10)]autorelease];
   [view setBackgroundColor:[UIColor redColor]];
   [self.view addSubview:view];
}

最終更新:2011年09月22日 13:01