I have tabbar icon size of 30x30. When i set these icons to tabbar, images are stretching for iphone4 & iphone5 screen sizes. Why?
UINavigationController *hndWriteNav = [[UINavigationController alloc] initWithRootViewController:hndWrite];
hndWriteNav.tabBarItem.image = [UIImage imageNamed:@"browse.png"];
[hndWriteNav setTitle:@"Browse"];
[hndWrite release];
You need to create two separate icons browse.png (30x30) and browse@2x.png (60x60) .
iOS will automatically load the right file based on the screen scale.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.