I want to create a custom drawable for RadioButton’s button drawable.
I have created a theme and style, which points the RadioButton’s button drawable to a custom drawable defined in XML.
The drawable.xml looks like this:
<android:shape xmlns:android="http://schemas.android.com/apk/res/android" shape="oval">
<android:solid color="#ffffffff"/>
</android:shape>
But this displays a blank area where the button should have been.
I tried adding a size parameter as well:
<android:shape xmlns:android="http://schemas.android.com/apk/res/android" shape="oval">
<android:solid color="#ffffffff"/>
<android:size width="16dip" height="16dip" />
</android:shape>
But no luck with that either.
It was a silly mistake on my part! I had missed the
android:namespace qualifier on thecolorand other attributes.The following works fine: