Is It Possible To Make The Android Options Menu Background Non-translucent?
Solution 1:
Try this:
<stylename="MyTheme"parent="android:Theme"><itemname="android:panelFullBackground">{your color or drawable}</item></style>
Also, see:
Solution 2:
set android:theme="myTheme"
, and define your own theme with whatever colours you want. Read up about Styles, and look at the android themes.xml.
Solution 3:
Try this for android 4.0:
<stylename="MyTheme"parent="@android:style/Theme.DeviceDefault"><itemname="android:popupMenuStyle">@style/MyPopupMenu</item></style><stylename="MyPopupMenu"parent="@android:style/Widget.DeviceDefault.ListPopupWindow"><itemname="android:popupBackground">{your color or drawable}</item></style>
Also, the following site generate Action Bar Style :
Solution 4:
If you don't want to style a whole theme and just change the options menu background then set the panelFullBackground property to a DRAWABLE RESOURCE of your liking. Setting it to a color directly doesn't work so either make one coloured - 9patch, if you want to save in size -image and set it to that or make a couple and make a selector drawable with an image for each state.
I put my definition in a style that i use for all the activities in my project using:
@drawable/optionsmenu_back
optionsmenu_back being a 9patch image with a solid colour...
Post a Comment for "Is It Possible To Make The Android Options Menu Background Non-translucent?"