[XeTeX] Charis SIL glyph variants
Jonathan Kew
jonathan at jfkew.plus.com
Tue Nov 18 12:33:31 CET 2008
On 18 Nov 2008, at 10:03, Benct Philip Jonsson wrote:
> On 2008-11-17 Jonathan Kew wrote:
>> %%%%%% test file %%%%%%%
>> \font\x="Charis SIL" at 12pt
>> \font\y="Charis SIL/GR:Uppercase Eng alternates=Large eng
>> on baseline"
>> at 12pt
>>
>> \x This is Charis with the default capital Eng, J.
>>
>> \y This is Charis with an alternate capital Eng, J.
>>
>> \end
>> %%%%%% end %%%%%%%
>
> Thanks for the help. I have some follow-up
> questions, however.
>
> So I can't get at it through fontspec?
I'm not sure if fontspec has support for specifying the Graphite
rendering option.... Will, are you listening?
> Do I have to use TeX rather than LaTeX font definition
> commands? I have nothing against it, I just want to know.
If fontspec supports the Graphite option, then you could use its
RawFeature option to pass the custom feature names to the font (see
the fontspec manual).
>
> Perhaps I could do something like
>
> %%% example %%%
>
> \font\alteng="Charis SIL/GR:Uppercase Eng alternates=Large
> eng on baseline" at 11pt
> \[re]newcommand{\NG}{\alteng\char"014A}
>
> % And then in the document
>
> VƏ\NG HUŠ
>
> %%% end %%%
I would recommend setting the font for the whole run of text, rather
than the individual character. And if you can go through fontspec and
use \newfontfamily, you'll get something that adapts to the current
font size, etc., rather than just a single, fixed-size instance, so
that's much better if it is supported.
>
>
>> Although both capital Eng characters in the source are
>> simply U+014A,
>> they will render with different glyphs because of the
>> optional feature
>> applied in the second font definition.
>>
>> **WARNING**
>>
>> Unfortunately, it turns out that a bug in xetex 0.999.6
>> (and earlier)
>> means that it will go into an infinite loop if you try
>> this, but if
>> you can build 0.999.7 from the source in Subversion (from
>> either the
>> xetex or texlive repositories), it should work.
>
> So I'll have to compile it myself? :-/
>
> What are the right commands, including those to
> download from Subversion? Mind you I'm originally a
> philologist, not a computer scientist, and I just
> recently went over to Linux!
If you check out the code from the xetex repository on
scripts.sil.org, there is a "build-xetex" script that should work. You
may need to install some development (-dev) packages first (e.g.,
fontconfig). There is some brief information at http://scripts.sil.org/xetex_linux
. Be sure to get the latest sources (see note at the end of the page),
as the 0.999.6 package will still have the Graphite feature bug.
Maybe an Ubuntu user here can give you an exact recipe of commands
that will install Subversion, check out the latest source, build, and
install.... anyone???
JK
More information about the XeTeX
mailing list