Customize default navigation bar appearance

suggest change

KNGRed and KNGGray are app-specific colors. fontWithName:size: returns nil when that font is not installed, and a nil font is ignored in the attributes dictionary. Set this appearance before the bar is created, typically in application:didFinishLaunchingWithOptions:.

// Default UINavigationBar appearance throughout the app
[[UINavigationBar appearance] setTitleTextAttributes:@{NSForegroundColorAttributeName: [UIColor whiteColor],
                                                       NSFontAttributeName : [UIFont fontWithName:@"HelveticaNeue-CondensedBold" size:17],
                                                       }];

[[UINavigationBar appearance] setTintColor:[UIColor whiteColor]];
[[UINavigationBar appearance] setBarTintColor:[UIColor KNGRed]];
[[UINavigationBar appearance] setTranslucent:NO];
[[UINavigationBar appearance] setBarStyle:UIBarStyleBlack];
[[UIBarButtonItem appearanceWhenContainedInInstancesOfClasses:@[[UISearchBar class]]] setTintColor:[UIColor KNGGray]];

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents