Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android programming - screen resolution

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.....

like image 614
Satyam Avatar asked Apr 24 '10 04:04

Satyam


1 Answers

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.

like image 145
Dave Webb Avatar answered Sep 28 '22 08:09

Dave Webb