From: Hans Hagen <pragma@wxs.nl>
To: ntg-context@ntg.nl
Subject: Re: wrong behaviour with ConTeXt unicode bidi
Date: Tue, 10 Sep 2013 17:26:43 +0200 [thread overview]
Message-ID: <522F3A33.6070809@wxs.nl> (raw)
In-Reply-To: <CAJZ8fyoj2sPjfmZLc-MAdge9j_SDkyhATTB3zZSCFKgP_RVrcA@mail.gmail.com>
On 9/10/2013 2:57 PM, Vafa Khalighi wrote:
> Hi
>
> The following document shows the wrong behaviour (the second parentheses
> is mirrored incorrectly and it should be after the number not before the
> number).
>
> Assuming "test" is an RTL word when I write (test 1363) I expect to get
> exactly that but somehow I get (test (1363
new beta ... also with fix for issue khaled mentioned
\starttext
\setupalign[r2l]
\definefont[arabicfont][Arial*arabic at 20pt]
\enabletrackers[typesetters.directions.one]
\enabletrackers[typesetters.directions.two]
\setupdirections[bidi=global,method=default] \arabicfont این (یک آزمایش
1363) است. \par
\setupdirections[bidi=global,method=one] \arabicfont این (یک آزمایش
1363) است. \par
\setupdirections[bidi=global,method=two] \arabicfont این (یک آزمایش
1363) است. \par
\stoptext
> One related question: is it possible to change font automatically when
> luatex sees a LTR word?
no, but you can define start\stop commands that deal with such switches
also, you can combine fonts (and there a yet not documented auto
script/language switcher .. i have no time now to explain that one)
btw, never use \textdir and \pardir directly (i might even define them
as no-ops some day) but use the higher level alignment commands
Hans
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
| www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
next prev parent reply other threads:[~2013-09-10 15:26 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-10 12:57 Vafa Khalighi
2013-09-10 15:26 ` Hans Hagen [this message]
2013-09-10 15:45 ` Vafa Khalighi
2013-09-10 16:20 ` Vafa Khalighi
2013-09-11 9:47 ` Vafa Khalighi
2013-09-11 11:34 ` Vafa Khalighi
2013-09-11 12:37 ` Hans Hagen
2013-09-11 15:24 ` Khaled Hosny
2013-09-11 17:10 ` Hans Hagen
2013-09-12 14:19 ` Vafa Khalighi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=522F3A33.6070809@wxs.nl \
--to=pragma@wxs.nl \
--cc=ntg-context@ntg.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).