Details:
I'm extending ActionBarActivity.
Eclipse and SDK fully patched as of 2011-11-06.
<uses-sdk android:minSdkVersion="4" android:targetSdkVersion="14" />
Deployed to Samsung device with Android 2.3.3
Application has android:theme="@android:style/Theme.Light"
Issue: application is light, but ActionBar is blue with grey icons, hardly visible against the blue background color. I also want the ActionBar to be light, so they grey icons are more visible.
I've tried modifying the styles but to no avail.
I'm probably missing something trivial.
How do I change the background color of the ActionBar of an ActionBarActivity using XML ?
color.xml file:
Behavior of Actionbar can also be changed in APIs < 11
See the Android Official Documentation for reference
I am building an app with
minSdkVersion = "9"
andtargetSdkVersion = "21"
I changed the color of action bar and it works fine with API level 9Here is an xml
res/values/themes.xml
and set the color of actionbar you want
res/values/colors.xml
Actionbar color can also be defined in
.class
file, the snippet isbut this will not work with the API < 11, so styling the actionbar in
xml
is only way for API < 11On the Nexus 4 people this seems to make the color go grey.
(all credit to this post, but it is buried in the comments, so I wanted to surface it here) https://stackoverflow.com/a/17198657/1022454
try this: