I'm trying to handle layout for different screen but I found it hard because emulators always use default layout. I cannot understand why. I create a Nexus 7 emulator and I expected to use layout-sw600dp. The same with Nexus 10 emulator. How came?! Thanks in advance R.
There are 2 versions of the nexus 7 that you can choose from. There's the newer model and the 2012 version. Choose the 2012 version and it should work as expected.
Check your layout directories once again, you might have picked wrong type of resource file. Also I'd suggest to use layout-sw600dp for 7inch tablets and layout-sw720dp for larger ones.
When you create emulator go in Advanced settings and custom skin definition enter "no skin"
emulator skin
There is a bug with Nexus 7 (2013) emulator. It thinks that its resolution is 1280x800, and since it is xhdpi device, final width is 400dp, so it misses sw600dp qualifier. You can track bug here: https://code.google.com/p/android/issues/detail?id=209440
I will update this answer when the bug is closed.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With