/ *テキストにタイトルのフォント、テキストの色、および影のプロパティを指定することもNSAttributedString.hで見つかったキーを使用して、辞書を属性。
効果への中国:あなたはタイトルテキストのフォント、テキストの色と影のプロパティを指定することができますが、辞書を属性、使用キーNSAttributedString.hが見つかりました。
* /
- (ボイド)setTitleTextAttributes :( NULL可能NSDictionaryの< NSStringの*、ID > *)属性forState :( UIControlState )状態NS_AVAILABLE_IOS (5 _0)UI_APPEARANCE_SELECTOR 。
次のコードは、直接フォントカラーラベルを設定するためのプロジェクトにコピーされます
[[UITabBarItem appearance] setTitleTextAttributes:[NSDictionary dictionaryWithObjectsAndKeys:
[UIColor whiteColor], NSForegroundColorAttributeName,
nil] forState:UIControlStateNormal];
UIColor *titleHighlightedColor = [UIColor getColor:@"05a2ea"];
[[UITabBarItem appearance] setTitleTextAttributes:[NSDictionary dictionaryWithObjectsAndKeys:
titleHighlightedColor, NSForegroundColorAttributeName,
nil] forState:UIControlStateSelected];