[XeTeX] Anomalies in using feature-enabled OT fonts

Peter Dyballa Peter_Dyballa at Web.DE
Sun Nov 21 00:01:19 CET 2010

Am 20.11.2010 um 16:35 schrieb Takayuki YATO (ZR):

> I understand your explanation and admit it's logical. But from the
> grammar of XeTeX I have the impression that XeTeX treats a font with
> some feature enabled as different from the original font; that is,
> there are two distinct fonts \tgpNorm and \tgpSmcp, and the latter has
> small-caps glyphs for lowercase characters. In this view, the glyph at
> slot 97 is different between these "two" fonts. And it is quite  
> natural
> that one expect \fontcharwd, \XeTeXcharglyph, etc. applied to \tgpSmcp
> return the information on the small-caps glyphs.

When one is trying to measure something one often is not able to  
measure this thing... And I think you were always referencing the  
standard glyphs while XeTeX allows for the printed glyphs that are  
somehow "translated".

So I changed your macro and text body a bit, which now gives quite  
reasonable values:

	 #1 % print the character
	 \immediate\write16{% output to terminal
	\font\tgpNorm="TeX Gyre Pagella"       % default
	\font\tgpSmcp="TeX Gyre Pagella:+smcp" % small-caps
	% There two lines should not report the same measurement....

But I think it would be nice to have easy means to determine the  
printed glyph's dimensions.



"Evolution"            o           __o                     _o _
           °\___o      /0~         -\<,              ^\___ /=\\_/-%
oo~_______ /\ /\______/ \_________O/ O_______________o===>-->O--o____

More information about the XeTeX mailing list