4

A long time ago i posted about an error I occur when trying to set the mainfont using xelatex and the fontspec package, specifically the bold/italic/bolditalic fonts.

My previous post from 2011 is posted here: old post

Basically it's impossible for me to set the boldfont and bolditalic fonts in this way:

\usepackage{fontspec}
\usepackage{xunicode}
\usepackage{xltxtra}
\usepackage{polyglossia}
\setmainlanguage{english}

\setmainfont[Path=C:/fonts/SabonNext/,
   BoldItalicFont=SabonNextLT-DemiItalic.otf,
   BoltFont      =SabonNextLT-Demi.otf,
   ItalicFont    =SabonNextLT-Italic.otf]
                 {SabonNextLT-Regular.otf} 

The problem is that the main font (SabonNextLT-Regular.otf) is recognized, however the bold/bolditalic/italic variants I try to define are not recognized. It gives me three errors of the time: the key 'fontspec'/BoltFont' is unknown and is being ignored

I'm almost certain that this is a bug in the fontspec package, but could someone be so kind and try to reproduce the error with your font of choice, so I know I'm right?

Timtico
  • 2,250
  • 2
    It looks like you have a typo: Change "Boltfont" to "Boldfont", and things should run smoothly. – Mico Mar 21 '13 at 17:11
  • ah I'm sorry I made that type when reproducing the error. However, fixing this doesnt fix the error. I've contacted the fontspec people and hope they could help – Timtico Mar 21 '13 at 20:46
  • 2
    why is this question closed? It is very relevant since It is a known bug in the fontspec package, something the maintainer of the fontspec package – Timtico Mar 21 '13 at 21:14
  • Have you checked the spelling of the font's filenames? On my system -- as well as on Linotype's online catalogue for the "Sabon Next" font family -- the file names that end in .otf have an extra "Pro" string, as in SabonNextLTPro-Regular.otf and SabonNextLTPro-Italic.otf, and those that end in .ttf contain an extra "Com" string but no "LT" string, as in SabonNextCom-Regular.ttf and SabonNextCom-DemiItalic.ttf. – Mico Mar 21 '13 at 22:08
  • yes, I checked that. Were you able to reproduce the problem? – Timtico Mar 22 '13 at 08:56
  • No, I'm not able to replicate the problems you describe -- when I use the file names that apply on my computer. – Mico Mar 22 '13 at 09:27
  • thats very unfortunate, I will give the fontfiles some arbitrary names and see if I still have the same problem. So when you use the code described boldfont etc work perfectly fine? – Timtico Mar 22 '13 at 12:31
  • I've retested it with other fonts, and it's this specific font that is giving me problems (Sabon). Perhaps something wrong with the files althought I'm able to use them when installed on my system. – Timtico Mar 22 '13 at 12:53
  • Since you don't seem to be encountering similar problems with other fonts, it would indeed appear to be the case that there's something defective about the "Sabon Next" fonts you have on your system. – Mico Mar 22 '13 at 13:37
  • yeah it seems so... will try it with the old Sabon font I've used for many years. – Timtico Mar 22 '13 at 16:00

0 Answers0