I have a UIImage that I want to draw on a UIView . But instead of creating a UIImageView and adding this as a preview, I want to overwrite -drawRect: and draw the UIView directly.
For example, my code looks like this:
- (void)drawRect:(CGRect)rect { CGContextRef myContext = UIGraphicsGetCurrentContext(); UIImage *img = [UIImage imageNamed:@"foo.png"];
iphone cocoa-touch uiimage drawrect
HelloMoon Nov 02 '09 at 21:27 2009-11-02 21:27
source share