[XeTeX] xunicode.sty -- pinyin and TIPA shortcuts
spence at saar.de
Fri Apr 7 03:47:18 CEST 2006
Something that had been literally staring me in the face all the time...
> I'm pretty sure the Chinese government prefers the upright italic
> shape for lowercase a and g in pinyin, but I'm not sure how strict
> this is.
... I've only just now noticed that when typing inside a \textipa
environment as defined by xunicode.sty and using the Gentium font the
lowercase g I'm getting is the _wrong_ one, i.e. the one that looks
like a pair of spectacles rotated ninety degrees, not the one the
teacher writes on the blackboard in primary school. For phonetics it
really has to be the blackboard-type g, because the amount of
topological variation involved in not only changing the shape of a
curve but actually closing it on itself is systematically meaningful
within IPA, i.e. whenever you put a little extra hook or turn
somewhere on a glyph, it turns it into a different glyph standing for
a different sound.
Tricky... In this case XeTeX needs to know what font you're using
before it can decide which unicode point the g in your input text
should be addressing: plain old 0067 if you're using a sans serif
font or an italic roman font, otherwise whatever unicode point (1D4D
maybe?) corresponds to the special lowercase g phonetic letter
(provided the font supports it); otherwise XeTeX has to fall back on
using the wrong glyph, but in that case should perhaps issue a
console warning and record it in the log file.
Hmmm.. from memory Fukui Rei had a command \textg and it would give
you _either_ the one shape _or_ the other depending on which input
mode you were in at the time: in what could be called the "longhand"
input mode you typed \textg for the special phonetic glyph, but in
the "express" input mode typing just g would give you the special
phonetic glyph and if you needed the normal (serif-) roman font glyph
you typed \textg .
At line 752 of xunicode.sty I see that \textg is assigned to unicode
0067, and that's the only occurrence of \textg in the file. So that
would mean... perhaps... having to write some kind of patch that
would do, the XeTeX unicode way, what Rei's \textg does?
Does anyone have an out-of-the-box solution for this?
And does this (admittedly almost maximally minor) problem relate to
the issue of fallback fonts mentioned in Malte Rosenau's XeTeX list
posting of 06/04/2006 ?
Curious to find out more about all this...
-- Rob Spence
P.S. I just saw Will Robertson's latest posting in which he suggests
a "xetipa" package.. ("Curiouser and curiouser!")
More information about the XeTeX