1.这个是APIDemo中的布局格式:

<?xml version="1.0" encoding="utf-8"?>
android:layout_width="fill_parent"
android:layout_height="fill_parent">
android:id="@+id/label"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="Type here:"/>
android:id="@+id/entry"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@android:drawable/editbox_background"
android:layout_below="@id/label"/>
android:id="@+id/ok"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/entry"
android:layout_alignParentRight="true"
android:layout_marginLeft="10dip"
android:text="OK" />
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_toLeftOf="@id/ok"
android:layout_alignTop="@id/ok"
android:layout_above="@id/ok"
android:text="Cancel" />



1.这里面比较有用的部分1)
[color=red]android:background="@android:drawable/editbox_background"[/color]

2.android:layout_marginLeft="10dip"是设定后续如果有放在左面的View就默认间隔10dp的距离;

更多相关文章

  1. android有用的知识
  2. Android与Js交互获取返回值
  3. Android双击
  4. Android自定义Dialog
  5. Android使用MediaRecorder实现录音功能相关知识
  6. EditText 行间距 以及光标高度和样式
  7. android文件管理实现源码
  8. Android总结笔记
  9. android按两次后退键退出程序

随机推荐

  1. android中调用金山词霸
  2. Android对图片局部扩大的实现
  3. 关于android上dpi/screen-size的厘清解释
  4. android md5加密
  5. Android(安卓)命令行手动编译打包详解
  6. Android异步加载图片
  7. Android: couldn't save which view has
  8. Android(安卓)不通过parent实现样式继承
  9. Android(安卓)系统菜单与自定义菜单
  10. android获得手机的电量