3

I need to print the below string which is in Arabic on TextView in Android. It is printing good but when the Arabic text and digits falls in a same string, Android put the digit at end!

here is my code

String str = "مقر 44";
TextView textView = (TextView)findViewById(R.id.test);
textView.setText(str);

Here is the output

enter image description here

Rohit Mandiwal
  • 10,258
  • 5
  • 70
  • 83

1 Answers1

0

you can try with this workaround

 String str = "44 "+"مقر ";
        TextView textView = (TextView)findViewById(R.id.txt_title);
        textView.setText(str);

enter image description here

its not Android who put digit at the end, its because of Arabic writing standard

Mohammed Azharuddin Shaikh
  • 41,633
  • 14
  • 96
  • 115