Question

I am trying to change the highlighted color of the tabBarItem just like the Viber app does. I don't want to change the color of all the Bar, just the highlighted color.

I have read a lot posts here, but none of them explained how to do only this modification.

Does someone know how to do this? There is many apps that have customized colors!

Was it helpful?

Solution

Currently, with iOS4, this type of customization is not possible with a standard UITabBar. Most applications that have customized UITabBars actually create their own. Check out CocoaControls for some drop in third-party solutions you could use.

OTHER TIPS

Have you tried:

UIView *bg = [[[UIView alloc] initWithFrame:CGRectMake(0,0,320,49)] autorelease];
[bg setBackgroundColor:[UIColor redColor]];
[self.tabBarController.tabBar insertSubview:bg atIndex:1];

That code initially creates a background view for the tabBar and sets it's colour to red.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top