Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android xxhdpi, 420 dpi and 480 dpi

I'm facing the next problem:

I have a values-xxhdpi with their dimensions.xml. Devices with 480 dpi work great with this folder.

The problem is that for example Samsung Galaxy S4 or S5 catch the values from this folder and not look well in screen because they have a 420 dpi. So I need to create a values-SOMETHING to this type or devices.

I try adding values-w410dp and work fine, but if I add this folder the devices with 480 dpi now catch de values from this folder and not the values from the values-xxhdpi.

Please need sugestions

Thanks

like image 687
user3240604 Avatar asked Feb 15 '17 15:02

user3240604


1 Answers

You have to create dimension resource files for different screen sizes with different dpi.

As you can see here:

android:screenSize=   ["small"| "normal" | "large" |     "xlarge"     ]

android:screenDensity=["ldpi" |   "mdpi" | "hdpi"  | "xhdpi"| "xxhdpi"]

            dpi   [ "280" | "360"| "420"| "480" | "560" ] 

Add your screen dimension with density and define your attributes.

like image 154
user3500198 Avatar answered Sep 20 '22 19:09

user3500198