我有一個水平的LinearLayout
(在另一個LinearLayout
裏面),它包含幾個ImageView
s。出於某種原因,我只是在運行應用程序時看不到它們。我的ImageViews在哪裏?
這裏是我的佈局:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="fill_parent"
android:background="@drawable/background">
<TextView android:layout_height="wrap_content"
android:layout_width="wrap_content" android:textSize="20dp"
android:text="A bunch of text"
android:textColor="#000000" android:layout_gravity="center_horizontal"
android:padding="10dp" android:background="#0000FF"/>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_height="wrap_content" android:layout_width="fill_parent"
android:orientation="horizontal">
<ImageView android:layout_width="wrap_content"
android:layout_height="75dp"
android:src="@drawable/image1"
android:scaleType="centerCrop" android:background="#0000FF"/>
<ImageView android:layout_width="wrap_content" android:layout_height="75dp"
android:layout_weight="1" android:src="@drawable/image2"
android:scaleType="centerCrop" />
<ImageView android:layout_width="wrap_content" android:layout_height="75dp"
android:layout_weight="1" android:src="@drawable/image3"
android:scaleType="centerCrop" />
</LinearLayout>
</LinearLayout>
賓果!總是忘記這個... – LuxuryMode 2011-06-01 02:27:59