Reputation: 7519
I'm using Droid Naskh font in my application to display Arabic characters. One of my users pointed out that the arabic number 4 ٤
displays as number 5 ٥
. I have attached a screenshot below of how it's appearing on the device (as well as the emulator).
This is the string:
<string name="num">٠١٢٣٤٥٦٧٨٩</string>
Output:
Why is this happening?
PS: I tried other fonts as well, yet this persists. I tried unicode U+0664
, but it displays 5. This is weird.
Upvotes: 0
Views: 714
Reputation: 7519
Okay, figured it out. I was using the ArabicReshaper class and there was a mistake for U+0664
.
This:
{0x0664, 0x000B, 0x0665, 0x0664, 0x0664, 0x0664},
Should be:
{0x0664, 0x000B, 0x0664, 0x0664, 0x0664, 0x0664},
Upvotes: 1