[XeTeX] arabic problem with polyglossia

Ross Moore ross at ics.mq.edu.au
Tue Dec 29 04:26:29 CET 2009

Hi Vafa,

On 29/12/2009, at 12:13 PM, Vafa Khalighi wrote:

> I'm not sure whether this is the complete solution,
> as the usage of  \addfontfeature  looks like it might result
> in the same feature being added multiple times.
> This might break something, or eventually overload something.
> Some extra grouping braces might be needed to prevent this.
> There is no need to change \@arabic counter at all. bidi makes sure  
> (without changing it) that anything that uses \@arabic counter, is  
> done perfectly.

Good; that is the way it should be, IMHO.

It can be achieved by putting this at the end of the preamble:

>> \makeatletter
>>  \AtBeginDocument{\let\@arabic\default at arabic}
>> \makeatother

Now the .aux  has this line:

>> \@writefile{toc}{\contentsline {section}{\numberline {1}يوسف  
>> شريم}{1}}

whereas previously (with  the \protect s) it was:

>> \@writefile{toc}{\contentsline {section}{\numberline  
>> {{\addfontfeature {Mapping=arabicdigits}1}}يوسف شريم} 
>> {{\addfontfeature {Mapping=arabicdigits}1}}}

It is better to have just the numbers and section-title ---
information having nothing about the font features or styles.
The context of where this information is being used should
be what determines the stylistic appearance.

> -- 
> Best wishes,
> Vafa Khalighi



Ross Moore                                       ross at maths.mq.edu.au
Mathematics Department                           office: E7A-419
Macquarie University                             tel: +61 (0)2 9850 8955
Sydney, Australia  2109                          fax: +61 (0)2 9850 8114

More information about the XeTeX mailing list