android:layout_alignParentRight="true"
使当前控件的右端和父控件的右端对齐。这里属性值只能为true或false,默认false。
android:layout_marginLeft="10dip"
使当前控件左边空出相应的空间。
android:layout_toLeftOf="@id/ok"
使当前控件置于id为ok的控件的左边。
android:layout_alignTop="@id/ok"
使当前控件与id控件的上端对齐。


padding表示填充,margin表示边距
可通过android:padding属性进行设置,4个方向的边距属性为android:paddingLeft, android:paddingRight, android:paddingTop, and android:paddingBottom.


结论:
*android:layout_marginBottom
*android:layout_marginLeft
*android:layout_marginRight
*android:layout_marginTop
上面几个属性的值是根据下面的相对位置的对象的值来做计算的,如果没有相对的对象就以总体布局来计算
*android:layout_below
*android:layout_above
*android:layout_toLeftOf
*android:layout_toRightOf
*android:layout_alignTop


*android:layout_centerHrizontal //是否支持横屏或竖屏
*android:layout_centerVertical //这个根据单词的意思:中心垂直
*android:layout_centerInparent //
android:layout_centerInParent="true"//居中在父对象
android:layout_centerInParent="false" ... 浏览器不支持多窗口显示,意思就是说所有页面在单一窗口打开,这样避免了页面布局控制显示问题
下面的相对于父的相对位置
*android:layout_alignParentBottom
*android:layout_alignParentLeft
*android:layout_alignParentRight
*android:layout_alignParentTop
*android:layout_alignWithParentIfMissing

来自http://www.eoeandroid.com/archiver/tid-23220.html
http://www.cnblogs.com/llopx/archive/2010/03/31/1701238.html

更多相关文章

  1. 学习Android(安卓)studio 个人总结小经验
  2. Android之动画Animation的使用
  3. Android(安卓)众多的布局属性详解
  4. android 让一个控件按钮居于底部的几种方法
  5. android:属性 layout_alignParentRight android:paddingRight
  6. Android(安卓)众多的布局属性详解
  7. LinearLayout布局实现垂直水平居中
  8. android与j2me移植之clipRect
  9. android 组件属性描述

随机推荐

  1. Android GSM驱动模块(rild)详细分析(一)基本
  2. Android Studio 2.2 NDK开发环境搭建
  3. linux insufficient permissions for dev
  4. Android 进程保活
  5. Android+Jquery Mobile学习系列-目录
  6. Android(安卓)设备蓝牙连接扫描枪获取扫
  7. 前Sun开发人员为Android,iOS等其他移动平
  8. Android 上传头像(文件)到服务器
  9. android 实现QQ好友列表(扩展listview:Exp
  10. Android 广播接收者(具体例子)