I watch the CTAN Announcement RSS feed as a way of finding out about cool new packages. Recently I saw two announcements; The release of lm-math and tex-gyre-math. I use both Latin Modern (via lmodern or cfr-lm ) and Times (via loading mathptmx followed by tgtermes) quite a lot. Do these new packages contain anything useful for me? Should I be loading my fonts in a different way now? An older question seems to imply that these are for XeLaTeX and LuaTeX, since they are in OTF format, not Type 1. Is there an easy way I can use these updated fonts with PDFLaTeX (Or should I refer to my old question?) If there is, should I worry about trying to use them?
1 Answers
The tex-gyre-math release contains only OpenType fonts:
Description:
TeX-Gyre-Math is to be a collection of maths fonts to match the text fonts of the TeX-Gyre collection. The collection will be made available in OpenType format, only; fonts will conform to the developing standards for OpenType maths fonts. At present, TeX-Gyre-Math-Pagella and TeX-Gyre-Math-Termes are available.
So they are only (directly) usable with XeLaTeX or LuaLatex (and require the package unicode-math). I tried them this morning with the following, and here is what I do to load the fonts (I also load the TeX Gyre Termes font for text):
\documentclass{article}
\usepackage{ifluatex}
\usepackage{unicode-math}
\ifluatex
\setmainfont[Ligatures=TeX]{TeX Gyre Termes}
\setmathfont{TG Termes Math}
\else
% xetex
\setmainfont[ExternalLocation,
Mapping=tex-text,
BoldFont=texgyretermes-bold,
ItalicFont=texgyretermes-italic,
BoldItalicFont=texgyretermes-bolditalic]{texgyretermes-regular}
\setmathfont[ExternalLocation]{texgyretermes-math}
\fi
\begin{document}
$\cos(x)=\sin(x)$
\end{document}
Perhaps there is a simpler way to let XeTeX find the fonts.
Note that there are no bold versions of the math fonts (as far as I can tell).
-
So new fonts....designed for academic use (who else needs that many math symbols?)...that you can't publish as journals demand pdftex. sigh – Canageek Oct 27 '12 at 22:12
-
@Canageek Journals either use TeX + CM or Times, or non-TeX solutions, for which TeX-only fonts don't help anyway :-) Think time-scale: these fonts will be around a long time, and there is a lot of interest in math typesetting beyond the TeX world. – Joseph Wright Oct 27 '12 at 22:18
-
@jfbu There is no concept of a bold version of a math font - bold is used to alter meaning, so is quite intentionally available on a per-symbol basis only. (See also question about sanserif math fonts.) – Joseph Wright Oct 27 '12 at 22:20
-
@JosephWright: Bold math fonts can be of use in all bold situation e.g. in titles or theorems (last year I had a math book typeset with metal type in Russia where all theorems were set in bold including math), XITS and Lucida Math has bold fonts for that reason. – خالد حسني Oct 27 '12 at 22:45
-
If you install the fonts system wide, you can load them by font name. I hope at some point to make XeTeX able to load fonts installed in TeX tree by font name too, LuaLaTeX already do. – خالد حسني Oct 27 '12 at 22:47
-
@Canageek: OpenType is the way forward, we already have two TeX engines that support OpenType math, MS Word, Mozilla has some interest in supporting it, and if IE ever supports MathML it will almost certainly use OpenType math. On the other hand building TeX TFM-based math fonts is PITA, and I did build fonts both ways, and only TeX can use them. – خالد حسني Oct 27 '12 at 22:51
-
@KhaledHosny I'm more annoyed I can't use it now, as I like Microtype, and don't want to come to rely on features I can't use later. Also, one of my favourite things about TeXLive is that I never have to worry about if someone else has the same fonts. If TeXLive will load the package, everyone else has that font. Putting it as a system thing means that we go back to Word's problem of 'you don't have that font, go download it' – Canageek Oct 27 '12 at 23:32
-
@JosephWright Wait, so body text is set in Times, then they use CM for the math? Isn't that, you know, horribly ugly? Also, you are assuming that in 10 or 15 years MS or Apple doesn't release a new font format that makes everyone abandon OpenType. – Canageek Oct 27 '12 at 23:33
-
@Canageek: may be they will (it is not a very well written standard after all), but the industry have much invested in OpenType that I really doubt they can go away with such a thing (look how they amended TrueType instead of replacing it completely, even Type1 got a new life as
CFFtable.). – خالد حسني Oct 28 '12 at 02:31 -
@KhaledHosny I wish I could point to MP3 or GIF to prove you wrong, but you do have a good point. – Canageek Oct 28 '12 at 02:36
-
@Canageek When you use for example
mathptmx, most of the glyphs in math mode are Times-like, but 'gaps' are filled in from CM. One of the reasons there are a variety of deprecated font packages (e.g.times) is that people have worked hard to get as many glyphs as possible from the correct fonts. However, to do the job properly needs glyphs drawing: for Times-like fonts, there is for example the commercial Math Time Pro set. – Joseph Wright Oct 28 '12 at 08:25 -
On the future of font formats, as @KhaledHosny says OpenType may not last for ever. However, any change would almost certainly have a 'migration path' as lots of people have invested in maths fonts. On the other hand, if you produce a new TeX format math mode font then it's in the 'TeX ghetto', whether we like it or not, and the world is moving to some form of standard for maths fonts. – Joseph Wright Oct 28 '12 at 08:27
-
@JosephWright Ah, ok, that makes sense. So now I just have to hope that either PDFLaTeX gets OTF support, or LuaTeX gets Microtype support. Also; hope that they don't rely on system fonts, for the reasons I outlined above. – Canageek Oct 28 '12 at 15:05
-
pdflatex. – egreg Oct 27 '12 at 22:04