[Tex/LaTex] Ligatures for fi, fl, ffl do not work for Times New Roman (XeLaTeX)

ligaturestimes

When I compile the code below with XeLaTeX (using TeXworks), ligatures for Times New Roman do not show. Instead, I just get singular characters.

\documentclass{article}

\usepackage{fontspec}

\setmainfont[Mapping=tex-text,Ligatures=TeX,Scale=1.05]{Times New Roman}

\begin{document}

Ligatures: fi fl ffl

\end{document}

I have tried Ligatures={Common} and Ligatures={Common, TeX} instead of Ligatures=TeX (found in this answer), but there is no difference. I've checked the font map for Times New Roman (v.6.85) and the Unicode characters FB01 and FB02 are present with the expected ligatures.

However, when I do not specify the font, the above (thus set in Computer Modern) does have ligatures.

It is not terribly important for me to use Times New Roman, but it has IPA characters (which I need for my linguistics thesis), and old style numerals and small caps (which I like).

Is there a way for me to get Times New Roman to show these ligatures?

Best Answer

Prepare a new map file, I called it rijke.map

; TECkit mapping for TeX input conventions <-> Unicode characters

LHSName "TeX-text"
RHSName "UNICODE"

pass(Unicode)

; ligatures from Knuth's original CMR fonts
U+002D U+002D           <>  U+2013  ; -- -> en dash
U+002D U+002D U+002D    <>  U+2014  ; --- -> em dash

U+0027          <>  U+2019  ; ' -> right single quote
U+0027 U+0027   <>  U+201D  ; '' -> right double quote
U+0022           >  U+201D  ; " -> right double quote

U+0060          <>  U+2018  ; ` -> left single quote
U+0060 U+0060   <>  U+201C  ; `` -> left double quote

U+0021 U+0060   <>  U+00A1  ; !` -> inverted exclam
U+003F U+0060   <>  U+00BF  ; ?` -> inverted question

; additions supported in T1 encoding
U+002C U+002C   <>  U+201E  ; ,, -> DOUBLE LOW-9 QUOTATION MARK
U+003C U+003C   <>  U+00AB  ; << -> LEFT POINTING GUILLEMET
U+003E U+003E   <>  U+00BB  ; >> -> RIGHT POINTING GUILLEMET

; additions for f ligatures
;U+0066 U+0066 U+0069 <> U+FB03 ; LATIN SMALL LIGATURE FFI
;U+0066 U+0066 U+006C <> U+FB04 ; LATIN SMALL LIGATURE FFL
;U+0066 U+0066        <> U+FB00 ; LATIN SMALL LIGATURE FF
U+0066 U+0069        <> U+FB01 ; LATIN SMALL LIGATURE FI
U+0066 U+006C        <> U+FB02 ; LATIN SMALL LIGATURE FL

The basis is the standard tex-text.map file found in TeX Live. The “ff” ligatures are commented out, because my copy of Times New Roman doesn't support them.

Now compile it

teckit_compile rijke.map

This will produce a rijke.tec file; if you keep it along your document, the input

\documentclass{article}

\usepackage{fontspec}

\setmainfont[Mapping=rijke,Scale=1.05]{Times New Roman}

\begin{document}

Ligatures: ff ffi ffl fi fl 

\end{document}

will produce

enter image description here