android - Is there any property in CSS which is equivalent to "max-height" and "max-width" to scale images proportionally? -


it annoying of css properties not working on android phones. same case max-height , max-width properties.

is there equivalent css properties handle such things? in case of images, images should scalable according proportion. here jsfiddle same.

i dont know if equivalent propierty can way:

you obtain width , heigth on mainactivity.

display display = getwindowmanager().getdefaultdisplay();  int width = display.getwidth();   int height = display.getheight();  

then set default value image width , heigth.

then calculate new value.


Comments

Popular posts from this blog

php - Why I am getting the Error "Commands out of sync; you can't run this command now" -

linux - Does gcc have any options to add version info in ELF binary file? -

java - Are there any classes that implement javax.persistence.Parameter<T>? -