[XeTeX] Book Templates

sjo sjo222 at gmail.com
Mon Nov 2 03:10:53 CET 2009


> \RequirePackage{fourier}
> \RequirePackage[scaled=0.85]{berasans}
> \RequirePackage[scaled=0.85]{beramono}

> Herb Schulz
> (herbs at wideopenwest dot com)

Very nice combination.

I tried it with xelatex/bidi (font in Hebrew) and I like it. The
problem is that after typing in Hebrew, and changing back to English I
don't get the berasans, but something else (Ezra Sil English
perhaps?). See below

How do I set the main font to always be berasans/beramono/fourier.

===============
% !TEX TS-program = xelatex
\documentclass[10pt]{article} % use larger type; default would be 10pt

\usepackage{fourier}
\usepackage[scaled=0.85]{berasans}
\usepackage[scaled=0.85]{beramono}

\usepackage{bidi}
\usepackage{fontspec}
\usepackage{xltxtra}
\usepackage{hebcal,url}
\usepackage{xunicode}
\newfontfamily\ezra[Script=Hebrew]{Ezra SIL}
\def\h{\beginR\setRL\ezra}
\def\e{\beginL\setLR}

\begin{document}


\section{First section}
\section{What is bidi?}
Bi-directional text is text containing text in both text
directionalities, both right-to-left (RTL) and left-to-right (LTR). It
generally involves text containing different types of alphabets, but
may also refer to boustrophedon, which is changing text directionality
in each row.
$x = \beta \rightarrow \alpha$


\h
אבגדהו אבגדהואבגדהואבגדהואבגדהו אבגדהו אבגדהו אבגדהו אבגדהו אבגדה

\e
Bi-directional text is text containing text in both text
directionalities, both right-to-left (RTL) and left-to-right (LTR). It
generally involves text containing different types of alphabets, but
may also refer to boustrophedon, which is changing text directionality
in each row.
$x = \beta \rightarrow \alpha$

\subsection{A subsection}

More text.

\end{document}


More information about the XeTeX mailing list