XeTeX (
or ; see also
Pronouncing and writing "TeX") is a
TeX
Tex, TeX, TEX, may refer to:
People and fictional characters
* Tex (nickname), a list of people and fictional characters with the nickname
* Tex Earnhardt (1930–2020), U.S. businessman
* Joe Tex (1933–1982), stage name of American soul singer ...
typesetting engine using
Unicode
Unicode or ''The Unicode Standard'' or TUS is a character encoding standard maintained by the Unicode Consortium designed to support the use of text in all of the world's writing systems that can be digitized. Version 16.0 defines 154,998 Char ...
and supporting modern font technologies such as
OpenType
OpenType is a format for scalable computer fonts. Derived from TrueType, it retains TrueType's basic structure but adds many intricate data structures for describing typographic behavior. OpenType is a registered trademark of Microsoft Corpora ...
,
Graphite
Graphite () is a Crystallinity, crystalline allotrope (form) of the element carbon. It consists of many stacked Layered materials, layers of graphene, typically in excess of hundreds of layers. Graphite occurs naturally and is the most stable ...
and
Apple Advanced Typography
Apple Advanced Typography (AAT) is Apple Inc.'s computer technology for advanced font rendering, supporting internationalization and complex features for typographers, a successor to Apple's little-used QuickDraw GX font technology of the mid ...
(AAT). It was originally written by Jonathan Kew and is distributed under the
X11 free software license.
The last change to the source code was made on January 20, 2020, and there has been no further development since then. Usage of XeLaTeX is now discouraged.
[Engine news from the LaTeX Project](_blank)
/ref>
Initially developed for Mac OS X
macOS, previously OS X and originally Mac OS X, is a Unix, Unix-based operating system developed and marketed by Apple Inc., Apple since 2001. It is the current operating system for Apple's Mac (computer), Mac computers. With ...
only, it is now available for all major platforms. It natively supports Unicode and the input file is assumed to be in UTF-8
UTF-8 is a character encoding standard used for electronic communication. Defined by the Unicode Standard, the name is derived from ''Unicode Transformation Format 8-bit''. Almost every webpage is transmitted as UTF-8.
UTF-8 supports all 1,112,0 ...
encoding by default. XeTeX can use any fonts installed in the operating system without configuring TeX font metric
Tex, TeX, TEX, may refer to:
People and fictional characters
* Tex (nickname), a list of people and fictional characters with the nickname
* Tex Earnhardt (1930–2020), U.S. businessman
* Joe Tex (1933–1982), stage name of American soul sing ...
s, and can make direct use of advanced typographic features of OpenType
OpenType is a format for scalable computer fonts. Derived from TrueType, it retains TrueType's basic structure but adds many intricate data structures for describing typographic behavior. OpenType is a registered trademark of Microsoft Corpora ...
, AAT and Graphite
Graphite () is a Crystallinity, crystalline allotrope (form) of the element carbon. It consists of many stacked Layered materials, layers of graphene, typically in excess of hundreds of layers. Graphite occurs naturally and is the most stable ...
technologies such as alternative glyph
A glyph ( ) is any kind of purposeful mark. In typography, a glyph is "the specific shape, design, or representation of a character". It is a particular graphical representation, in a particular typeface, of an element of written language. A ...
s and swashes, optional or historic ligatures, and variable font weights. Support for OpenType local typographic conventions (locl
tag) is also present. XeTeX even allows raw OpenType feature tags to be passed to the font. Microtypography is also supported. XeTeX also supports typesetting mathematics using Unicode fonts that contain special mathematical features, such as Cambria Math or Asana Math as an alternative to the traditional mathematical typesetting based on TeX font metrics.
Mode of operation
XeTeX processes input in two stages. In the first stage XeTeX outputs an extended DVI (xdv
) file, which is then converted to PDF
Portable document format (PDF), standardized as ISO 32000, is a file format developed by Adobe Inc., Adobe in 1992 to present documents, including text formatting and images, in a manner independent of application software, computer hardware, ...
by a driver. In the default operating mode the xdv
output is piped directly to the driver without producing any user-visible intermediate files. It is possible to run just the first stage of XeTeX and save the xdv
, although there are no viewers capable of displaying the intermediate format.
Two backend drivers are available to generate PDF from an xdv
file:
* xdv2pdf, which uses ATSUI and QuickTime
QuickTime (or QuickTime Player) is an extensible multimedia architecture created by Apple, which supports playing, streaming, encoding, and transcoding a variety of digital media formats. The term ''QuickTime'' also refers to the QuickTime Pla ...
frameworks, and only works on Mac OS X
macOS, previously OS X and originally Mac OS X, is a Unix, Unix-based operating system developed and marketed by Apple Inc., Apple since 2001. It is the current operating system for Apple's Mac (computer), Mac computers. With ...
.
* xdvipdfmx, a modified version of dvipdfmx, which uses FreeType. This driver works on all platforms.
Starting from version 0.997, the default driver is xdvipdfmx on all platforms. As of version 0.9999, xdv2pdf is no longer supported and its development has been discontinued.
XeTeX works well with both LaTeX
Latex is an emulsion (stable dispersion) of polymer microparticles in water. Latices are found in nature, but synthetic latices are common as well.
In nature, latex is found as a wikt:milky, milky fluid, which is present in 10% of all floweri ...
and ConTeXt
In semiotics, linguistics, sociology and anthropology, context refers to those objects or entities which surround a ''focal event'', in these disciplines typically a communicative event, of some kind. Context is "a frame that surrounds the event ...
macro packages. Its LaTeX counterpart is invoked as xelatex
. It is usually used with the fontspec
package, which provides a configurable interface for font selection, and allows complex font choices to be named and later reused.
XeTeX is bundled with TeX Live
TeX Live is a cross-platform, free software, free software distribution for the TeX typesetting system that includes major TeX-related programs, macro packages, and fonts. It is the replacement of its no-longer supported counterpart teTeX.
It is ...
, MacTeX, MiKTeX and Lyx
LyX (styled as LYX; pronounced ) is an open-source software, open source, graphical user interface document processor based on the LaTeX typesetting system. Unlike most word processors, which follow the WYSIWYG ("what you see is what you get") ...
(see the History
History is the systematic study of the past, focusing primarily on the Human history, human past. As an academic discipline, it analyses and interprets evidence to construct narratives about what happened and explain why it happened. Some t ...
below for dates and versions).
Example
The following is an example of XeLaTeX source and rendered output. The typeface used is OFL-licensed font Linux Libertine
Linux Libertine is a typeface released in 2003 by the Libertine Open Fonts Project, which aims to create FOSS, free and open alternatives to Proprietary software, proprietary typefaces such as Times New Roman. It was developed with the free font e ...
. The text is to be processed by the command xelatex
.
\documentclass 1pt\usepackage
\setmainfont igatures=TeX\begin
\section
\subsection
All human beings are born free and equal in dignity and rights.
\subsection
Hver maður er borinn frjáls og jafn öðrum að virðingu og réttindum.
\subsection
Все люди рождаются свободными и равными в своем достоинстве и
правах.
\subsection
Tất cả mọi người sinh ra đều được tự do và bình đẳng về nhân phẩm và
quyền lợi.
\subsection
Ὅλοι οἱ ἄνθρωποι γεννιοῦνται ἐλεύθεροι καὶ ἴσοι στὴν ἀξιοπρέπεια
καὶ τὰ δικαιώματα.
\section
When he goes---``Hello World!''\\
She replies---“Hello dear!”
\section
\fontspec igatures=Questo è strano assai!
\section
\fontspec umbers=ld style: 1234567\\
\fontspec umbers=ining: 1234567
\end
Arabic support
XeTeX also supports right-to-left
A writing system comprises a set of symbols, called a ''script'', as well as the rules by which the script represents a particular language. The earliest writing appeared during the late 4th millennium BC. Throughout history, each independen ...
scripts, such as Arabic
Arabic (, , or , ) is a Central Semitic languages, Central Semitic language of the Afroasiatic languages, Afroasiatic language family spoken primarily in the Arab world. The International Organization for Standardization (ISO) assigns lang ...
. One way of rendering Arabic in XeTeX is to use the package arabxetex. In order to do so, the Arabic is placed inside the following:
\begin tf.
.
.
\end
The following code illustrates this:
\documentclass 2pt,fleqn,titlepage,twoside,a4paper\usepackage
\usepackage
\usepackage
\usepackage entering,includeheadfoot,margin=1in\usepackage
\usepackage
%\newfontfamily cript=Arabic,Scale=1.5
\parindent = 0pt
\begin
\begin tf\chapter*
\section*
أديـن بدين الحـــب أنـى تــوجـهت ركـائبه \qquad فالحـــب دينــي و إيماني\\
لنا أسوة في بشر هند و اختها و قيس و ليلى \qquad ثـــــم مـــــي و غـــيــــلان
\end
\end
Features
In bibliographic files (see below the BibTeX example) you can use Unicode entities and call them with their native scripting, for example \cite, instead of a transliterated ASCII form like \cite which is mandatory using the pdfTeX engine.
% Encoding: UTF8
@ARTICLE(Ekstrom,
AUTHOR = "Author w",
TITLE = "",
JOURNAL = "Ekstrm Journal",
YEAR = 1965,
note =
)
@ARTICLE(Ekstrøm,
AUTHOR = "Author Ekstrm",
TITLE = "",
JOURNAL = "Ekstrøm Journal",
YEAR = "1965",
note =
)
History
XeTeX was initially released for Mac OS X
macOS, previously OS X and originally Mac OS X, is a Unix, Unix-based operating system developed and marketed by Apple Inc., Apple since 2001. It is the current operating system for Apple's Mac (computer), Mac computers. With ...
only in April 2004 with built-in AAT and Unicode
Unicode or ''The Unicode Standard'' or TUS is a character encoding standard maintained by the Unicode Consortium designed to support the use of text in all of the world's writing systems that can be digitized. Version 16.0 defines 154,998 Char ...
support. In 2005 support for OpenType layout features was first introduced. During BachoTeX 2006 a version for Linux
Linux ( ) is a family of open source Unix-like operating systems based on the Linux kernel, an kernel (operating system), operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically package manager, pac ...
was announced, which was ported to Microsoft Windows
Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
by Akira Kakuto a few months later, and finally included into TeX Live
TeX Live is a cross-platform, free software, free software distribution for the TeX typesetting system that includes major TeX-related programs, macro packages, and fonts. It is the replacement of its no-longer supported counterpart teTeX.
It is ...
2007 for all major platforms. XeTeX is also supported by LyX
LyX (styled as LYX; pronounced ) is an open-source software, open source, graphical user interface document processor based on the LaTeX typesetting system. Unlike most word processors, which follow the WYSIWYG ("what you see is what you get") ...
since version 2.0 and shipped with MiKTeX since version 2.7.
As of the inclusion in TeX Live
TeX Live is a cross-platform, free software, free software distribution for the TeX typesetting system that includes major TeX-related programs, macro packages, and fonts. It is the replacement of its no-longer supported counterpart teTeX.
It is ...
, XeTeX supports most macro packages written for LaTeX
Latex is an emulsion (stable dispersion) of polymer microparticles in water. Latices are found in nature, but synthetic latices are common as well.
In nature, latex is found as a wikt:milky, milky fluid, which is present in 10% of all floweri ...
, OpenType
OpenType is a format for scalable computer fonts. Derived from TrueType, it retains TrueType's basic structure but adds many intricate data structures for describing typographic behavior. OpenType is a registered trademark of Microsoft Corpora ...
, TrueType
TrueType is an Computer font#Outline fonts, outline font standardization, standard developed by Apple Inc., Apple in the late 1980s as a competitor to Adobe Inc., Adobe's PostScript fonts#Type 1, Type 1 fonts used in PostScript. It has become the ...
and PostScript
PostScript (PS) is a page description language and dynamically typed, stack-based programming language. It is most commonly used in the electronic publishing and desktop publishing realm, but as a Turing complete programming language, it c ...
fonts without any specific setup procedure.
Version 0.998 announced at BachoTeX 2008 supports Unicode normalization
Unicode equivalence is the specification by the Unicode character (computing), character encoding standard that some sequences of code points represent essentially the same character. This feature was introduced in the standard to allow compatibi ...
via the \XeTeXinputnormalization
command.
Version 0.9999, released in May 2013, switched from ICU Layout Engine to HarfBuzz
HarfBuzz (loose transliteration of Persian language, Persian calque ''harf-bāz'', literally "open type") is a software library for supporting text shaping, which is the process of converting Unicode text to glyph indices and positions. The ne ...
for OpenType
OpenType is a format for scalable computer fonts. Derived from TrueType, it retains TrueType's basic structure but adds many intricate data structures for describing typographic behavior. OpenType is a registered trademark of Microsoft Corpora ...
layout, and Graphite2 engine for Graphite
Graphite () is a Crystallinity, crystalline allotrope (form) of the element carbon. It consists of many stacked Layered materials, layers of graphene, typically in excess of hundreds of layers. Graphite occurs naturally and is the most stable ...
layout, as well Core Text framework instead of ATSUI on Mac OS X.
See also
* LuaTeX
LuaTeX is a TeX-based computer typesetting system which started as a version of pdfTeX with a Lua (programming language), Lua scripting engine embedded. After some experiments it was adopted by the TeX Live distribution as a successor to pdfTeX (i ...
* Omega (TeX)
* Typeface
A typeface (or font family) is a design of Letter (alphabet), letters, Numerical digit, numbers and other symbols, to be used in printing or for electronic display. Most typefaces include variations in size (e.g., 24 point), weight (e.g., light, ...
* TeXworks
TeXworks is free and open-source application software, available for Microsoft Windows, Windows, Linux and macOS. It is a Qt (software), Qt-based graphical user interface to the TeX typesetting system and its LaTeX, ConTeXt, and XeTeX extensions. ...
– A multi-platform, Unicode editor designed for working with TeX files, written by the author of XeTeX.
* List of TeX extensions
References
Further reading
* M. Goossens (Ed.) (2008
The XeTeX Companion: TeX meets OpenType and Unicode
External links
*
The Beauty of LaTeX
illustrates XeTeX use with professional fonts.
XeTeX Showcase at TUG
{{DEFAULTSORT:Xetex
2007 software
Digital typography
Free PDF software
Free TeX software
Linux TeX software
Software using the MIT license
TeX
Unicode