maxwell wrote: > > Another problem we're having is with the display of the Thaana script. > This is a right-to-left script, Unicode range 0780 to 07BF. Java's display > of this is buggy (and I do think the problem is with Java, not specifically > with XXE). In particular, while the first line of a Thaana paragraph is > rendered on-screen right-to-left, succeeding lines are rendered > left-to-right. This may be a problem only with the Windows implementation > of Java, although I have not been able to test this. Java is of course > capable of displaying Arabic or Hebrew right to left, and even moving the > insertion point correctly, although the visible display of the cursor is > wrong in these languages. > > XXE does not support the common 'dir' attribute, which would allow <para>s > and other elements to be marked as 'rtl'. Nor does XXE support the CSS2 > 'direction' property. Of course, given that Java has problems with > right-to-left scripts already, this might not solve the problem. > > We have found one work-around that does result in correct right-to-left > display of Thaana: we put a Unicode RLE (Right-to-left embedding) character > (U+202B) at the beginning of any run of Thaana script (i.e. immediately > after the open <para>, <phrase> etc. tag), and an LRE character (U+202A) at > the end. (One might think that the opening RLE would be sufficient to at > least start right-to-left dispaly, but it isn't; the close LRE character > seems necessary as well.) > > One problem with this work-around is that we might need to create a > keystroke (or templates) to insert these characters. More problematic is > the fact that the characters are invisible (zero width), making it hard for > authors to correctly position the cursor, and also making it possible to > accidentally delete the characters and not even know it (until text starts > showing up wrong--but that might not happen until you narrow the screen, > forcing wrapping, etc.). If we could colorize runs of Thaana text that did > (or didn't) start and end with these characters, that would be a partial > solution. But I can't find anything in CSS that would allow me to do this. > > I've also tried putting the Unicode RLE character in an attribute of the > <para> tag, instead of in the text element, but of course CSS ignores that. > We've even tried altering the font to render the RLE and LRE characters as > non-zero width characters, but if that's possible, it's not easy.
It's possible and not difficult at all: copy the existing glyph of character A and paste it in character B. I did that a long time ago using FontForge (http://fontforge.sourceforge.net/): ugly, but works fine. However I don't think you'll be able to see the glyphs of U+202A and U+202B. In my understanding, characters such as U+202A and U+202B are never displayed because they are seen as *directives* by the text rendering machinery of Java. > > Any suggestions? Sorry but I don't really see. > (Any chance that the CSS2 'direction' property will be > supported soon?) Sorry again but the answer is no. -- XMLmind XML Editor Support List [email protected] http://www.xmlmind.com/mailman/listinfo/xmleditor-support

