Text FormattingWhere \fontspec looks for files

Information and discussion about LaTeX's general text formatting features (e.g. bold, italic, enumerations, ...)
Post Reply
Laurentius
Posts: 132
Joined: Wed Feb 11, 2009 11:38 pm

Where \fontspec looks for files

Post by Laurentius »

When specifying an uninstalled font file with \fontspec, e.g. by

Code: Select all

\fontspec{[caslon.otf]}
the file has to be in the same directory as the tex-file. Is there any way to get \fontspec to look for it elsewhere?
Last edited by Stefan Kottwitz on Wed Feb 22, 2012 3:32 pm, edited 1 time in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

Stefan Kottwitz
Site Admin
Posts: 10345
Joined: Mon Mar 10, 2008 9:44 pm

Where \fontspec looks for files

Post by Stefan Kottwitz »

You can specify a path, such as

Code: Select all

\fontspec[Path = /home/laurentius/fonts/]{caslon.otf}
and

Code: Select all

\setmainfont[Path = /home/laurentius/fonts/]{caslon.otf}
Stefan
LaTeX.org admin
Post Reply