[XeTeX] Font change

Theodore M Rolle, Jr. stercor at gmail.com
Tue Dec 25 05:36:21 CET 2012


Um...like this?

\documentclass{article}
\usepackage{fontspec}
\begin{document}
\setmainfont{Linux Biolinum}
This is Linux Biolinum.\\
\setmainfont{Linux Biolinum Keyboard}
This is Linux Biolinum Keyboard.
\end{document}

I just tried it with a minimal example.  It worked.

On 12/24/2012 10:11 PM, Sasi Kumar wrote:
> Dear friends,
> 
> As a relatively new user of XeTeX, I have a number of doubts. But right
> now, let me ask you two of them. I would be thankful if someone could point
> out a good tutorial on xelatex.
> 
> My doubts are:
> 1. How can I change the font inside a document? For instance, let me say I
> have a document such as this:
> 
>     The fox and the dog
> The quick brown fox jumped over the lazy dog. The quick brown fox jumped
> over the lazy dog. The quick brown fox jumped over the lazy dog.
> 
> I want "The fox and the dog" in the font, let us say, "FreeSans" and the
> rest of the text in the font "FreeSerif". How do I do that?
> 
> 2. I am creating a document in two languages, let us say, English and
> Malayalam, with both languages appearing intermixed. Now, how do I set the
> fonts for each language? I have a font for Malayalam, but the English text
> does not appear very beautiful in that font, so I would like the English
> text to appear in some other font.
> 
> Thanking for any help that may be forthcoming and wishing everyone a Merry
> Christmas and a Very Happy 2013 and beyond.
> 
> Regards,
> Sasi
> 
> 
> 
> Dear friends,
> 
> As a relatively new user of XeTeX, I have a number of doubts. But right
> now, let me ask you two of them. I would be thankful if someone could
> point out a good tutorial on xelatex.
> 
> My doubts are:
> 1. How can I change the font inside a document? For instance, let me say
> I have a document such as this:
> 
>     The fox and the dog
> The quick brown fox jumped over the lazy dog. The quick brown fox jumped
> over the lazy dog. The quick brown fox jumped over the lazy dog.
> 
> I want "The fox and the dog" in the font, let us say, "FreeSans" and the
> rest of the text in the font "FreeSerif". How do I do that?
> 
> 2. I am creating a document in two languages, let us say, English and
> Malayalam, with both languages appearing intermixed. Now, how do I set
> the fonts for each language? I have a font for Malayalam, but the
> English text does not appear very beautiful in that font, so I would
> like the English text to appear in some other font.
> 
> Thanking for any help that may be forthcoming and wishing everyone a
> Merry Christmas and a Very Happy 2013 and beyond.
> 
> Regards,
> Sasi
> 
> -- 
> V. Sasi Kumar
> Free Software Foundation of India
> Please see: http://swatantryam.blogspot.com/
> 
> 
> 
> 
> --------------------------------------------------
> Subscriptions, Archive, and List information, etc.:
>   http://tug.org/mailman/listinfo/xetex
> 



More information about the XeTeX mailing list