When saving an image button for android, what DPI and Screen Width (or Ratio) should I use?
-
I know slicing for iPhone just need a 320px, and 640px for retina, slicing buttons for android seems to be much more complex.
-
Answer:
Android uses different pixel densities for different devices. This includes LDPI (Low DPI), MDPI (Medium), HDPI (High) etc. There are best practices to follow here for the best results. Simplest way is to make different version of buttons for different DPIs. Android project has a res folder which could have Drawable-hdpi, drawable-mdpi and similarly named subfolders. Each device will read from the respective folder which matches its resolution. If the images are not present in the respective folders, the system will take image from the available folder and resize it. This may create artifacts, because the ratios between is like LDPI = 0.75 MDPI, MDPI = 0.75 HDPI and so on. You should try to use scalable backgrounds for imagebuttons using 9patch images. Android documentation has a lot of coverage on this.
Narayan Babu at Quora Visit the source
Related Q & A:
- How can I use a button to retrieve a phone 'number' from contacts?Best solution by Stack Overflow
- What can I use as a screen name?Best solution by Yahoo! Answers
- What length and width of skateboard should I get?Best solution by warehouseskateboards.com
- What’s Dynamic Keyword Insertion, And How Should I Use It?Best solution by wordstream.com
- How can I use my Pc screen to play Xbox on it?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.