Kotlin笔记(31) — RadioButton的使用
2020-10-01 本文已影响0人
奔跑的佩恩
前言
上节我们学过了CheckBox
的使用,这节我们来了解下RadioButton
的使用。
今天涉及内容有:
- RadioButton介绍
- RadioButton的使用
先来波效果图
1.gif
一 .RadioButton介绍
RadioButton
作为单选框,主要结合RadioGroup
使用,一般用在需要选择的场景上。
二.RadioButton的使用
下面贴出RadioButton
在Activity
中使用代码: