Android application support RTL

Posted on 2011-03-02
Last Modified: 2012-05-11
 I have developet Android application which display RSS news

 I'm using the Radio buttons & Test View

 how do I set the application to suopport RTL Direction ??

Question by:madmare
  • 4
  • 3
LVL 17

Expert Comment

by:Dejan Pažin
ID: 35029282

I guess you need Arabic locales for that. If you compare the android version 2.2 and 2.3, you will notice that 2.3 has Arabic support, while 2.2 does not:

There are suggestions to use webkit control, see here:

Author Comment

ID: 35047384
i need Hebrew, not arabic

 is it the same ?
LVL 17

Expert Comment

by:Dejan Pažin
ID: 35053871

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.


Author Comment

ID: 35098898
I don't have any problem with the fonts, all what i need that the fonts in TextView be aligned to the rigth

LVL 17

Expert Comment

by:Dejan Pažin
ID: 35106061

I am not sure I understand now. I thought you needed RTL support?

To justify text to the right try this:


Author Comment

ID: 35106137
unfortunatly it still aligned to the left after I had inserted the: tv.setGravity(Gravity.RIGHT);

LVL 17

Accepted Solution

Dejan Pažin earned 500 total points
ID: 35117557
Here is a sample that works, try it:

public class MyActivity extends Activity
    /** Called when the activity is first created. */
    public void onCreate(Bundle savedInstanceState)
        LinearLayout layout = new LinearLayout(this);
        TextView tv  = new TextView(this);
        LinearLayout.LayoutParams lp = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.FILL_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT);
        layout.addView(tv, lp);

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Samsung Marshmallow  - how to get rid of annoying alarm icon. 2 157
disable wifi and bluetooth 10 56
fb messenger security and privacy 15 98
how many cores in note3? 5 49
Displaying an arrayList in a listView using the default adapter is rarely the best solution. To get full control of your display data, and to be able to refresh it after editing, requires the use of a custom adapter.
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at
This video demonstrates how to sync Microsoft Exchange Public Folders with smartphones using CodeTwo Exchange Sync and Exchange ActiveSync. To learn more about CodeTwo Exchange Sync and download the free trial, go to:…

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question