Questions tagged [android-resource-qualifiers]

10 questions
36
votes
1 answer

Android Resource Qualifiers -sw#dp vs -w#dp

Say I'm developing a different layout for devices with screen size equal to or greater than 600dp. I want to use the post android 3.2 resource qualifiers. I created a folder named layout-sw600dp and put my layout there, but at the same time I could…
user1409534
  • 2,140
  • 4
  • 27
  • 33
4
votes
0 answers

Android does not pick up strings.xml from Any Region (for ex.values_zh) specifically for locale zh_US

I have 2 module projects (lets say App1 and App2) into the same repo, both apps have values_zh, values-zh-rTW and values-zh-rHK in their respective src>res folders. When I set a custom locale of the device to zh_US (on rooted device/emulator) then…
1
vote
1 answer

I Am getting this as an error message in android studio Android resource linking failed Error?

This is an error which is showing when I import the project. It is showing gradle invocation failed but after that when I started copy-pasting each xml and java file then it is showing me this as an error message !! Android resource linking…
1
vote
0 answers

Android raw directory abi qualifier with app bundle?

I'd like to provide different raw files (which is essentially zip file and it's relatively large ~ 15Mb) dependent on ABI (armeabi-v7a/arm64-v8a) for Android application distributed as App Bundle. I can't see in the doc on how i can add ABI…
1
vote
0 answers

Can I force my android test to read resources from a specific qualifier?

I have an android test, when I run in a small device context but I want to read a resource of large screen context (under sw-600 qualifier) Is there any annotation or code to force that?
1
vote
1 answer

Android correct smallest width qualifier

This is my first venture in sw qualifiers and I appear to be missing the mark. Looking into this I see soo many directions on figuring out how to correctly calculate what is needed and through trial and error, I have landed back on error. What I…
0
votes
1 answer

Different integer resource values for phone and tablet?

As described here: https://developer.android.com/guide/topics/resources/more-resources#Integer I added a resource value for integer at /res/values/integers.xml Now, I would like to add the same integers.xml for tablet devices? Like it is done for…
Ralf Wickum
  • 2,850
  • 9
  • 55
  • 103
0
votes
1 answer

Android: Resource Qualifiers on src folder

Is it possible to separate out my src folder by resource qualifier? I already have my code (src, res, etc) separated by product flavor, but I want to separate my src folder in one of the flavors further by portrait and landscape. android…
Jason John
  • 934
  • 2
  • 12
  • 23
0
votes
1 answer

Providing Alternative Bitmaps !! How to recognize that initially in which bucket/drawable we need to put our image

Hello Androider's, I need your little help I developed many applications but from the beginning I was confused on this thing. Suppose I have an image or a bunch of images with different resolutions. How to know in which drawable I need to put it in…
0
votes
1 answer

Use string variable as object key

I have strings in my strings.xml e.g.: Service I want to access them like this: val key = "category__$this.name" // "category__service" val s = R.string.[key] This would give me the Id of the string which…
M Deckers
  • 3
  • 1