views:

1936

answers:

4

Hi,

I need to change the selection color of UITabBar from default blue to red. How do we do this.

+1  A: 

I do not believe this can be done - I think the only selection color of UITabBar is the default, which is blue.

zPesk
wrong.. it can be done, there are apps out there with it..
Scrimmers
+3  A: 

The SDK does not make this easy, but it is technically possible. Apple apparently believes this to be part of their vision of a consistent look and feel.

UITabBar is a subclass of UIView. You can always subclass and implement your own -drawRect:

This is not a trivial task, however, you have to essentially re-implement the class from scratch or you risk some weird side-effects.

Kailoa Kadano
A: 

This can be done with a little private API hacking.

rpetrich
A: 

I would be careful about implementing such a change, even if you could figure it out. This strikes me as exactly the kind of thing Apple would reject your application for.

Amagrammer
cobblers.. there are plenty of apps out there that have selected colour based on the look and feel of their app.. check out Yell (Uk) for example
Scrimmers
Apple has changed it standards over time. My comment may not be accurate any more.
Amagrammer