as the title says , a text from a RTL language like persian or arabic doesnt show well in android for example the word "سلام" shows as "م ا ل س". this problem happens even in text inputs (which i thought they were native and native android textboxes support that) is there a way to fix this?
-
2Bidi mode is not supported in FireMonkey. See [`QC 98644 All FireMonkey controls should have BiDiMode property`](http://qc.embarcadero.com/wc/qcmain.aspx?d=98644). – LU RD Sep 18 '13 at 22:34
-
4wow the topic is from the year 2011 and still not fixed .. – Adib Faramarzi Sep 18 '13 at 22:43
-
I'd prefer that we have XPlatform rather than BiDi support, and add the latter at a future date. The majority of Delphi users don't work in RTL languages, AFAIK, based on traffic at the EMBT forums and here at SO. If a choice is "support the highest percentage of users first", it's usually the right one. :-) If bidi was done first, you wouldn't have Android support at all, and it wouldn't be an issue, right? – Ken White Sep 19 '13 at 00:37
-
4I'd rather we had cross platform, and bidi, and a much less buggy product. I don't buy that these are mutually exclusive. – David Heffernan Sep 19 '13 at 06:09
-
2I think absence of BiDi is the bigest blind spot of FM. – mh taqia Sep 19 '13 at 06:27
-
This question appears to be off-topic because it is a firemonkey bug report. – Kuba hasn't forgotten Monica Oct 03 '13 at 15:03
-
Have you found any solution!? – Amin Aug 27 '14 at 07:31
-
No i haven't found a definitive solution yet.this topic is about a year and a half old , so there might be newer solutions to this matter , so please check the web. – Adib Faramarzi Feb 17 '15 at 06:26
-
See: http://sourceforge.net/projects/dpfdelphiandroid/ and http://sourceforge.net/projects/dpfdelphiios/ – Johan Apr 04 '15 at 20:21
3 Answers
Lack of Bidirectional and Glyph Shaping support is a known restriction of the FireMonkey platform, on all targets (including Windows and Mac OSX).
We will have to wait for "native controls" for Android as third party components for FireMonkey, as it does exists for iOS - see http://www.tmssoftware.com/site/tmsicl.asp for instance.
I've found this great blog article with source code about Android Native controls for Lazarus/FreePascal which is quite interesting. But this won't work with the "NextGen" Delphi compiler, which is currently going in a diverse direction in respect to FPC (e.g. with the ObjectivePascal mode).
Since it uses native Android controls, it should not suffer from the same restrictions as FireMonkey do.

- 42,305
- 3
- 71
- 159
-
the last link your provided is really great , is there a way to actually use those Pascal Android native controls in delphi XE5?(i mean is there a way to add them as components in delphi and use them?) – Adib Faramarzi Sep 19 '13 at 10:39
-
@SNAKY it is in the source: "Free Pascal Compiler FPC 2.7.1, ( XE5 in near future )" – mjn Sep 19 '13 at 10:55
-
I just wrote a [small blog article about this... blog article](http://blog.synopse.info/post/2013/09/19/FreePascal-Lazarus-and-Android-Native-Controls)... :) Only benefit is that it is in English. Could be good that those "Native UI components for FPC" projects are better known - in fact, there is a [sibling Native iOS Controls project using FPC available](http://blog.naver.com/simonsayz/120193098772) to target also iPhone/iPad devices – Arnaud Bouchez Sep 19 '13 at 12:15
As per LURD's suggestions.
Download and use D.P.F Delphi Android Native Components and/or D.P.F Delphi iOS Native Components.
That will fix the problem in XE7 and prior.
According to the documentation with the Delphi XE8 beta the problem is fixed there as well.
As a last resort (if you feel up to it), someone has taken the effort to patch the XE5 source code to enable BiDi support. See: https://docs.google.com/file/d/0BwumWe43CaijVDRQZzNQbXNSLWc/edit?usp=sharing

- 74,508
- 24
- 191
- 319