パディング 5 dp を ImageView (サイズ 50x50) に適用すると、結果は高さになり、幅は 50x50 になり、パディングが含まれます。
Android でこの問題を解決するにはどうすればよいですか?
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="#cccccc" >
<ImageView
android:id="@+id/image"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginBottom="8dp"
android:layout_marginLeft="8dp"
android:layout_marginRight="4dp"
android:layout_marginTop="4dp"
android:src="@drawable/user11" />
</RelativeLayout>