问题
I have an image which is actually 393 x 21 px, which I would like to set on the bottom of my View.
The problem is that, even if i set the width and the height to fill_parent, my image stays very small in the middle of the screen bottom and on the left and the right I have an empty field.
I can resolve this by reducing the Image width size mannualy but is ther any other solution whic could set the image in fullscreen ?
Thank you.
回答1:
//in your xml Image attribute as
android:scaleType="fitXY"
or //using thru programatically
imgview.setScaleType(ScaleType.FIT_XY);
来源:https://stackoverflow.com/questions/9477971/how-to-choose-an-image-resolution-to-be-shown-fullscreen