I want to change LaTeX engine from PdfLaTeX to XeLaTeX.
There are a lot of formulas and equations with Russian text inside. And it used without any commands.
MWE for pdflatex:
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[russian]{babel}
\usepackage{mathtext}
\usepackage[T2A]{fontenc}
\begin{document}
Формула: $F_{подпись} = Ф$
Уравнение:
\begin{equation}
X_{первый} = Y_{второй}
\end{equation}
\end{document}
I tried the same example with XeLaTeX. There is no errors, but Russian characters are displayed only with \textup command, like it was said in this answer:Cyrillic symbols in math equation xetex
\documentclass{article}
\usepackage{unicode-math}
\usepackage{polyglossia}
\setdefaultlanguage{russian}
\setmainfont{Liberation Serif}
\setmathfont{Asana Math}
\begin{document}
Формула: $F_{подпись} = Ф$
Уравнение:
\begin{equation}
X_{первый} = Y_{\textup{второй}}
\end{equation}
\end{document}
Are there any ways to do it without \textup?
первыйis a named index, in which case is always should be typeset in the upright text font so it is not confused withп*е*р*в*ы*йor six separate indices. – daleif Dec 19 '18 at 14:19\textup, but displayed with it. – Shalom Alecheim Dec 19 '18 at 15:35