[XeTeX] Microtypography?

Jonathan Kew jonathan_kew at sil.org
Sun May 21 14:55:00 CEST 2006


On 21 May 2006, at 12:44 pm, Ralf Stubner wrote:

> Ralf Stubner <ralf.stubner at physik.uni-erlangen.de> writes:
>
>> Would that also be true for OpenType fonts with the (equally named)
>> 'opbd' feature? Or would that require additional coding in ICU(?)  
>> first?
>> I don't have a font that supports this feature, but I could build  
>> one,
>> once I really understand how the OT specs are to be interpreted  
>> wrt to
>> 'opbd' and its relation to 'rtbd' and 'ltbd'.
>
> Some success: I have build an OpenType TT font in which the advance
> width of the hyphen might be reduced (by an insanely large amount ;-)
> via an 'opbd' feature and (separately) via an 'rtbd' feature.  
> Switching
> on one of these feature in XeTeX does indeed make the hyphen go  
> into the
> margin. However, the change in advance width is also applied in normal
> text, which is of course not what I want.
>
> I have no idea if this in an error in the font, in XeTeX, in ICU, or
> somewhere else.

To use this, XeTeX would have to apply the feature selectively, only  
when the hyphen appears at end-of-line; but switching it on via the  
\font command causes it to be applied throughout the text.

XeTeX does not currently have any support for applying OpenType  
features selectively like this, except for the various script- 
specific "shaping engines" -- but that's a slightly different  
scenario. Making use of OpenType 'opbd' features would require  
additional logic in XeTeX itself, as this is the only place where the  
line boundaries can be identified.

JK



More information about the XeTeX mailing list