<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res/com.example.myviewdemo"
android:layout_width="match_parent"
android:l...
分类:
其他好文 时间:
2015-01-30 10:47:54
阅读次数:
99
StackView的使用效果:
使用方法:
在Xml布局文件中使用:<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent...
分类:
其他好文 时间:
2015-01-29 14:37:30
阅读次数:
138
安装了最新的ATD 18之后,新加的Lint Warnings插件会给我们检测出许多xml布局中不当的地方,例如:
Use a layout_height of 0dip instead of fill_parent for better performance
什么意思呢?举个简单的例子:
这是一个垂直布局,上下的线性布局各占高度50.0dp,中间的的TextView设...
分类:
其他好文 时间:
2015-01-28 13:09:50
阅读次数:
1974
主布局
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="ma...
分类:
移动开发 时间:
2015-01-27 23:32:26
阅读次数:
211
当然是以文件形式写到手机内存,不过在模拟器上面运行会很慢
布局文件
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent...
分类:
移动开发 时间:
2015-01-27 11:13:20
阅读次数:
211
main.xml
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_heigh...
分类:
移动开发 时间:
2015-01-26 21:07:58
阅读次数:
256
有时间再写个日期时间合在一起的自定义时间选择对话框
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
and...
分类:
移动开发 时间:
2015-01-26 21:06:09
阅读次数:
276
一下是个人的一些总结。
为fragment创建XML
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
...
分类:
其他好文 时间:
2015-01-24 11:39:51
阅读次数:
181
TextView的宽和高都是 match_parent 手机分辨率(720 * 1280)
===widthMode===EXACTLY===heightMode===EXACTLY===widthSize===720===heightSize===1084
===widthMode===EXACTLY===heightMode===EXACTLY===widthSize===720===heig...
分类:
其他好文 时间:
2015-01-23 13:27:17
阅读次数:
177
三个属性都用来适应视图的水平或垂直大小,一个以视图的内容或尺寸为基础的布局比精确地指定视图范围更加方便。
1)fill_parent
设置一个构件的布局为fill_parent将强制性地使构件扩展,以填充布局单元内尽可能多的空间。这跟Windows控件的dockstyle属性大体一致。设置一个顶部布局或控件为fill_parent将强制性让它布满整个屏幕。
2) wrap...
分类:
移动开发 时间:
2015-01-23 13:27:13
阅读次数:
176