I'm new to Android programming. I've seen different phones with different screen resolutions that run on Android. How can I create an application that works on all android devices with out any distortion in my application views.....
The short answer is to size all your layout items in dip
. dip
is short for Density-independent pixel
and Android automatically scales items sized in dip
to be the same size on different screens. (You can shorten dip
to dp
in your layout XML files.)
The long answer is to read this article on the Android developer website. It is long but I highly recommended reading it from beginning to end at least once before you get too far with you application.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With