RTL Support: Disabling it only for specific UI components

Behnam picture Behnam · Apr 9, 2014 · Viewed 14.6k times · Source

I have a custom video player Activity.

I am forced to enable RTL Support in my Application.

But doing so will result in a Right-To-Left aligned ProgressBar. (And that looks ugly)

I want my ProgressBar to stay LTR in my RTL enabled Application.

Is there any solution?

P.S. I am using Android 4.2.2

Answer

Behnam picture Behnam · Jun 30, 2014

Okay there is a simple solution for 4.2 and upper:

You can set the android:layoutDirection property in XML, it can have either rtl or ltr values.

The property overrides android:supportsRtl property in "application" segment of your manifest file.