0

my application has no problem with English input language and elements and widgets are aligned from left to right. but when this application runs on other mobile with other input language (Like Persian) every things aligns from right to left and it isn't my desire.

Is there any comprehensive setting on the application/code that arranges the the entire app element and activities LEFT-TO-RIGHT without considering the mobile input language?

Ümañg ßürmån
  • 9,695
  • 4
  • 24
  • 41
amir ghorbani
  • 123
  • 2
  • 3
  • 10
  • 1
    Possible duplicate of https://stackoverflow.com/questions/39817683/forcing-the-app-to-work-as-ltr – Shai Sep 09 '18 at 13:09

2 Answers2

1

You can specify a layout that is specific to a language, by placing that layout inside an appropriate layout folder. I don't know what the code is for Arabic, but it should be something like /layout-aa/

Far better today, however, is to use a relative layout, where you use the android:gravity="start" or similar, aligning it based on the language orientation and not strictly left/right. This is available with API version 14 and above.

Anubhav Gupta
  • 2,492
  • 14
  • 27
0

Well, you can force the app to ignore rtl configurations from the AndroidManifest.xml file.

Just make android:supportsRtl equals false.

<application
        android:supportsRtl="false"
        android:...
Alaa AbuZarifa
  • 1,171
  • 20
  • 39