即時使用該代碼;相對佈局不放按鈕
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/hello" />
<Button
android:id="@+id/button1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:text="Button" />
</RelativeLayout>
由於某種原因,這不適用於模擬器與540x960。該按鈕出現在模擬器的中間。
在我的droid2中,它能正常工作。
左圖展示它是如何工作在我的Droid 2的手機,而右側顯示如何是工作在HTC sensationXe模擬器
什麼操作系統版本是模擬器?也許你應該把TextView固定在某個東西上。 –
我已經更新了我的問題,並且我上傳了一些圖片,以便您能夠看到問題 – Yayo28