[XeTeX] "Missing" system fonts

Bruno Voisin bvoisin at mac.com
Fri May 25 09:27:02 CEST 2007


Le 25 mai 07 à 08:59, John Was a écrit :

> I'm a novice with XeTeX (on Windows) and haven't yet worked out the  
> niceties
> of font access, but I have found that fonts I haven't installed on my
> system, or fonts which XeTeX seems to be having trouble locating,  
> can be
> accessed by going directly to the font file and putting square  
> brackets
> round the name (as in the documentation), e.g.
>
> \font\outlinefont = [d:/temp/MinionPro-Regular] at  14pt

If you've got to do that in order to access a font, then I would  
suspect a misconfiguration of your system. The problem does not seem  
to lie within XeTeX, but within fontconfig upon which XeTeX relies to  
access fonts on Windows. Hence it's the doc of fontconfig you should  
look at, not that of XeTeX.

Useful tips have been given already:

> Le 22 mai 07 à 10:14, Akira Kakuto a écrit :
>
>> You have to run a command
>> fc-cache -v
>> in order to create data files for fontconfig.

> Le 22 mai 07 à 10:43, Akira Kakuto a écrit :
>
>> Please go to the directory .../bin/win32/conf/
>> and edit the file fonts.conf:
>>
>> line 16 of fonts.conf is
>> <dir>c:/windows/fonts</dir>
>>
>> Please rewrite this line as
>> <dir>YourDriveLetter:/YourSystemFontDir</dir>
>>
>> and run fc-cache -v once more.

If you don't do that, fontconfig won't know where to look for fonts,  
neither will it index the fonts already present on your system. As a  
result, XeTeX won't be able to find the fonts, unless you take it by  
the hand and give it the full paths for the font you are using; which  
is precisely what you seem to be doing.

And also, but that's probably more relevant to PDF file generation  
than to font inclusion:

> Le 21 mai 07 à 11:55, caapv 208 a écrit :
>
>> --- John Was <john.was at ntlworld.com> wrote:
>>
>>> Here is my dvipdfmx.cfg file as requested - doesn't
>>> mean a lot to me!
>>
>> You have:
>>
>> %%
>> %% GhostScript (Unix/Linux):
>> D "gs -q -dNOPAUSE -dBATCH -sPAPERSIZE=a0 ...
>>
>> %% GhostScript (Win32):
>> %D "gswin32c -q -dNOPAUSE -dBATCH -sPAPERSIZE=a0 ...
>>
>> If you are on Win32, then you have to activate the
>> latter.

If you don't do that, xdvipdfmx, which XeTeX invokes behind the scene  
to produce PDF files, will use a configuration appropriate for Linux,  
not Windows. Accordingly, it's not surprising the generated PDF  
files, if any, won't behave as expected.

I can't help more, as I'm a Mac user since circa 1988 and have never  
(I'm not kidding!) used Windows, other than giving a hand to friends  
and colleagues now and then.

Bruno Voisin


More information about the XeTeX mailing list