| November 25, 2009 12:02 am

Very few documents are more personal than a curriculum vitae (CV).  A CV lists a person’s educational history, who they’ve worked for and what they’ve accomplished.  Moreover, a CV is frequently used to judge a person’s inherent worth and value (or at least exploitability).  A quality curiculum vitae matters, a lot.

For that reason, a CV not only needs to include all the pertinent information of a person’s life, but it also needs to look good. An attractive CV with good spacing and contrast leaves a positive impression and makes it easier to find information.  When laid out correctly, a reviewer might just find themselves scouring past accomplishments for interesting tidbits: “I didn’t realize that this applicant organized a lecture series with Patch Adams and other notables, that’s interesting!”

There are many dedicated CV classes which can be used to typeset a CV with LaTeX.  Unfortunately, they all share one thing in common: they’re complicated.  To ensure that the spacing and fonts are correct, far too often a document based on these classes will devolve into a jumbled mess of tags and obscure page layout commands.

I’ve tried to typeset my CV with LaTeX a number of times, and in nearly every case, I’ve been unhappy with the output.  Sure, the end product is attractive enough; but it doesn’t quite match the CV that I have in my head.  To really arrive at my coveted ideal of perfection, I would need to manually specify the font and position of nearly every element on the page; which is why I’ve normally used a dedicated layout program (such as Adobe InDesign) for the job.

This is unfortunate, however, since a CV based on LaTeX would be much easier to keep current.  Additionally, a well designed document class and corresponding BibTeX style would allow me to use my existing bibliographic database to automate the process.

Thus, any time that I need to make major updates, I always check the internet for information and new LaTeX classes.  While conducting one such review a few days ago, I came across a very interesting article and set of examples by Dario Taraborelli of the University of Surrey.  In his write-up, Dr. Taraborelli expresses frustrations which are similar to my own;  but instead of complaining and throwing his hands up in exasperation, he went on to solve the problems in an elegant way.

Rather than use or modify one of the existing CV classes (as I would have done), Taraborelli opted to extend the article class by adding additional features.  Perhaps the most important addition was the use of XeTeX and the \fontspec package, which allows for OpenType or expert fonts to be used and other advanced features.  The end result of this work is an attractive and flexible document template.

Dr. Taraborelli’s example also shows how easy it can be to extend an existing document class to meet a more specific need.  As I read through the example code, I realized that it would be straightforward to build upon his work and create something that would suit my particular aesthetic.

So … I did, and this series is the result of my efforts.

In the remainder of this article, I will introduce the new CV document class I created (called xetexCV) and provide a few examples of how to work with it.  In part 2, I will dissect the class code and explain how it works.  I will also provide hints on how it might be modified.  In part 3, I will show how to generate a publications list through the use of a .bib database and custom BibTeX style.  In Part 4, I will describe how the document class and corresponding layout file can be used with LyX.


xetexCV – An Attractive and Easy to Use CV Document Class

Downloads and Installation

All of the files needed to use the class (including xetexCV.cls, examples and supporting files) can be found here.  To install, copy to an appropriate folder in your tex path and refresh the tex database:

sudo texhash

Package Requirements

  • XeTeX Typesetting Engine.  For users of Mac OS X and Windows, XeTeX is included in the MacTeX and MikTeX distributions (respectively).  Users of Linux, however, will need to install the texlive-xetex package
  • Fontspec package (included with MacTeX, MikTeX or texlive-xetex)
  • OpenType Expert Fonts.  By default, the document class uses Fontin and Fontin sans.

Curiculum Vitae Examples

xetexCV Class Usage

To use the xetexCV class, there are a few important macros.  These include:

  • The \makecvtitle macro and title block tags
  • The \cvsection and \cvsubsection macros
  • The \years tag for hanging notes


The title block is created through the use of the \makecvtitle macro.  The name, institution and contact information are all specified by descriptive tags.  The example below shows what these are and how they are used:


\cvname{Albert Einstein}
\institution{Institute for Advanced Study}

\contactaddress{Einstein Drive\\
Princeton, New Jersey 08450
United States of America}

\phone number{609-734-8000}


\cvsection and \cvsubsection

Sections and subsections can be added through the \cvsection{section name} and \cvsubsection{subsection name} macros.  The following codeblock creates the “Publications” section header and “Peer Reviewed Journals” subhead seen at right:

\cvsubsection{Journal Articles}

Hanging Notes

Hanging notes can be specified through the use of the \years macro.  This is helpful for typesetting education, employment history, and awards.  The following example produces the output seen below:

\cvsection{Appointments Held}

University of Bern \years{1908-1911}\\
University of Zurich \years{1911-1912}\\
Charles University of Prague \years{1912-1914}\\
Prussian Academy of Sciences, Berlin \years{1914-1932}\\
University of Leiden \years{1920-1930}\\
Institute for Advanced Study, Princeton \years{1932-1955}


Choosing a Font

To change the font, use the \fontspec package and appropriate \settext macro.  The example below shows how to change the main font and sans font to Warnock Pro and Frutiger LT Std (commercial fonts available as part of the Adobe Font Folio 11):

\setmainfont[Ligatures={Common}, Numbers={OldStyle}]{Warnock Pro}
\setsansfont{Frutiger LT Std}

All of the examples shown here were typeset with Warner Pro and Frutiger.  By default, however, the document class uses Fontin and Fontin sans, which are available as free downloads.  Another excellent font alternative is Gentium Basic.  Because XeTeX can use OpenType fonts, however, you can use any font installed on your computer.

Other Features

  • Font features such as ligatures and glyph variants can be accessed through the fontspec package
  • The examples and class are unicode compatible.  This means means that you can write in Chinese, Cyrillic or Greek without additional packages


Acknowledgements and Further Reading

As noted above, this document class is based on a similar example available from Dario Taraborelli’s website.  Other examples of how to create a resume or CV are available from Matthew Boedicker and Kamil Wójcicki.


7 Responses to “Typeset Your Curriculum Vitae – Part 1: The xetexCV Document Class”

[…] Art and Photography « Typeset Your Curiculum Vitae – Part 1: The xetexCV Document Class […]

Youssef wrote a comment on December 3, 2009

Thanks for your class. I’ve previously used Dario’s class, but it’s harder to use and the \years command set as \marginpar is rather small.
Your commands are easier and the overall appearance looks cleaner and nicer.
Nice work.

Teri wrote a comment on February 7, 2010

I found your blog through my search for ways to customize LyX documents. I really like your website, and your work! I
I was wondering if the promised “Part 4” on “how the document class and corresponding layout file can be used with LyX” will be posted any time soon?
Thanks for your great posts!

[…] is not something that I would like to see happen with my custom Curriculum Vitae document class, xetexCV.  I spent a great deal of time developing and debugging the document class […]

[…] Typeset Your Curriculum Vitae by Rob Oakes […]

MA wrote a comment on May 30, 2012

I like almost all typeset features of the CV PDF examples you have shown. Except that sometimes I prefer not to leave lot of empty space on the left side. For example, if I use a different citation style in which year is included at the end of the citation (e.g. IEEE style) then entire left column is empty and wasted.
Is this a flexible choice available in your class? Can I choose how I want text to be indented?

Care to comment?