誰能告訴我爲什麼下面的代碼不工作?該圖像根本沒有出現。Android ImageView不顯示圖像?
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
<ImageView
android:src="@drawable/splashscreen"
android:scaleType="center"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</RelativeLayout>
RelativeLayout沒有定位..... – 2015-01-06 04:06:44
如果你在Android Api 21或更低版本運行應用程序,它是一個常見的問題。主要是因爲你使用高分辨率,大尺寸的圖像。我建議你調整大小,縮小圖像。 – emiraslan 2017-03-30 15:54:43