android - How to set imageview fit to sreen? -
android - How to set imageview fit to sreen? -
i have utilize android studio , set image view fit screen using relative background image give layout top margin , set image view fit screen below part
android:layout_width="fill_parent" android:layout_height="match_parent" android:paddingleft="@dimen/activity_horizontal_margin" android:paddingright="@dimen/activity_horizontal_margin" android:paddingtop="@dimen/activity_vertical_margin" android:paddingbottom="@dimen/activity_vertical_margin" android:background="@drawable/backgroud"> <imageview android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_margintop="500dp" android:background="@drawable/blacksquare" android:alpha=".33" />
write next imageview tag in parent layout.
<imageview android:layout_width="match_parent" android:layout_height="match_parent" android:scaletype="fitxy" android:background="@drawable/blacksquare" />
and can remove paddings parent layout tag fit image view in screen without padding..
android android-layout imageview
Comments
Post a Comment