# Showing English numbers with XePersian and Minted

This is my code:

\documentclass{article}
\usepackage{xcolor}

\usepackage{minted}
\usemintedstyle{colorful}

\usepackage{xepersian}
\settextfont{B Nazanin}

\definecolor{mintedbackground}{rgb}{0.95,0.95,0.95}

\newmintedfile[pythoncode]{python}{
fontfamily=tt,
bgcolor=mintedbackground,
linenos=true,
numberblanklines=true,
numbersep=5pt,
gobble=0,
frame=leftline,
framerule=0.4pt,
framesep=2mm,
funcnamehighlighting=true,
tabsize=4,
obeytabs=false,
mathescape=false,
samepage=false, %with this setting you can force the list to appear on the same page
showspaces=false,
showtabs =false,
texcl=false,
breaklines=true
}

\begin{document}

\begin{latin}
\pythoncode{P.py}
222
\end{latin}
\end{document}


The numbers on the left of the Python code are in Persian. How can I change them to be in English? (But the 222 is in English)

A also have tried moving \newmintedfile[pythoncode]{pthon} into latin environment which did not fix the problem.

• By "English" numerals, would you be referring to arabic numerals, i.e., 0, 1, 2, 3, ...? Please advise. – Mico Jun 27 '17 at 19:47

\renewcommand{\theFancyVerbLine}{\lr{\upshape\tiny\arabic{FancyVerbLine}}}