什么是ImageView的默认ScaleType?如果我在普通屏幕(320x480)上放置400像素x 400像素的图像而未指定ScaleType,图像将如何缩放?
谢谢.
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<ImageView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:src="@drawable/big_image"
/>
</RelativeLayout>
Run Code Online (Sandbox Code Playgroud)
Rob*_*ond 94
ImageView.ScaleTypeFIT_CENTER使用缩放图像
CENTER.从XML,使用以下语法:android:scaleType="fitCenter".
| 归档时间: |
|
| 查看次数: |
20553 次 |
| 最近记录: |