3

I'm trying to use fontspec (XeLaTeX) in combination with the Boisik font, which turns out to be hard.

The following order

\usepackage{boisik}
\usepackage{fontspec}

leads to fontspec overriding Boisik with Latin Modern, and I can't seem to recover it (except for the Math, which remains Boisik).

The other order,

\usepackage{fontspec}
\usepackage{boisik}

I get ! LaTeX Error: This NFSS system isn't set up properly.

The combination

\usepackage{fontspec}
\usepackage[T1]{fontenc}
\usepackage{boisik}

avoids the former error, but the result is as in the first case: Latin Modern everywhere but in the math.

Any other combination I could think of yields one of the same results as above.

So basically my question is, which would be the way to go to combine Boisik with a TTF font? Is there a way at all?

As a side note, I've tested the same with the Fourier font, and

\usepackage{fourier}
\usepackage{fontspec}

produces the same result as with Boisik (math Fourier, text Latin Modern), while

\usepackage{fontspec}
\usepackage{fourier}

does not produce an error but instead the very result I wanted: Fourier everywhere but the ability to use fontspec to include new font families for headings.

Any help is most appreciated. Thanks in advance.

apo13
  • 71

1 Answers1

4

Upon re-reading the question, I realized I did not try the following:

\usepackage{fontspec}
\usepackage[OT1]{fontenc}
\usepackage{boisik}

which is actually the solution. I'll leave it here for future reference. My apologies and thanks for your time.

Edit: Minimal working example as requested:

\documentclass{book}

\usepackage{amssymb}

\usepackage{fontspec}
\usepackage[OT1]{fontenc}
\usepackage{boisik}

\newfontfamily{\arialFamily}{Arial}

\begin{document}
This document uses Boisik, but can change to {\arialFamily Arial} if desired.
\end{document}

This document uses Boisik, but can change to Arial if desired.

It is necessary to include amssymb before \usepackage{boisik} to resolve the issue of LaTeX Error: Command '\hbar' already defined.

apo13
  • 71