android - Scaling Images in a Linear Layout Evenly -
i have linear layout contains 6 images, span linear layout horizontally.
<linearlayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="horizontal" android:layout_width="wrap_content" android:layout_height="wrap_content" android:background="@layout/roundedcorner"> <imageview android:id="@+id/icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/someimage"> </imageview> ...
the problem is, first 5 images not scale , take pixel width, , 6th images scrunched down, because there not enough space left horizontally.
is there way scale images down have uniform look?
add android:layout_weight="1"
each imageview. if images of equal size, scaled in same way then.
Comments
Post a Comment