chr*_*ina 4 android radio-button


在Android,我想使用RadioButton,但我不想检查纯文本.如何在第一张图像而不是第二张图像中显示?使用RadioGroup和RadioButton.
没有什么特别的事情..只需在其中添加drawable:
<RadioButton
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:drawableLeft="@drawable/ic_launcher"/>
Run Code Online (Sandbox Code Playgroud)
对于这样的效果:

RadioButton本身包含一个TextView默认..所以你可以做任何存在的所有操作TextView.
奖励:如果您想更改显示check状态的圆点,只需更新android:button标签即可引用您自己的标签drawable.
| 归档时间: |
|
| 查看次数: |
4818 次 |
| 最近记录: |