Pseudo localization in Android Emulator not available
Asked Answered
E

2

7

I would like to enable "English (XA)" and "عربى" (XB) locales en-XA and ar-XB to make sure my app layouts are ready for translation, similar to what the article describes here. However, it is not available in the official Android emulator settings. I have tried several images and cannot find these pseudo-localization languages. Is there a setting or trick to enable them?

Earle answered 31/1, 2017 at 13:9 Comment(0)
W
7

Try this:

  1. Turn on Developer Options, by tapping on Build number 7+ times.
  2. Restart your emulator, by long clicking the power icon in the emulator menu and choosing the Restart option.
  3. Go to the Add Language page. Choose your psuedolocale.
  4. Add pseudoLocalesEnabled true to your build.gradle and build your app.

app/build.gradle:

  android {
    ...
    buildTypes {
      debug {
        pseudoLocalesEnabled true
      }
    }

from https://developer.android.com/guide/topics/resources/pseudolocales

While answered 1/12, 2020 at 22:32 Comment(1)
Restarting the device isn't mentioned in the docs, but apparently it's necessary. Thanks!Agricola
H
-2

You can add en_XA and ar_XB locale in android emulator's Custom Locale app.That's it.

enter image description here

Helios answered 13/12, 2017 at 2:16 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.