用相对布局也可以,直接在xml文件中写出来,不要用手拖,容易出问题,而且控件多的话最好不要用相对布局,它每个控件都是相关联的,牵一发而动全身在编译时容易出问题
解决方案 »
- 打死进。。安卓底层native用的是C语言还是C++,都用的话,各用在哪些方面
- android源代码编译之后,烧入板子中没有声音
- 自定义适配器的问题?
- listView中应用imageButton
- 关于onKeyMultiple事件怎么用
- eclipse AVD启动问题
- android应用转游戏开发
- 分离式的actionbar,底部的actionbar如何隐藏?
- 如何升级旧工程?
- 求指点,要在Android平台上开发一款类似Hopscotch、Scratch的儿童用编程软件
- 求助!!!!!!!!android15应该用什么版本的sdk和adt,谁有对应版本的内有邮箱
- 关于android获得照片路径的问题
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
xmlns:android="http://schemas.android.com/apk/res/android">
<AbsoluteLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<ImageView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_x="0dp"
android:layout_y="0dp"
android:background="@drawable/workbg"
/>
<ImageView
android:layout_width="150px"
android:layout_height="30px"
android:layout_x="0dp"
android:layout_y="5px"
android:background="@drawable/logo"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_x="260px"
android:layout_y="0px"
android:text="手机无线扫描枪"
android:textSize="20sp"
android:textColor="#ffffffff"
/> <ImageButton
android:layout_width="150px"
android:layout_height="150px"
android:layout_x="50px"
android:layout_y="120px"
android:background="@drawable/uploaddatabg"
android:onClick="onclickUpload"/> <ImageButton
android:layout_width="150px"
android:layout_height="150px"
android:layout_x="280px"
android:layout_y="120px"
android:background="@drawable/downloaddatabg"
android:onClick="onclickDownload"/> <ImageButton
android:layout_width="150px"
android:layout_height="150px"
android:layout_x="50px"
android:layout_y="330px"
android:background="@drawable/updownline"
android:onClick="onclickUpDown"/> <ImageButton
android:layout_width="150px"
android:layout_height="150px"
android:layout_x="280px"
android:layout_y="330px"
android:background="@drawable/updownlineorder"
android:onClick="onclickUpDownOrder"/>
<ImageButton
android:layout_width="150px"
android:layout_height="150px"
android:layout_x="50px"
android:layout_y="540px"
android:background="@drawable/offlinesearch"
android:onClick="onclickOfflineSearch"/> <ImageButton
android:layout_width="150px"
android:layout_height="150px"
android:layout_x="280px"
android:layout_y="540px"
android:background="@drawable/backbg"
android:onClick="onclickBack"/>
</AbsoluteLayout>
</LinearLayout>
效果图: