Fork me on GitHub

2012年4月21日

摘要: To extend on the subject, ...without crashing? I load about 15 full size images from the photo library in UIImageViews and get out of memory warnings and eventually an app crash. These images range from around 250KB to 400KB. The UIImageViews are set to aspect fit.The photo library seems to load sma 阅读全文
posted @ 2012-04-21 13:22 pengyingh 阅读(320) 评论(0) 推荐(0)
摘要: http://bbs.weiphone.com/read-htm-tid-95491.html我的代码做了如下:NSString* sCands = [NSString stringWithUTF8String:"欢迎"];//struct __GSFont * font=[NSClassFromString(@"WebFontCache") createFontWithFamily:@"STHeiti" traits:2 size:18.];//struct __GSFont * font=GSFontCreateWithName( 阅读全文
posted @ 2012-04-21 13:06 pengyingh 阅读(878) 评论(0) 推荐(0)
摘要: I load a UIImageView with an image depending on user interaction. When the parent view is initially displayed, no image has been selected and the imageview is black. If the user leaves that view and comes back, the image is still there. I've triedmyImageView.image = nil;upon leaving the view but 阅读全文
posted @ 2012-04-21 12:53 pengyingh 阅读(436) 评论(0) 推荐(0)
摘要: http://stackoverflow.com/questions/3838725/what-is-the-difference-between-uiimageview-and-drawinrectI want to display so many images in table cells. I knew two methods to show an image.One is creating an instance to UIImageView and show itCGRect rect=CGRectMake(x,y,width,height);UIImageView*image=[[ 阅读全文
posted @ 2012-04-21 12:51 pengyingh 阅读(1031) 评论(0) 推荐(0)
摘要: Hi, I'm trying to correct the camera's image orientation.I'm using this function lifted out of a book but it's returning an image.Can you see what's wrong?I'm using ios 5.- (UIImage *)fixOrientation: (UIImage *) image{ CGSize size = image.size; if (image.imageOrientation == U 阅读全文
posted @ 2012-04-21 12:15 pengyingh 阅读(221) 评论(0) 推荐(0)

导航