1
每當我在我的XML中創建一個ImageView時,仿真器崩潰。RelativeView中的ImageView會導致崩潰?
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:padding="10px"
android:background="@drawable/words_background">
<EditText
android:id="@+id/letters"
android:layout_width="275dp"
android:layout_height="wrap_content"
android:hint="@string/enter_letters" />
<TextView
android:id="@+id/moreText"
android:text="@string/more"
android:layout_alignLeft="@id/letters"
android:layout_below="@id/letters"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:textSize="15dp"
android:typeface="normal"
android:paddingLeft="5dp"
android:textStyle="bold" />
<Spinner
android:id="@+id/maxSpinner"
android:layout_width="80dp"
android:layout_height="wrap_content"
android:layout_below="@id/letters"
android:layout_alignRight="@id/letters"
android:visibility="gone" />
<Spinner
android:id="@+id/minSpinner"
android:layout_width="80dp"
android:layout_height="wrap_content"
android:layout_below="@id/maxSpinner"
android:layout_alignRight="@id/letters"
android:visibility="gone" />
<TextView
android:id="@+id/lettersQuestion"
android:typeface="sans"
android:text="@string/question"
android:gravity="right"
android:textSize="20dp"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:layout_alignParentRight="true">
</TextView>
<ImageView
android:id="@+id/logo_image" />
</RelativeLayout>
您也可以發表您從logcat中獲得異常? – 2011-06-04 02:02:38