ios - Get Height of UIImage inside UIimageView *aspectFill -
i have uitableview tableview.backgroundview containing uiimage. trying attain height of image once set in imageview - uiviewcontentmodescaleaspectfill. tableview setcontentinset whatever height of image entire image in view.
uiview *backview = [[uiview alloc]initwithframe:cgrectmake(0, yvalue, [[uiscreen mainscreen] bounds].size.width, 100)]; coverimageview = backview.frame; coverimageview.contentmode = uiviewcontentmodescaleaspectfill; coverimageview.image = [uiimage imagewithdata:data]; [backview addsubview:coverimageview]; self.tableview.backgroundview = backview; [self.tableview setcontentinset:uiedgeinsetsmake(coverimageview.frame.size.height, 0, 0, 0)]; this understandably gives me imageview height. unsure how image height uiviewcontentmodescaleaspectfill
Comments
Post a Comment