<RelativeLayout android:id="@+id/RelativeLayout02"android:background="@drawable/login_back" android:paddingTop="21.0px"android:paddingBottom="10.0px" android:layout_width="fill_parent"android:layout_height="wrap_content" android:layout_marginLeft="15.0px"android:layout_marginTop="62.0px" android:layout_marginRight="15.0px"><ImageView android:id="@+id/faceImg" android:background="@drawable/login_head"android:layout_width="wrap_content" android:layout_height="wrap_content" /><EditText android:id="@+id/login_edit_account"android:background="@drawable/qq_edit_login" android:paddingLeft="45.0sp"android:saveEnabled="true" android:layout_width="fill_parent"android:layout_height="wrap_content" android:layout_marginLeft="5.0dip"android:layout_marginTop="5.0dip" android:layout_marginRight="5.0dip"android:layout_marginBottom="5.0px" android:hint="@string/strInputAccHint"android:maxLength="10" android:layout_toRightOf="@+id/faceImg"android:layout_alignParentTop="true" android:inputType="number" />            <TextView android:textSize="16.0dip" android:textColor="#ff3f3f3f"android:gravity="center_vertical" android:id="@+id/TextView01"android:paddingLeft="7.0sp" android:layout_width="wrap_content"android:layout_height="wrap_content" android:layout_marginRight="15.0sp"android:text="@string/strAccInputLabel" android:layout_alignLeft="@+id/login_edit_account"android:layout_alignTop="@+id/login_edit_account"android:layout_alignBottom="@+id/login_edit_account" />                   </RelativeLayout>
关键代码如下:
android:layout_alignLeft="@+id/login_edit_account"android:layout_alignTop="@+id/login_edit_account"android:layout_alignBottom="@+id/login_edit_account"分别表示与id 为login_edit_account的EditText控件的上端,左边,底端对齐。

更多相关文章

  1. android 布局
  2. Android(安卓)控件:使用下拉列表框--Spinner
  3. Android(安卓)应用开发笔记 - 拖动效果(Gallery)
  4. android属性收集
  5. android最佳实践(三)
  6. 项目中那些事|控件之TextView
  7. android 让一个控件按钮居于底部的几种方法
  8. Android(安卓)布局之线性布局、相对布局、表格布局、帧布局
  9. android 相对布局属性

随机推荐

  1. Android(安卓)Service学习之AIDL, Parcel
  2. android 属性系统,SystemProperties 的简
  3. source android 主页改版,突出兼容性测试
  4. [置顶] Android(安卓)fragment 只让一个f
  5. android技术栈-现有使用的进行一个汇总(初
  6. android 里面资源应用 Drawable
  7. win10下使用Fiddler进行网络抓包
  8. android批量安装APK
  9. Dalvik虚拟机JNI方法的注册过程分析
  10. android listview 嵌套ListView,子lv高度