如何在iOS 7.1的UITabBar上更改图像和标签的颜色? [英] How can I change a color of image and label on UITabBar on iOS 7.1?
本文介绍了如何在iOS 7.1的UITabBar上更改图像和标签的颜色?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何在iOS 7.1上更改 UITabBar
上的图片和标签颜色?在iOS 7上,我可以使用 Tint
属性。但是在iOS 7.1上,它不起作用。
How can I change a color of image and label on UITabBar
on iOS 7.1? On iOS 7 I could make it by Tint
property. But on iOS 7.1 it doesn't work.
推荐答案
选择时,这会更改图像和标签的色调。
This changes the tint of both the image and the label, when selected.
- (void)viewDidLoad
{
[super viewDidLoad];
[[UITabBar appearance] setTintColor:[UIColor redColor]];
}
这篇关于如何在iOS 7.1的UITabBar上更改图像和标签的颜色?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文