3

Just few days ago I decided to give XeLaTeX a try for its wonderful use of system fonts.

I read a bit on the net about "fundamental lines" to change (I come from LaTeX) which basically boil down to (and correct me if I'm wrong!)

\usepackage{fontspec}
\setmainfont{<whatever>}

Now this yields very ugly math fonts. I wanted to use "Asana Math" via

\usepackage{unicode-math}
\setmathfont{Asana-Math}

but then this happens

! fontspec error: "font-not-found"! The font "Asana-Math" cannot be found.!! <etc.>

I'm using Mac OS X 10.7 with the latest TeX Live distribution (I even ran TeX Live Utility to update anything "updatable" to make sure) and as editor TeX Studio. But I want to underline that this same error happens using the Terminal with

xelatex [-shell-restricted] <filename>.tex

I am "sure" the fonts are installed, at least Tex Live Utility says so. The issues presents even with this MWE

\documentclass[10pt,a4paper]{scrartcl}
\usepackage[T1]{fontenc}
\usepackage{fontspec}
\usepackage{unicode-math}
\setmainfont{Ubuntu}
\setmathfont{Asana-Math}

\begin{document}
Formula
\begin{equation}
    \sum_0^\infty 1/x^n = \frac{1}{x-1}
\end{equation}
\end{document}

Thank you in advance!

P.S.: I am reluctant to call the above MWE. It is not! It'a M inimal N ot W orking E xample!

1 Answer 1

6

You need the file extension (this is always the safest way to load a font in any case)

\setmathfont{Asana-Math.otf}
0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .