-4
我怎樣才能把TextView
完全ImageView
下面? 我寫下面的代碼,但它把TextView
以下的圖像保證金, 我也嘗試不同的scaleType
爲ImageView
。的LinearLayout不能正常工作
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<FrameLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<ImageView
android:id="@+id/list_row_logo"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="0dp"
android:padding="0dp"
android:src="@drawable/nature_bg" />
</FrameLayout>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="hello" />
</LinearLayout>
加上'機器人:adjustViewBounds = 「真」'在ImageView的XML。 –
@mohammad你可以發佈或'nature_bg'圖片嗎?它可能有空白空間 – user1140237
user114 ...圖像沒有空白,我敢肯定。 – Mohammad