基本的布局文件
来源:互联网 发布:wav音频分割软件 编辑:程序博客网 时间:2024/06/05 07:45
侧滑与主界面的布局:
<?xml version="1.0" encoding="utf-8"?><android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:id="@+id/drawer_layout" android:layout_width="match_parent" android:layout_height="match_parent"> <!--主内容区域--> <FrameLayout android:id="@+id/frame_layout" android:layout_width="match_parent" android:layout_height="match_parent"> </FrameLayout> <RelativeLayout android:layout_width="match_parent" android:layout_height="match_parent"> <RadioGroup android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:id="@+id/radiogroup" android:layout_alignParentBottom="true"> <RadioButton android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/radio_01" android:layout_weight="1" android:text="首页" android:checked="true" android:padding="20dp" android:button="@null" android:background="@drawable/select"/> <RadioButton android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/radio_02" android:layout_weight="1" android:text="视频" android:padding="20dp" android:button="@null" android:background="@drawable/select"/> <RadioButton android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/radio_03" android:layout_weight="1" android:text="播放器" android:padding="20dp" android:button="@null" android:background="@drawable/select"/> <RadioButton android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/radio_04" android:layout_weight="1" android:text="我的" android:padding="20dp" android:button="@null" android:background="@drawable/select"/> </RadioGroup> </RelativeLayout> <!--侧滑的区域 侧滑菜单的默认背景颜色是半透明 --> <RelativeLayout android:background="#ffffff" android:id="@+id/drawer_relative" android:layout_gravity="left" android:layout_width="200dp" android:layout_height="match_parent"> <ImageView android:id="@+id/image_touxiang" android:layout_centerHorizontal="true" android:layout_margin="10dp" android:src="@mipmap/ic_launcher" android:layout_width="80dp" android:layout_height="80dp" /> <ListView android:id="@+id/list_view" android:layout_below="@+id/image_touxiang" android:layout_width="match_parent" android:layout_height="match_parent"> </ListView> </RelativeLayout></android.support.v4.widget.DrawerLayout>
阅读全文
0 0
- 基本的布局文件
- 基本的UI控件和布局文件
- 网页布局的九宫格基本布局
- 布局的基本属性和表格布局
- Relative 布局的基本属性
- Android布局的基本方法
- 说说基本的布局观
- 自动布局的基本用法
- 百分比布局的基本用法
- Android 基本的UI布局
- 基本的html网页布局
- ConstraintLayout布局的基本使用
- 频道的布局基本操作
- ConstraintLayout布局的基本使用
- Solaris10的文件布局
- 自定义的布局文件
- 布局文件的优化
- 布局文件的NullPointerException
- Android 如何正确的获取屏幕高度
- Android自定义ViewGroup ,动态添加数目不确定的ImageView
- 机器学习岗面试总结
- 讲给Android程序员看的前端教程(09)——HTML5标签(8)
- Mysql之基本增删改查
- 基本的布局文件
- Mysql数据表查询
- 浅谈equals与==
- 深入理解java虚拟机—类文件结构
- kNN算法识别手写数字(代码笔记)
- JSP登录界面
- 掌柜大作战(5):使用AOP,统一记录方法执行所花的时间
- windows7下Python3.5.3 安装 matplotlib-2.1.0
- angularjs路由