继承UINavigationController
自定义:
- (void)customNavigation{
//设置显示的颜色
self.navigationBar.barTintColor = [UIColor whiteColor];
self.navigationBar.barTintColor = JXT_RGBAColor(1, 133, 208, 1);
//设置字体颜色
self.navigationBar.tintColor = [UIColor whiteColor];
[self.navigationBar setTitleTextAttributes:@{NSForegroundColorAttributeName : [UIColor whiteColor]}];
//或者用这个都行
// [bar setTitleTextAttributes:@{UITextAttributeTextColor : [UIColorwhiteColor]}];
}
亲测好有用end
网友评论