草庐IT

firstWillAppearOccured

全部标签

ios - 所有导航栏标题的大写字符串

目前,我正在使用AppDelegate中的以下代码更改导航栏的字体:[[UINavigationBarappearance]setTitleTextAttributes:[NSDictionarydictionaryWithObjectsAndKeys:[UIFontfontWithName:@"..."size:...],NSFontAttributeName,nil]];有没有一种方法可以确保字符串在全局范围内大写? 最佳答案 使用NSAttributedString无法实现这一点,但您可以在基础ViewController类中

ios - 所有导航栏标题的大写字符串

目前,我正在使用AppDelegate中的以下代码更改导航栏的字体:[[UINavigationBarappearance]setTitleTextAttributes:[NSDictionarydictionaryWithObjectsAndKeys:[UIFontfontWithName:@"..."size:...],NSFontAttributeName,nil]];有没有一种方法可以确保字符串在全局范围内大写? 最佳答案 使用NSAttributedString无法实现这一点,但您可以在基础ViewController类中