<LinearLayout xmlns:android="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:orientation="vertical"    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" >    <TextView        android:layout_width="fill_parent"        android:layout_height="wrap_content"        android:text="身高 (cm)" />    <EditText android:id="@+id/height"        android:layout_width="fill_parent"        android:layout_height="wrap_content"        android:numeric="integer"        android:text=""         /></LinearLayout>
当屏幕是垂直分布的时候,要使用LinearLayout,和android:orientation="vertical"布局方式是线性垂直布局,而不用RelativeLayout相对垂直布局,

更多相关文章

  1. 关于LinearLayout布局中,子控件平分宽度
  2. Android Layout布局文件里的android:layout_height等属性为什么
  3. android RelativeLayout属性和布局实例
  4. Android界面编程——Android布局组件(二)
  5. 关于界面布局的一些小知识
  6. Android 第七课——UI布局
  7. android布局文件属性说明(转)

随机推荐

  1. 应届毕业生Android面试经验小谈
  2. 控制UI界面的方法
  3. 个人对http请求的理解
  4. Android视频播放框架Vitamio
  5. Android SeekBar的使用,进度条的另一种实
  6. Android 使用LayerDrawable自定制SeekBar
  7. Android上的Native以及JNI开发(1)
  8. 【Android】 基于Socket 的即时通信软件
  9. 使用夜神模拟器进行Android开发调试
  10. Android下Entity封装工具类