# How to force a long-tailed Q in EB Garamond

I'm using XeLaTeX and EB Garamond to produce a facsimile of a 17th-century French pamphlet. EB Garamond, at least with its default settings, seems to select the long-tailed Q only when the Q is followed by at least three more characters:

\documentclass{article}
\usepackage{fontspec}
\defaultfontfeatures{Ligatures=TeX}
\setmainfont{EB Garamond}
\begin{document}
\noindent
Qu'il viue\\
Qui soubmettant\\
Quiconque vienne
\end{document}


However, in the original pamphlet the long-tailed Q is used even for shorter words such as "Qui". How can I get my document to use the long-tailed Q for the word "Qui"?

• – Thérèse Nov 2 '14 at 16:48
• @Thérèse I tried and it doesn't work (XeLaTeX and LuaLaTeX). – egreg Nov 2 '14 at 16:54
• @egreg -- might adding an empty box help? – barbara beeton Nov 2 '14 at 16:56
• @barbarabeeton No, my impression is that the tail is used only if it ends short of the word. In the case of Qaa adding \mbox{} works, not with Qui\mbox{} – egreg Nov 2 '14 at 17:01
• In luatex you can even write a feature file with sub \Q by \Q.long; so that you don’t need to remember to use the \fontchar{} macro every time Q appears. – Thérèse Nov 2 '14 at 17:05

With XeTeX you can force the glyph with \XeTeXglyph:

\documentclass{article}
\usepackage{fontspec}
\defaultfontfeatures{Ligatures=TeX}
\setmainfont[Contextuals=Alternate,Ligatures=Rare]{EB Garamond}
\newcommand\Qlong{\XeTeXglyph\the\XeTeXglyphindex "Q.long" \relax}
\begin{document}
\noindent
\Qlong ui blablab

\end{document}


• Contextuals=Alternate is the default for EB Garamond, according to the documentation. – Bernard Nov 2 '14 at 18:27