我希望每个 TextView 出现在每个 ImageButton 下,但我的情况下的 TextView 根本没有出现,我不明白为什么。感谢您的帮助。这是我的 activity.xml :
<ImageView android:id="@+id/imageView1" android:layout_width="200dp" android:layout_height="200dp" android:layout_gravity="center" android:src="@drawable/logo" /> <LinearLayout android:id="@+id/linearLayout1" android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" > <ImageButton android:id="@+id/imageButtonProjet" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginBottom="25dp" android:layout_marginLeft="25dp" android:adjustViewBounds="false" android:scaleType="centerCrop" android:src="@drawable/projet" /> <ImageButton android:id="@+id/imageButtonWorkitem" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginBottom="25dp" android:layout_marginLeft="25dp" android:adjustViewBounds="false" android:scaleType="centerCrop" android:src="@drawable/workitem" /> <ImageButton android:id="@+id/imageButtonUser" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginBottom="25dp" android:layout_marginLeft="25dp" android:adjustViewBounds="false" android:scaleType="centerCrop" android:src="@drawable/user" /> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/imageButtonProjet" android:layout_marginLeft="32dp" android:text="Projects" android:textColor="@color/text_color" > </TextView> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/imageButtonWorkitem" android:layout_marginLeft="62dp" android:text="WorkItem" android:textColor="@color/text_color" > </TextView> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/imageButtonUser" android:layout_marginBottom="28dp" android:layout_marginLeft="65dp" android:text="Users" android:textColor="@color/text_color" > </TextView> </LinearLayout>
非常感谢您的帮助。在此先感谢