How to expand the image size with keeping ratio.
I would like to keep the image ratio when expanding. I would like to set height 10% of vertical screen size and adjust width according to the percents of expanding.
for example
screen size is 480 * 600 original image is 20 * 40image height is set 48 so I would like to set width 96.
How can I make it ?
"#Button":{ image:"/img/text.jpg", left:0, height:'10%',width:'auto' backgroundColor:"red" },it dosen't expand image correctly.