Let me provide a bit of background information on what I was doing, so if you are having the same problem, you will solve it nice and quickly.
I have a UITabBarController defined in my app delegate. Inside of there I create a UINavigationController and instantiate that with a UITableViewController that I have created.
Everything was working perfectly, then we wanted to change the blue to a red to match our logo. Sounds easy enough right? It sure is, when you know what you're doing. I struggled thinking that it was part of the UITableViewHeader, found a couple of examples of that, but I couldn't get them working or looking like I wanted it to.
After some wasted time, I then realized that it is the UINavigationController that draws the blue background. After some more trial and error and banging my head against the wall, I finally figured it out. You simply do the following:
navigationController.navigationItem.tintColor = [UIColor redColor];
That's it, now it's no longer blue!
Published on Mar 31, 2009
Tags: iPhone
| UINavigationController