I currently own Galaxy Note 4 with RTL in my language, and whenever I run my app it works from right to left while the app is English.
I need to some kind of "force" the app to be LTR in all kind of devices, RTL and LTR.
How I can force it?
I currently own Galaxy Note 4 with RTL in my language, and whenever I run my app it works from right to left while the app is English.
I need to some kind of "force" the app to be LTR in all kind of devices, RTL and LTR.
How I can force it?
Add in styles.xml in your Base App theme style:
<item name="android:layoutDirection">ltr</item>
Exemple:
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorPrimary</item>
<item name="android:screenOrientation">portrait</item>
<item name="android:layoutDirection">ltr</item>
</style>
Use the following attribute on your application manifest
android:supportsRtl="false"
tools:replace="android:supportsRtl"