tags:

views:

42

answers:

1

I've been using API level 4, and I am moving to level 5. I had a tab widget in my activity. The tabs used to be pretty light greys. After moving to API level 5, they are quite dark. The unselected tabs are almost black! I've tried setting the theme to light, but the colors remain very dark. What is the reason for this?

+2  A: 

Images for the tabs can be found under SDK res folders for all the SDK levels you've downloaded. So you can open them up and compare. If the goal is to preserve the look of the application, I would style the tabs.

EDIT: You can modify and use this drawable

<selector xmlns:android="http://schemas.android.com/apk/res/android"&gt;
    <!-- Non focused states -->
    <item android:state_focused="false" android:state_selected="false" android:state_pressed="false" android:drawable="@drawable/tab_unselected" />
    <item android:state_focused="false" android:state_selected="true" android:state_pressed="false" android:drawable="@drawable/tab_selected" />

    <!-- Focused states -->
    <item android:state_focused="true" android:state_selected="false" android:state_pressed="false" android:drawable="@drawable/tab_focus" />
    <item android:state_focused="true" android:state_selected="true" android:state_pressed="false" android:drawable="@drawable/tab_focus" />

    <!-- Pressed -->
    <item android:state_pressed="true" android:drawable="@drawable/tab_press" />
</selector>
Alex Volovoy
Ok, we can't style tabs on 1.5 though, right?