15

LuaLaTeX renders Turkish small cap dotted 'i' correctly in the main body of the text, but not in footnotes. Are there any solutions?

Here is a MWE:

%!TEX program = lualatex
\documentclass[11pt]{memoir}

\usepackage{fontspec}
\usepackage{polyglossia}
\setdefaultlanguage{turkish}
\usepackage[semibold]{libertine}


\begin{document}
    In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.\footnote{In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.}
\end{document}
  • 2
    good question, it works with \footnotesize text in the main body so it's the footnote command not the font that is the problem, xelatex fails the same way though – David Carlisle Mar 7 '18 at 18:54
  • 3
    \footnote triggers \ignorespaces. If you put \ignorespaces in the normal text, it loses the dot too. But if you remove the \ignorespaces from \footnote it doesnt wotk :( – Phelype Oleinik Mar 7 '18 at 19:01
11

Load the font with the Language=Turkish option:

\documentclass[11pt]{memoir}

\usepackage{fontspec}
\usepackage{polyglossia}
\setdefaultlanguage{turkish}
\setmainfont{Linux Libertine O}[
  Language=Turkish,
  BoldFont=* Semibold,
  BoldItalicFont=* Semibold Italic,
]

\setlength{\textheight}{2cm}

\begin{document}

In Turkish,  `\textsc{ı}' and `\textsc{i}' are different
letters.\footnote{In Turkish,  `\textsc{ı}' and `\textsc{i}'
are different letters.}

\textbf{Abc} \textbf{\textit{Abc}}

\end{document}

enter image description here

9

I don't think it should be be needed but you can re-assert turkish in the footnote:

\documentclass[11pt]{memoir}

\usepackage{fontspec}
\usepackage{polyglossia}
\setdefaultlanguage{turkish}
\usepackage[semibold]{libertine}


\begin{document}

 In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.

{\footnotesize In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.}


x\footnote{\textturkish{In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.}}


\end{document}

I think the root cause is \normalfont

\documentclass[11pt]{memoir}

\usepackage{fontspec}
\usepackage{polyglossia}
\setdefaultlanguage{turkish}
\usepackage[semibold]{libertine}


\begin{document}

 In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.

{\footnotesize In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.}


{\normalfont\footnotesize In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.}


x\footnote{In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.}

x\footnote{\textturkish{In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.}}


\end{document}

\normalfont (which is used to reset the font in footnotes, headings and other places) ends up selecting LinLibertine(0) whereas for Turkish it should be LinLibertine(9) I'm not sure if that's the responsibility of fontspec or polyglossia but I'll ask...

5

babel has a new interface to setup language dependant fonts. It seems to handle this correctly:

\documentclass[11pt]{memoir}

\usepackage[english,turkish]{babel}
\babelfont[english]{rm}[Language=Default]{Linux Libertine O}
\babelfont[turkish]{rm}[Language=Turkish]{Linux Libertine O}


\begin{document}
    In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.%
    \footnote{In Turkish,  `\textsc{ı}' and `\textsc{i}' are different letters.}

    \selectlanguage{english}
    In english,  `\textsc{ı}' and `\textsc{i}' %
    \footnote{In english,  `\textsc{ı}' and `\textsc{i}'}


\end{document}

enter image description here

But you won't be able to use the libertine package. The babel document says explicitly that you must setup the fonts with \babelfont and not \setXXfont.

  • 1
    And even simpler: \babelfont{rm}{Linux Libertine O}. That's all — babeldefines and switches the fonts for you (which is the main point of \babelfont). – Javier Bezos Apr 10 '18 at 13:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.