Reputation:
For most iOS widgets I can set the background color. It appears that UINavigationBar is not this way. Furthermore I cannot set the navigation item (top item)'s background as it does not respond to setBackgroundColor.
How can I change that color? Thanks.
Upvotes: 2
Views: 8606
Reputation: 151
Change it by following code:
self.navigationController.navigationBar.tintColor=[UIColor grayColor];
Upvotes: 3
Reputation: 1790
You should use setTintColor:
instead:
[self.navigationController.navigationBar setTintColor:[UIColor redColor]];
Hope this helps!
Upvotes: 5