Fragment加RadioGroup布局
2017-11-03 13:10
295 查看
<FrameLayout
android:id="@+id/fl_main"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="9" />
<RadioGroup
android:id="@+id/group"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal">
<RadioButton
android:id="@+id/but1"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:button="@null"
android:gravity="center"
android:text="首页" />
<RadioButton
android:id="@+id/but2"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:button="@null"
android:gravity="center"
android:text="想法" />
<RadioButton
android:id="@+id/but3"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:button="@null"
android:gravity="center"
android:text="市场" />
<RadioButton
android:id="@+id/but4"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:button="@null"
android:gravity="center"
android:text="通知" />
<RadioButton
android:id="@+id/but5"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:button="@null"
android:gravity="center"
android:text="更多" />
</RadioGroup>
android:id="@+id/fl_main"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="9" />
<RadioGroup
android:id="@+id/group"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal">
<RadioButton
android:id="@+id/but1"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:button="@null"
android:gravity="center"
android:text="首页" />
<RadioButton
android:id="@+id/but2"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:button="@null"
android:gravity="center"
android:text="想法" />
<RadioButton
android:id="@+id/but3"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:button="@null"
android:gravity="center"
android:text="市场" />
<RadioButton
android:id="@+id/but4"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:button="@null"
android:gravity="center"
android:text="通知" />
<RadioButton
android:id="@+id/but5"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:button="@null"
android:gravity="center"
android:text="更多" />
</RadioGroup>
相关文章推荐
- Fragment与Radiogroup联动,经典的主界面布局。使用show和hide的方式实现;
- Fragment配合RadioGroup实现点击切换布局
- RadioGroup+ViewPager+Fragment的框架布局
- Fragment + RadioGroup 实现类似于Tab的效果
- 点击RadioGroup切换Fragment(不能滑动切换)
- 高仿拉手网底部菜单实现FragmentActivity+Fragment+RadioGroup
- RadioGroup与Fragment使用
- android自定义RadioGroup实现可以添加多种布局
- RadioGroup+Fragment实现页面之间的切换
- ViewPager+RadioGroup实现标题栏切换,Fragment切换
- RadioGroup内兼容任何布局
- Android 底部菜单栏(RadioGroup+Fragment)美化
- Android RadioGroup中横向、竖向布局RadioButton的问题
- 使用ViewPager+Fragment+RadioGroup实现类似微信主界面
- RadioGroup+Fragment实现界面切换
- 使用RadioGroup和fragment搭建项目框架填坑
- 关于Fragment的显示与隐藏结合RadioGroup的默认选中问题
- [Android学习笔记]fragment配合RadioGroup实现点击切换内容
- radioGroup+fragment的显示和隐藏
- android自定义RadioGroup可以添加多种布局的实现方法