I have attempted to install a new font (source-sans-pro) onto my gentoo server, however when I run xelatex test.tex the PDF file it generates uses the font but does not give the expected output - i.e. the words "this is a test" show as the attached image:


The code I am using is as follows:

\setromanfont[Mapping=tex-text]{Source Sans Pro Light}


This is a test.


Nothing ground breaking there - I'm wondering if perhaps the font has not been installed correctly, after a bit of googleing I found the following website - however following said instructions doesn't really give me anything other than the same result again..does anyone have any ideas? or even links to some documentation on how to install XeLaTeX fonts on gentoo correctly?

  • Welcome to TeX.SX. Usually, we don't put a greeting or a "thank you" in our posts. While this might seem strange at first, it is not a sign of lack of politeness, but rather part of our trying to keep everything very concise. Upvoting is the preferred way here to say "thank you" to users who helped you. – Claudio Fiandrino Jan 23 '13 at 14:05
  • Did you download Source Sans Pro from here?. Also: does the same happen when you use \usepackage[default,otf,light]{sourcesanspro}? – Silke Jan 23 '13 at 15:02
  • Tried that - and I get the following error: ! LaTeX Error: File `sourcesanspro.sty' not found. – andy99998 Jan 23 '13 at 15:21

I suppose that the fonts are already installed in your system. XeTeX does not like it when fonts are installed twice. Delete the otf-fonts in your tex tree or in /usr/share/fonts/opentype/ and it should work.

after deleting the system fonts: run fc-cache -fv

after deleting the tex fonts: run texhash

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.