UITabBarItem正常状态下的字体颜色
[[UITabBarItem appearance] setTitleTextAttributes:[NSDictionary dictionaryWithObjectsAndKeys:[UIColor colorWithRed:154.0/255 green:254.0/255 blue:158.0/255 alpha:1.0], NSForegroundColorAttributeName, nil] forState:UIControlStateNormal];
加了如上设置之后
controller.tabBar.tintColor = [UIColor whiteColor];UITabbarController的tintColor将会对选中时的字体无效
所以还需加上如下设置
UITabBarItem选中状态下的字体颜色
[[UITabBarItem appearance] setTitleTextAttributes:[NSDictionary dictionaryWithObjectsAndKeys:[UIColor whiteColor], NSForegroundColorAttributeName, nil] forState:UIControlStateSelected];