布局与深化_第1张图片 "http://schemas.android.com/apk/res/android"

xmlns:tools="http://schemas.android.com/tools"

android:layout_width="match_parent"

android:layout_height="match_parent"

android:paddingBottom="@dimen/activity_vertical_margin"

android:paddingLeft="@dimen/activity_horizontal_margin"

android:paddingRight="@dimen/activity_horizontal_margin"

android:paddingTop="@dimen/activity_vertical_margin"

tools:context=".MainActivity"

android:orientation="vertical"

android:background="#FFFFFF"

android:gravity="top|left"

>

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:orientation="horizontal"

>

android:layout_width="65dp"

android:layout_height="wrap_content"

android:text="用户名"

android:textSize="16sp"

/>

android:layout_width="200dp"

android:layout_height="wrap_content"

android:hint="请输入 登录 用户名"

/>

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:orientation="horizontal"

>

android:layout_width="65dp"

android:layout_height="wrap_content"

android:text="密码"

android:textSize="16sp"

/>

android:layout_width="200dp"

android:layout_height="wrap_content"

android:hint="请输入 密码"

/>

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:orientation="horizontal"

>

android:layout_width="65dp"

android:layout_height="wrap_content"

android:text="年龄"

android:textSize="16sp"

/>

android:layout_width="200dp"

android:layout_height="wrap_content"

android:hint="请输入 年龄"

/>

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:orientation="horizontal"

>

android:layout_width="65dp"

android:layout_height="wrap_content"

android:text="生日"

android:textSize="16sp"

/>

android:layout_width="200dp"

android:layout_height="wrap_content"

android:hint="请输入 您的生日"

/>

android:layout_width="match_parent"

android:layout_height="wrap_content"

android:orientation="horizontal"

>

android:layout_width="65dp"

android:layout_height="wrap_content"

android:text="电话"

android:textSize="16sp"

/>

android:layout_width="200dp"

android:layout_height="wrap_content"

android:hint="请输入 您的电话"

/>

android:layout_width="265dp"

android:layout_height="wrap_content"

android:hint="注册"

android:layout_gravity="center_vertical"

/>

编写这个程序的代码:

"1.0"encoding="utf-8"?>

"http://schemas.android.com/apk/res/android"

android:layout_width="match_parent"

android:layout_height="match_parent">

android:id="@+id/img1"

android:layout_width="wrap_content"

android:layout_height="wrap_content"

android:src="@drawable/ic_launcher"

android:layout_centerInParent="true"

/>

android:id="@+id/img2"

android:layout_width="wrap_content"

android:layout_height="wrap_content"

android:src="@drawable/ic_launcher"

android:layout_above="@id/img1"

android:layout_centerInParent="true"

/>

android:id="@+id/img3"

android:layout_width="wrap_content"

android:layout_height="wrap_content"

android:src="@drawable/ic_launcher"

android:layout_alignTop="@id/img1"

android:layout_toLeftOf="@id/img1"

/>

android:id="@+id/img4"

android:layout_width="wrap_content"

android:layout_height="wrap_content"

android:src="@drawable/ic_launcher"

android:layout_alignTop="@id/img1"

android:layout_toRightOf="@id/img1"

/>

android:id="@+id/img5"

android:layout_width="wrap_content"

android:layout_height="wrap_content"

android:src="@drawable/ic_launcher"

android:layout_below="@id/img1"

android:layout_centerInParent="true"

/>

文/stonecutter(作者)

原文链接:http://www.jianshu.com/p/a64f4f12ebb4

著作权归作者所有,转载请联系作者获得授权,并标注“作者”。

更多相关文章

  1. 比如说我们要从用户表customer和用户订单表orders中,查询上海的用
  2. 我不是盘神!PanDownload 作者被抓捕,一代神器凉凉了!
  3. windows10家庭版更改登录用户名
  4. Requests库作者Kenneth Reitz的另一神作!虚拟环境及包管理工具Pip
  5. 从微信赞赏升级来谈谈公号作者的境况
  6. php实现根据身份证获取年龄
  7. PHP实现根据出生年月日计算年龄的功能(代码示例)
  8. PHP基础案例二:计算学生年龄
  9. PHP根据身份证号码,获取性别、获取生日、计算年龄等多个信息

随机推荐

  1. android 微信分享大坑总结
  2. 网络请求测试之HttpUrlConnection【Andro
  3. Android(安卓)View的onTouch和onClick和o
  4. Android自定义Layout
  5. android 自定义View的属性
  6. android 键盘弹出,布局重绘
  7. android基础知识05:四大组件之Broadcast R
  8. Android信息界面编辑及组合控件的封装
  9. android Intent的常用flags
  10. Android(安卓)ApiDemos示例解析(109):Vie