Am Fri, 19 Mar 2010 21:25:59 +0100 schrieb Philiрp Rеichmuth: > is there a way to force the onscreen rendering for the text contained in a > given character or paragraphy style to be right-to-left? Ideally some kind > of command within the InsetLayout or Style groups in the layout options? > > Background: [...]
Clarification: I use XeTeX, which has directionality commands inherited from eTeX; there's a package called bidi.sty that wraps them in a nice user interface. To access this, I use a paragraph style for RTL paragraphs, and character styles for embedded RTL text (and embedded LTR text in RTL paragraphs). These styles also change the font. Now LyX obviously doesn't know that whatever is formatted in those styles is actually RTL. So the display order is broken. I've attached a sample file to show what this looks like. It requires XeTeX, bidi.sty, and some fonts - I used Charis SIL and Scheherazade, both freely available from <http://scripts.sil.org/>. It seems that the generated 46 kB PDF file is too large for an email attachment to the list. For comparison to how it looks in the final output, I've uploaded it to <http://freepdfhosting.com/15665b4a39.pdf>. Setting the language of the text to Arabic doesn't work; it gets the display order right, but then LyX makes assumptions about rendering the text using either ArabTeX or arabi.sty, which is obsolete now thanks to XeTeX ;). (It also activates the Arabic spellchecker, which is a nuisance because the text is in Arabic script, but not in the Arabic language.) So what I'm looking for is a way to tell LyX that whatever is in a given style should be rendered in RTL. Can this be done? I reckon this kind of problem will pop up more frequently as soon as LyX supports XeTeX regularly and more people start using it for their weird alphabets. Philipp
arbidi.lyx
Description: Attached file: arbidi.lyx