Android 控件在最底部展示
来源:互联网 发布:all in one seo pack 编辑:程序博客网 时间:2024/05/19 12:25
Android控件放屏幕最下面有两种方式:
使用android:layout_height="match_parent"将控件设置为占满屏幕。
使用RelativeLayout包括控件,控件中增加android:layout_alignParentBottom="true" 表示放在父控件的最下方。
使用android:layout_gravity="bottom" 指定当前控件的位置为bottom即可。
<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:background="#FFFFFF" android:orientation="vertical"> <LinearLayout android:layout_width="fill_parent" android:layout_height="50dp" android:background="@color/bannerblue" android:gravity="center_vertical" android:orientation="horizontal" > <TextView android:id="@+id/tv_friend_title" android:layout_width="wrap_content" android:layout_height="50dip" android:layout_weight="1" android:gravity="center" android:text="我的车库" android:textColor="#ffffff" android:textSize="20dip" /> </LinearLayout> <LinearLayout android:layout_width="fill_parent" android:layout_height="match_parent" android:background="@color/white" android:orientation="horizontal"> <TextView android:id="@+id/delcar" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="@color/bannerblue" android:gravity="center" android:paddingBottom="10dp" android:paddingLeft="15dp" android:paddingRight="15dp" android:paddingTop="10dp" android:text="删除车型" android:textSize="17sp" android:textColor="@color/white" android:layout_gravity="bottom" android:layout_alignParentBottom="true"/> </LinearLayout></LinearLayout>
0 0
- Android 控件在最底部展示
- android linearlayout 把控件view置底部(放在页面最下方)
- Android-ListView显示在最底部
- Android 布局:控件放置在底部
- androidの布局控件居于最底部实现
- android如何让控件摆放在屏幕底部?
- android如何让控件摆放在屏幕底部
- Android中设置控件显示在屏幕底部
- android 线性布局设置控件固定在底部
- 如何使对话框中edit控件的滚动条始终在最底部
- 如何在ListBox中添加控件后让ListBox滚动到最底部
- Android将控件显示在最上层
- Android 打造底部导航控件
- android让控件基于底部
- 底部一直在最底部不管内容多少
- android中listView下有Button按钮始终在最底部
- android中listView下有Button按钮始终在最底部
- Android ScrollView在内容过多时自动翻滚到最底部
- How to replace a Django model field with a property
- C#实现Base64的编码与解码
- 安卓listview两个类型条目的复用,总是报数组越界Android listview ArrayIndexOutOfBoundsException问题
- ubuntu远程连接windows系统
- Block Change Tracking(块跟踪)详解
- Android 控件在最底部展示
- Mysql limit 优化,百万至千万级快速分页,--复合索引的引用并应用于轻量级框架
- Android-AsyncTask简单介绍和使用
- DB2中,先四舍五入在保存4位小数点的方法
- std::map::erase的用法及陷阱
- Android官方示例分享
- 18个常用的JavaScript代码
- IOS开发 判断是否是非法字符 例如表情符号
- Spark-SQL介绍及优化策略