[Tex/LaTex] Cyrillic monospaced font

cyrillicfontstypewriterwarnings

I need to use Cyrillic (russian) monospaced font.

I chose courier and added

\usepackage[T1]{fontenc}

and

{\fontfamily{pcr}\selectfont 
 blabla
}

and that "blabla" is displayed like usual text and there is warning:

LaTeX Font Warning: Font shape `T2A/pcr/m/n' undefined using `T2A/cmr/m/n' instead on input line 245.

How to fix this?
At the end I would like to have cyrillic monospaced font with possibility to write bold or underlined words.

Update

here's minimal non-working example:

\documentclass[a4paper,11pt]{article}
\usepackage[cp1251]{inputenc}
\usepackage[russian]{babel}
\usepackage[T1]{fontenc}

\begin{document}
usual text

русский текст

{\fontfamily{pcr}\selectfont 
curier?

курьер?
}

\end{document}

Best Answer

There's no cyrillic support for pcr family in TeX distributions. If you want to use Courier fonts in LaTeX, you may use some commercial fonts via XeLaTeX. For example, to use Courier New on Windows, you can use:

% UTF-8 encoding
% Use xelatex / lualatex to compile this
\documentclass{article}

\usepackage{fontspec}
\setmonofont{Courier New}

\begin{document}

\texttt{русский язык}

\end{document}

result


If you just want to use a monospaced font in LaTeX, you can use default font families. Then pdfLaTeX is sufficient.

% UTF-8 encoding
% Use pdflatex / latex+dvips / latex+dvipdfmx to compile this
\documentclass{article}

\usepackage[T1,T2A]{fontenc}
\usepackage[utf8x]{inputenc}

\begin{document}

% lh font families are used
\texttt{русский язык}

\end{document}

It is also OK if you use inputenc with cp1251 option and save this file in CP1251 encoding.