[XeTeX] letter spacing
Jonathan Kew
jonathan_kew at sil.org
Sun Jun 4 23:32:42 CEST 2006
On 4 Jun 2006, at 9:42 pm, public at heslin.eclipse.co.uk wrote:
[useful discussion snipped]
> So, Jonathan, it would be great if Xetex would provide this too.
I have a couple of ideas on how we might approach this, and perhaps
some folks will have comments on which you'd prefer to see
implemented. (I'm not promising anything, just thinking aloud!)
(1) Letterspacing as a TeX font property, settable from within the
document. There are a couple of ways this could be specified:
(1.a) a "pseudo-feature" in the \font definition, something like \font
\mycaps="MyFont:+smcp,letterspace=0.05" to add 5% of the em-size
between letters
(1.b) specify a \fontdimen that xetex would use to apply such an
adjustment, so you could say something like
\font\mycaps="MyFont:+smcp" at 24pt
\fontdimen9\mycaps=0.5pt
(2) Letterspacing by inserting glue; a new parameter such as
\XeTeXinterletterglue that (if non-zero) would be automatically
inserted between characters. This would make it easy to do things
like spacing text out to exactly fit a given width (by making the
interletter glue stretchable). Obviously, this could be horrendously
abused, too, but that in itself is not a reason to reject it!
In all these cases, things get a little tricky when we're dealing
with general Unicode text, not just English typography. For example,
we mustn't allow letterspacing adjustments to affect the relative
positioning of base characters and diacritics, or to interfere with
script-specific glyph processing that's specified in the OpenType
tables.
(There's also "(3) Access to AAT tracking tables, when rendering with
ATSUI on Mac OS X", but so few fonts actually include a 'trak' table,
as far as I've seen, that I'm not sure this is worth doing.)
Comments/suggestions?
JK
More information about the XeTeX
mailing list