I have long been using the TeX Gyre Pagella font for my documents. However, like many users, when I'm trying to find out how to customize documents by searching StackExchange (or often) googling, there are so many options, packages, old information, bleeding edge information, and alternative compilers I'm not sure if I'm responsibly using the available software.
Ideally I could set up a preamble and use it over and over for my documents. The preamble should:
- Let me use TeX Gyre Pagella
- Enable proper matching math fonts, get ligatures correct
- Play well with unicode
- Packages and compilers are available in TeX Live/MacTeX/TeX Shop
- Highly stable -- no known bugs or conflicts with other popular packages
- Uses packages that are not 'orphaned' i.e. they will continue to be improved but not deprecated in the years to come.
For example: for a long time I had used XeLaTeX but after trying to read around about 'good ways to do things' I read about some combination of using LuaLaTeX and certain packages/preamble lines such as below, that appeared to be more 'preferred'. But I really am not sure what everything here does, and using fonts in TeX has been explicitly called a black hole, so I thought I could open up a question and see what people think.
Here's a (minimal) preamble I am now trying to use with LuaLaTeX:
\documentclass[english]{exam}
\usepackage{babel}
\usepackage{parskip}
\usepackage{fontspec}
\usepackage{fontenc,unicode-math}
\setmainfont[Ligatures=TeX]{TeX Gyre Pagella}
\setmathfont[Ligatures=TeX]{TeX Gyre Pagella Math}
Am I missing or misusing something important? Any further ideas about what would be 'good' to have in a preamble?
fontenc; it may still work, but I don't think it is recommended when you are usingfontspec. I think there's a comment in the manual of the latter about this. – jon Sep 12 '13 at 17:03english. Specify the variant instead e.g.britishoramerican. This is recommended because different versions ofbabelaliasenglishto different variants. – cfr Mar 24 '14 at 01:48