Hello Guest

Author Topic: How to get input and output of Arabic/Persian/Farsi texts?  (Read 4022 times)

test84

  • Jr. Member
  • **
  • Posts: 71
    • View Profile
How to get input and output of Arabic/Persian/Farsi texts?
« on: March 15, 2014, 02:05:17 am »
Hi,

I was wondering on how to get Arabic/Farsi text input vai tk2d's input texts and also what should I do if I want to have Arabic/Farsi text on button labels, a.k.a. text meshes.

Thanks.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: How to get input and output of Arabic/Persian/Farsi texts?
« Reply #1 on: March 15, 2014, 11:13:40 am »
tk2d doesn't support right to left, but if you generate the right glyphs and handle the right to left yourself, it should be possible to get to work.

test84

  • Jr. Member
  • **
  • Posts: 71
    • View Profile
Re: How to get input and output of Arabic/Persian/Farsi texts?
« Reply #2 on: March 15, 2014, 08:01:45 pm »
Thanks.

Is there any way to prevent user from entering any text beside standard English, like Farsi/Arabic?

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: How to get input and output of Arabic/Persian/Farsi texts?
« Reply #3 on: March 15, 2014, 10:00:55 pm »
No there isn't but you do have the code to tweak as you wish.

test84

  • Jr. Member
  • **
  • Posts: 71
    • View Profile
Re: How to get input and output of Arabic/Persian/Farsi texts?
« Reply #4 on: March 17, 2014, 05:23:14 am »
For future reference and anyone finding this via search, here is how I did it. Replace this from tk2dUITextInput.cs:

If I don't want to modify tk2d, should I make this protected, inherit from this class and then override this method with my own?