1. 程式人生 > >消除RadioButton中的自帶的圓圈

消除RadioButton中的自帶的圓圈

修改app主題時以前寫的RadioButton對圖片處理有些變形,於是想使用系統自帶的RadioButton。但是發現有一個圓圈,消除辦法如下:

在xml中處理: android:button="@null"

帶Java程式碼證處理:

 RadioButton rb = (RadioButton) findview.xxx
 Bitmap a=null;  
 rb.setButtonDrawable(new BitmapDrawable(a)); 

可以通過drawableTop或者drawableBottom進行 drawableBottom圖片處理來顯示底部導航欄。