Karthi
Karthi

Reputation: 13762

Android muliple screen support?

I have to design an application which to support under three resolution. for that i use the code in manifest

and also create three folder layout , layout-large, layout-small for supporting three resolution, correspondingly i put the different resolution of image in drawable-hdpi ,drawable-ldpi ,drawable-mdpi , but whenever i run the app in different resolution it going to take low resolution image instead of different resolution i use.

I don`t know where i made the mistake, whether i have to add some code in layout xml or not. I also search the android developer forum and i do the application design as they insist.

Any one suggest some idea to achieve this.Thanks

Upvotes: 0

Views: 440

Answers (1)

ataulm
ataulm

Reputation: 15334

There are two things you could check: have you set the minimum SDK version of your app to use version 4 (Android 1.6) support for this started?

Secondly, the layout-large and layout-small folders are designed for different sized screens (think tablet vs phone), and not resolution. If you're changing the resolution (DPI) of the device, you'll need to use layout-hdpi, layout-ldpi etc.

Further, if it's only the images you're changing, you should be placing the different images in drawable-hdpi, drawable-ldpi etc, and not layout-xxxx. If on a supported device, Android will pick the image from the correct folder, so you'll only have one layout folder (or 2 if you use layout-land)

Some (or all :S) of these points are covered in this link, to another question on StackOverflow. Try to use the search function before asking a question. Also, you'll find people are more receptive to providing answers to users with higher accept percentages.

Android - layout-large folder is been ignored

Edit: for multiple screen support, also look at Fragments to better organise and fit your content for both large and small screen devices (dev.Android, worked example)

Upvotes: 3

Related Questions