How to change color of tab when its selected, see below screen shot:
i am showing Orange color in ActionBar, in a same way i wanna show orange color in place of light blue.
To show Orange color in ActionBar background, i am using below code:
<?xml version="1.0" encoding="utf-8"?>
<resources xmlns:android="http://schemas.android.com/apk/res/android">
<style name="Theme.MyAppTheme" parent="android:style/Theme.Holo.Light">
<item name="android:actionBarStyle">@style/Theme.MyAppTheme.ActionBar</item>
</style>
<style name="Theme.MyAppTheme.ActionBar" parent="android:style/Widget.Holo.Light.ActionBar">
<item name="android:background">#FF4444</item>
</style>
</resources>
You can use this code and set icon alpha , it look like one is selected and other are disable.
Style your custom theme like below.
after that
Or you can use following code.
or
Hope it helps you .
you can use like this
tab_background_select.xml
To change tab bar background:
use this code in order to change the color of selected tab:-
you can use this code and set the background of your item_tab xml file
tab_selection.xml