Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is default scale type of ImageView?

I can set options for scaling the bounds of an image to the bounds of an ImageView using setScaleType(ImageView.ScaleType).

What is default ImageView.ScaleType?

like image 643
user1301568 Avatar asked Dec 11 '12 21:12

user1301568


1 Answers

Looks to be ScaleType.FIT_CENTER:

private void initImageView() {
    mMatrix     = new Matrix();
    mScaleType  = ScaleType.FIT_CENTER;
}

Links to the source code of ImageView: Android 4.1.1 r6.1

like image 85
Cat Avatar answered Nov 02 '22 23:11

Cat