%&program=xelatex
%&encoding=UTF-8 Unicode

%%%% Begin file %%%%

\documentclass[12pt,a4paper]{article}

%%% NOTE that the osxfonts.sty package used here is a quick-and-dirty hack
%%% and should be replaced by Will Robertson's far more extensive "fontspec" package
%%% (see http://scripts.sil.org/xetex_related)

\usepackage{fontspec}

\renewcommand{\encodingdefault}{U}

%\NewOSXFontFamily{hoefler}{Hoefler Text}  \renewcommand{\rmdefault}{hoefler}

% some other possibilities (you'll get warning about the missing small-caps shape with these)
%\NewOSXFontFamily{palatino}{Palatino}  \renewcommand{\rmdefault}{palatino}
%\NewOSXFontFamily{timesroman}{Times Roman}  \renewcommand{\rmdefault}{timesroman}

% these are also lacking an italic shape
%\NewOSXFontFamily{lucidagrande}{Lucida Grande}  \renewcommand{\rmdefault}{lucidagrande}
%\NewOSXFontFamily{helv}{Helvetica}  \renewcommand{\rmdefault}{helv}

% these require Adobe Pro fonts...
%\NewOSXFontFamily{agaramond}{Adobe Garamond Pro} \renewcommand{\rmdefault}{agaramond}
%\NewOSXFontFamily{acaslon}{Adobe Caslon Pro}  \renewcommand{\rmdefault}{acaslon}

% note that to access all the weights of Minion and Brioso Pro, additional declarations would be needed
%\NewOSXFontFamily{minion}{Minion Pro}  \renewcommand{\rmdefault}{minion}
%\NewOSXFontFamily{brioso}{Brioso Pro}  \renewcommand{\rmdefault}{brioso}

\begin{document}

Normal text—in Üñıćō∂ė, of course.

\textbf{Bold text}.

\textit{Italic text}.

\textbf{\textit{Bold italic text}}.

\textsc{Small caps text \textbf{including bold}}.

% a couple of extra experiments....
% test for the use of font mappings:
\bigskip
\font\x="Times Roman:mapping=tex-text" at 12pt \x
Normal text---in ``Üñıćō∂ė,'' of course. % note dash and quotes!

% try a transliteration mapping:
\begin{centering}
\def\txt{Unicode - это уникальный код для любого символа,\\
    независимо от платформы,\\
    независимо от программы,\\
    независимо от языка.\par}
\font\x="Lucida Grande" at 12pt \x
\bigskip \txt

\font\x="Lucida Grande:mapping=cyr-lat-iso9" at 12pt \x
\bigskip \txt
\end{centering}

\end{document}

%%%% End file %%%%
