[XeTeX] Urdu script problems

François Charette firmicus at ankabut.net
Tue May 26 20:26:40 CEST 2009


maxwell a écrit :
> We're using XeTeX to typeset an Urdu grammar.  The grammar itself is
> written in DocBook XML, then converted to XeTeX using the dblatex program
> (dblatex.sourceforge.net).  We're using the Nafees Nastaleeq font, version
> 1.02 (www.crulp.org/software/localization/Fonts/nafeesNastaleeq.html) for
> the Urdu script.
>
> We've encountered some problems with a few characters.  We checked with Dr.
> Sarmad Hussain, the head of CRULP (Center for Research in Urdu Language
> Processing), where the Nafees Nastaleeq font was developed.  When he runs
> the text of some of our problematic words through Microsoft Word to produce
> a PDF, the characters come out fine.  So my guess is that XeTeX is doing
> something wrong, perhaps choosing the wrong glyph for some of the
> characters.  Or perhaps I don't understand the parameters on \newfontface
> (like how to tell it the language is Urdu, if that matters).  
>   
In principle you could specify "Language=Urdu", but since the font
Nafees Nastaleeq does not have an OpenType language tag for Urdu, this
would have no effect.

> Anyway, I'm attaching a semi-minimal document to illustrate the problems
> (semi-minimal, in that you'll need to tell fontspec where you keep the
> Nafees Nastaleeq font--my 'ExternalLocation' probably won't work for you). 
> This document illustrates several of the problems we have had (there are a
> few others, but if I can fix these, the others might clear themselves up?).
>  I'm also attaching PDFs showing the right and wrong output;
> SampleProblems.pdf is our output from running xelatex on the attached
> SampleProblems.xelatex (and shows the wrong alef etc.), while
> CorrectOutput.pdf is a PDF we received from Dr. Hussain.  (It's not quite
> the same document, but does show the correct form for the Urdu words that
> come out wrong in our output.  I can't reproduce the correct output in
> Word, for reasons I don't quite understand--possibly a version difference
> in Word.)
>
> I should also say that we're still running xe(la)tex version
> 3.141592-0.996. 
That is most certainly the reason. I remember having encountered the
same kind of problem with an earlier version of Nafees Nastaleeq when I
originally developed ArabXeTeX on XeTeX 0.996. But now your sample file
produces a perfect output with Nafees Nastaleeq 1.02 under XeTeX version
0.999.6 and xdvipdfmx  0.7.3 (TeXLive 2008).

>  We downloaded the newer version (TEX Live 2008), but
> haven't gotten around some install glitches yet (particularly the
> hyphenation problem--I can't recall where those 8-bit files are, so I can
> convert them to UTF-8).  If upgrading will solve our problem, that would be
> good to know.
>   
Yes, you should definitely update! TeXLive 2008 comes with UTF-8
hyphenation patterns for all languages, but I am not sure to understand.
Please be more specific on your installation glitches and we will
certainly be able to help.

Best,
François Charette

PS: Please don't use an existing thread when posting on a different topic ;)


More information about the XeTeX mailing list