CheckBoxActivity以及对应的xml页面布局文件
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:padding="15dp"
>
<TextView
android:id="@+id/tv_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="你会哪些移动开发"
android:textSize="20sp"
/>
<CheckBox
android:id="@+id/cb_1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Android"
android:textSize="20sp"
android:layout_below="@+id/tv_title"
android:layout_marginTop="10dp"
/>
<CheckBox
android:id="@+id/cb_2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="IOS"
android:textSize="20sp"
android:layout_below="@+id/cb_1"
android:layout_marginTop="10dp"
/>
<CheckBox
android:id="@+id/cb_3"
android:layout_width

本文深入探讨了Android中CheckBox的使用,包括如何在CheckBoxActivity中实现功能,并详细讲解了对应的xml页面布局文件。同时,还介绍了如何在drawable资源文件中自定义CheckBox的背景样式。
最低0.47元/天 解锁文章
2070

被折叠的 条评论
为什么被折叠?



