UINavigationBar *navBar= [UINavigationBarappearance];
//设置全局导航栏的背景图片
[navBar setBackgroundImage:[UIImageimageNamed:@"NavBar64"]forBarMetrics:UIBarMetricsDefault];
//设置全局导航栏的title颜色和字体
NSMutableDictionary *arrt = [NSMutableDictionarydictionary];
arrt[NSForegroundColorAttributeName]=[UIColorwhiteColor];
arrt[NSFontAttributeName] =[UIFontsystemFontOfSize:18];
[navBar setTitleTextAttributes:arrt];
iOS7.0以上 需要使用 NSFontAttributeName、NSForegroundColorAttributeName
'UITextAttributeTextColor' is deprecated: first deprecated in iOS 7.0 - UseNSForegroundColorAttributeName
'UITextAttributeFont' is deprecated: first deprecated in iOS 7.0 - UseNSFontAttributeName