Search code examples
androidright-to-left

Override right-to-left in layouts


I have developed an application where everything is laid out left-to-right in its layouts and views. The issue is when I change the language in settings to Persian, a right-to-left language, everything changes to right-to-left. How can I override this change to prevent it from happening?


Solution

  • as mentioned in this post: Override supportsRtl in one of the layouts

    you have to set

    android:layoutDirection="ltr"