trying to set the layout elements to be RTL ordered
in 4.2 and above the line: layoutDirection=\"rtl\"
and in the manifest: android:supportsRtl=\"true
Just use ViewCompat using android.support.v4.view to do it.
ViewCompat.setLayoutDirection(findViewById(R.id.my_view), ViewCompat.LAYOUT_DIRECTION_RTL);
You won't be able to. It was added to in API Level 17 which is 4.2 so the older versions do not support it.
you can change your application language and solve this problem :
String languageToLoad = "en";
Locale locale = new Locale(languageToLoad);
Locale.setDefault(locale);
Configuration config = new Configuration();
config.locale = locale;
getBaseContext().getResources().updateConfiguration(config,
getBaseContext().getResources().getDisplayMetrics());