[Q] UI Help, XML file - Android Q&A, Help & Troubleshooting

Hello All,
I am Charan Kumar, a beginner in android. I have created an UI design XML file. The design I have created shows all the components on a 3.7 inch display screen phone(default Nexus Phone in eclipse emulator). But, When I try on 3.2 inch and 3.4 inch screen phone, the components which are at lower part of UI are not getting displayed. The components are not getting fitted to the screen.
I am using "dp" to mention height, and "fill_parent" for width.
Please help me how to design an UI that displays all components on all phones, the design must be compatible for all mobile screens.

U cannot use dp or any other hard coded methods if u want the UI to work for all screen sizes.
I would suggest 2 options.
1. Use fill_parent n wrap_content only as view sizes and use weight attribute and margin and padding values to set the positions and sizes.
2. Else if u want to set the sizes preciously, set the sizes dynamically after reading the screen size from windowManager.

Please use the Q&A Forum for questions &
Read the Forum Rules Ref Posting
Moving to Q&A

Related

[Q] Display Scaling/Zoom

Is there an option to scale the display, so everything will look bigger (for people who have difficulties reading the small fonts that is everywhere).
I'm not looking for a local solution as changing the browser font size, but something like the same effect as when you lower the screen resolution on your PC.
Thanks.
There are a few tools that let you change the DPI, for example: https://market.android.com/details?id=com.innodroid.dpichanger
You need root to use it.
thanks,
the app you mentioned crushed, but this one does work. if I increase the DPI too much then it switches to another launcher and the soft buttons are tiny or gone.
original DPI=160
max DPI working well with the original launcher=177
min DPI = 120 (also works well)
so I only succeded to increase the DPI by 10% and still keep the system work well, not very effective.
https://market.android.com/details?...wsMSwyLDEsImNvbS5iaXJkYXBpLmFuZHJvaWQuZHBpIl0.
Please use the Q&A Forum for questions &
Read the Forum Rules Ref Posting
Moving to Q&A
I use 120 dpi with Go Launcher to fix the view of the home screen. Works very well in expanding the usage of most apps. Though some sharpness is loss in the text...even though it was never that sharp to begin with in 160 dpi.

[Q] Actual Screen size

What is the exact screen size I should use while developing apps for Prime ?
Declared screen resolution isn't correct, because I used that and tested and its not showing in full size as it should, so it must be some other screen size.
Don't know, but would it work to take a screen shot and mail yourself the photo?
I had the same trouble with my hubs screens. Beautiful Photoshop stuff, but when they display at the original (advertised) size, they have a few pixels missing at either end.
I've used 1280x800px, but width of 1280 won't go to their ends and height seems to be shorter, because I see font degradation and rest of the objects, but its best visible on fonts (at least in my case.)
I'll have to explore tomorrow with different sizes... although I don't like these testing where I have to do whoknows how much of them to find exact dimensions.
The system bar take 48 pixels. So the actual resolution that's is available is 1280x752
If you going to create a app. I why don't look at android developer section for guide and info.. Just a suggestion...
http://developer.android.com/guide/practices/screens_support.html
http://developer.android.com/guide/practices/screens_support.html#DeclaringTabletLayouts
Asus Prime & Tapatalk
Both of your links don't mention 752px, there is 720.
Anyways I don't use Android SDK or any other of their info. I use Adobe Flash and do it all from there. Very easy and no need for lots of reading

[Q] Issue with scaling html5 built app

I have created an HTML5 'app' with a width and height 480 x 800 to be used as an android app.
Plan is that this can be scaled down/up for other Android devices to fit screen.
The app runs fine, but it is not being scaled to my device screen size. I have to scroll up/down and left/right on the every screen.
I have tried nearly every variation of the meta viewport tag with no succes (in the index.html file).
Any ideas? Have spent two days frying brain on this one. Have also tried appmobi & phonegap.
Cheers
Please use the Q&A Forum for questions &
Read the Forum Rules Ref Posting
Moving to Q&A

Wallpaper size

Hey all I am trying to design a wallpaper for my 80 g9 but don't what size to make it. I am using photoshop and don't know the right pixel amount to use. Thanks in advance
Took this straight from the Tech Specs page on the Archos website.
Display characteristics • 8”: 1024 x 768
Hope it helps!
On my Cobalt it crops the image to a 768x768 cross then enlarges it to a 1024x1024 cross so it should fit both portrait and landscape but it looks awful.
So it may be an idea to enlarge the canvas in Photoshop to 1024x1024, then set it as your wallpaper on the device so it is cropped without being resized
I've done some experimenting.
The best results are to use photoshop to add a large border around the image you want, basically set the canvas size to twice the current dimensions or more, this will reduce the amount of resizing the tablet does when you crop.
Now, with the mask that the wallpaper crop tool gives you, even though the landscape section is in the middle, it is wrong, the top of the landscape section is actually the top of the outer rectangle, so the top most line of the rectangle will be the top most line of the final cropped image.
xaccers said:
I've done some experimenting.
The best results are to use photoshop to add a large border around the image you want, basically set the canvas size to twice the current dimensions or more, this will reduce the amount of resizing the tablet does when you crop.
Now, with the mask that the wallpaper crop tool gives you, even though the landscape section is in the middle, it is wrong, the top of the landscape section is actually the top of the outer rectangle, so the top most line of the rectangle will be the top most line of the final cropped image.
Click to expand...
Click to collapse
just set the pixels to stock display size them go to playstore, download crop wallpaper then find photo set as overall and apply

Dealing with DPI and resolution

Hello, I'm a beginner for android development, and I am currently making a game for Android, but I've been stuck on this problem for a few hours.
Since android's resources (drawable, mipmap) are based on DPI, if I want to fill a screen with a specific resolution, how would I go about adjusting the size for multiple displays?
For example, I have a 1920x1080 screen, so I make a background that is 1920x1080. If I try the app a 1280x720 screen, the image will be clipped and some of it will not be visible on the screen. If I try the app on a 2560x1440 screen, the image will not cover the entire screen.
How would I make my app work with phones with different displays? Or have I misunderstood the mdpi,hdpi,xhdpi,..etc. and they in fact actually deal with resolution?
I am using SurfaceView and BitmapFactory to load the resources and load it onto the screen, if that helps anything.
Many thanks.
(If I am posting on the wrong subforum, please direct me to the proper one, Android Software Development seemed to be full of guide and not help, so I decided to post here)

Categories

Resources