I am trying to parse an XML file which contains complex arabic letters ..
When i tested on android 2.3.7, not all arabic letters are supported, there is still some complex ones appear as squares ..
But when tested on android 4.0.4, all letters appear great ..
I needed to find the .ttf arabic font used in 4.0.4 or the best android arabic font to force it in my application to work fine on all versions, can you help me please?
I tried DroidNaskh-Regular.ttf and DroidSansArabic.ttf but not the same like android 4.0.4 ..
Thanks ..
This is a library code I use in my Goyalla dictionary to reshape Arabic on Android version before 4.0. You can get an example for it from github example.
At the same time you need to invoke the *.ttf file.
try this solution:
get the roboto font as used on android 4 , from here. if that doesn't work , you can try out other fonts , such as the DejaVu font . other fonts are available here for example .
then , put the file into your assets folder , and for each of the views that need to show text (like textView) , use the font :
i've tried hebrew in the past and it showed fine . sadly , the special dots (called "NIKUD") didn't show so well so you might have similar problems for arabic .