[The rest of this post is now outmoded - PsychoPy (at least when running locally) should now display Arabic and Farsi text correctly. In your text component, click the “Formatting” tab and select “Arabic” as the language style. Not all fonts will correctly display Arabic text, however. Start with Arial
, as a good option on Mac and Windows: the default option of Open Sans
doesn’t seem to work well.]
Some years ago, it was noted that PsychoPy does not correctly display Persian or Arabic text stimuli. Strings can be pasted correctly into dialog boxes but when displayed on-screen as stimuli, the characters are displayed left-to-right rather than right-to-left and the individual glyphs are isolated, not correctly flowing into each other as influenced by their neighbouring characters.
These issues were discussed here by PsychoPy users and developers, with some text and pictorial examples provided for reference:
https://groups.google.com/forum/#!topic/psychopy-users/HJgyKNaSlKQ
and some work-arounds noted. In particular, Abdullah Diab provides an online ‘reshaper’ for Arabic text here:
http://pydj.mpcabd.xyz/arabic-reshaper/
He describes the issues involved here:
http://mpcabd.xyz/python-arabic-text-reshaper/
That online service can be used to ‘re-shape’ text so that although it no longer looks correct in a dialog box in PsychoPy or in a conditions file, it will be rendered correctly on screen in text stimuli. Abdullah also maintains this as a Python package here:
https://github.com/mpcabd/python-arabic-reshaper
so this function could be integrated into PsychoPy so users don’t have to make workarounds, such as re-shaping text themselves or displaying text via images.
Alternatively, PsychoPy is also not too far away from making the transition to Python 3. The improved Unicode handling there might (possibly) help with this situation.
Are there Arabic- or Farsi-speaking PsychoPy users who would be willing to do some testing of ways to address these issues? Apart from @hsogo12600, who has done great work over the years to localise PsychoPy into Japanese, most of the PsychoPy developers work with Latin scripts and would need help to understand the issues involved.