i have bsnl penta 7" tab. It comes under normal, mdpi, 455x800, screen size is ~5.4"(but tab is 7") when checked via code.
The real problem is, when running my application it loads images, size etc from \res\drawable folder (not a problem with mdpi also not loading from /res/drawable-large). So that the images and font will be small. Similar problem is occurring in some other smart phones too. How can be handled it.
I also configured an emulator similar spec to that tab and it works perfectly.
thanks in advance
Related
I was just developing an application in android that works with both phone and tablet.
now the problem i am facing is with the icon sizes, if i am using say 28dp for mdpi devices then i came across one issue. In my office we have one 8inch tablet coming under mdpi and 5 inch phone also in mdpi. so both devices uses the same icon with size 28 dp. How to solve this problem?
Same in the case of text size i am facing the same issue. Is der any solution for this? I hav read many documentation so please dont copy paste urls. Kindly help me with exact solution...
I'm currently working on my application, which tries to support different screen resolutions but I noticed a major problem with my layouts. I'll explain:
I have two folders in my res folder. They are called "layout" and "layout-sw360dp" which is meant to support big screens like Samsung Galaxy S4, HTC One, etc.
Now, when I try to run my application on my private phone, galaxy S4, the app looks fine and all of the images and the components are perfect.
But when I try to run my app on an HTC One device, suddenly the layout looks small, like very small. It supposes to fit the entire screen, like in my galaxy s4.
It's like HTC One and Galaxy S4 don't use the same layout folder, although their screens sizes are almost the same.
If you guys can clarify this matter for me I would really appreaciate that.
Edit: I have tried to run my app on an Samsung Galaxy S5 device and it looks find, like the way it should. What is the problem with HTC One?
Physical size is usually measured in inches, it simply tells you the real device's screen size
dpi, is NOT correlated with it. Dpi expresses screen density, how many pixels are shown in a given area (usually a square inch). It could be considered as a measure of screen quality.
Resolution is given by the product of the two; it expresses the total number of physical pixels on a screen.
android:anyDensity="true"
Samsung Galaxy S4, HTC One have different physical size : DIFFERENCE
Refer this for how to choice best resolution : DOC
I am developing an Android application intended for high end handset devices like Galaxy S3, Galaxy Nexus, Xperia V etc. Now I want to know which layout is suitable for devices with resolution 720x1280, density xhdpi and size normal.
I already tried layout-xhdpi-1280x720 and Galaxy S3 device is loading screens from here, but not Galaxy Nexus.
I have tried layout-sw260dp but Galaxy Nexus emulator do not loading screens. Also Nexus7 is emulator is loading from here. I don't want any tablet to run my app.
What can be the problem ? Does Device definition of Galaxy Nexus causes the problem ?
I am using Android SDK 4.2.
Now I want to know which layout is suitable for devices with resolution 720x1280, density xhdpi and size normal.
res/layout/ works nicely. If you are also supporting -small screen devices, have an additional res/layout-small/ for those. You may or may not also wish -land variants (e.g., res/layout-land/) if you want different layouts for different screen orientations.
I already tried layout-xhdpi-1280x720 and Galaxy S3 device is loading screens from here, but not Galaxy Nexus.
That approach has been deprecated for years.
I don't want any tablet to run my app.
Then specify the appropriate <compatible-screens> element in your manifest, to state that you only support small and normal screens, not large and xlarge. This has nothing to do with your choice of layout resource directory.
I tested my app on Galaxy tab 10.1 and found something strange.
I use a large image as title of app created for large screen. But when checked it, image quality is lowered.
I never touched image like resizing. Image resolution is fit so there is nothing to change.
When viewing same image on gallary, it seems almost same.
Only in app, image is deteriorated.
I using image folder drawble-xhdpi and layout folder layout-xlarge.
Is there something more i should check?
You should check what density the device you're testing on actually is. The Galaxy Tab 10.1 is an mdpi device, not an xhdpi device. Also, it's recommended not to use the large and xlarge qualifiers, and instead to use the smallest-width qualifiers (e.g. sw600dp for 7", sw720dp for 10").
I have to put my Android application in a Galaxy tab. When I installed the app, the resolution of the UI of my application changed. But it's looking good in emulator and other Android 2.2 phones. But in Galaxy tab, the resolution is changed. Please help.
The Galaxy Tab has a pixel density of about 170. That isn't all that different from an mdpi device. (However, Android market apparently classifies it as an hdpi device.)
Are you sure that the problem is with the resolution? It's an extra large screen; perhaps that's causing problems?
I suggest getting device's (Samsung Galaxy Tab) height-width then optimise your resources according to them. Try to find out whether they lie in hdpi/mdpi or ldpi range
You may be required to use new set of graphics for them.