Is it possible to change the color of the radio button
in the Android spinner widget. By default it displays the green color for the radio button.
I need to change it to some other color, is it possible, and how?
Is it possible to change the color of the radio button
in the Android spinner widget. By default it displays the green color for the radio button.
I need to change it to some other color, is it possible, and how?
I know this is an old question now, but here goes...
You will need to create a custom Theme and apply it to the Activity with your spinner.
First, you need to create images for the checked/unchecked states of the 'new' radio, you could just pull the given images
btn_radio_on.png
andbtn_radio_off.png
from the sdk'sres/drawable-*
folder(s). Edit them to look how you want (such as changing color or whatever) and save off to your project.Next, create a new xml file in your
res/values
folder, and add the following:Then, create another xml file in
res/drawable
namededited_radio.xml
, and it should contain the following:just be sure to reference your edited images for the checked states. Then you just have to apply the
CustomSpinnerRadioTheme
to your Activity and run!A good resource I found is Applying Styles and Themes especially the additional reference on Android Styles (styles.xml) and Android Themes (themes.xml)