Noo*_*bMe 18 android uiimageview imageview android-layout
是否有可能我的ImageView
所有屏幕尺寸都适合没有图像看起来拉伸?
我尝试使用fill_parent
> 将所有比例类型更改为背景和srcwrap_content
但仍然.如果图像不小,它只是看起来拉伸..
例:
<ImageView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:scaleType="centerInside"
android:adjustViewBounds="true"
android:background="@drawable/background" />
<ImageView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:scaleType="fitXY"
android:adjustViewBounds="true"
android:background="@drawable/background" />
Run Code Online (Sandbox Code Playgroud)
这两个适合宽度,但图像被拉伸..但当我将其更改为src时,图像只是居中和小.
MH.*_*MH. 31
没有内置的缩放类型允许ImageView
自动升级图像并保持其纵横比不变.进行升级的唯一比例类型是fitXY
,不会像你自己发现的那样尊重宽高比.
话虽如此,这个话题已经不止一次被访问过了.看看针对类似问题提出的一些建议:
我肯定会更多,所以值得使用顶部的搜索框.
归档时间: |
|
查看次数: |
43700 次 |
最近记录: |