1

I was trying out different resource qualifiers in my application and wanted to confirm few things :

Suppose I have few dimension files as follows :

dimens.xml (hdpi)
dimen.xml (sw320dp)

In this case if the phone is hdpi and also the screen has a minimum width of 320dp, which resource file does android pick ?

In the few phones that I have tested, it seems to always pick the sw320dp file which leads me to believe that qualifiers such as "hdpi" and "swdp" should not be mixed.

Is this correct ?

sauvik
  • 2,224
  • 1
  • 17
  • 25
  • http://stackoverflow.com/questions/32860815/how-to-define-dimens-xml-for-every-different-screen-size-in-android/32861248#32861248 – IntelliJ Amiya Feb 14 '17 at 06:50
  • 2
    The table listed: https://developer.android.com/guide/topics/resources/providing-resources.html#AlternativeResources is in order of priority so sw320dp has priority over hdpi (lower in the table). – Morrison Chang Feb 14 '17 at 06:51
  • @MorrisonChang this solves my problem. thanks :) – sauvik Feb 14 '17 at 06:54

0 Answers0