I am trying to support for devanagari font for android 2.x (even though android 2.x is not capable of rendering the devanagari font) using following code. The code is working fine except having some issues with 'raswa' and 'dirga'. Is it possible to obtain the correct devanagari representation in android 2.x ?
Typeface typeface = Typeface.createFromAsset(getAssets(), "fonts/mangal.ttf");
TextView txtviewword=(TextView) findViewById(R.id.textViewWord);
txtviewword.setTypeface(typeface);
This is incorrect representation(from android 2.3):
This should have been rather like this(from android 4.4):
After analysing my situation over the problem, I found that swapping the position of 'raswa' with the alphabet ('akshar') itself would solve the problem for gingerbread. So, I swapped the position of 'raswa' and alphabet. So, this provided the problem workaround.