7

I've noticed that the same Cyrillic em-dash is rendered differently in English and Russian bibliographic entries. As you can see below, in Russian it's rendered as a single rule but in English it's rendered incorrectly using two overlapped en-dashes.

How to achieve consistency between two languages?

enter image description here

\documentclass{scrreprt}

\usepackage[english, russian]{babel}
\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@BOOK{Boehm:2000,
  author = {Boehm, Barry W.},
  title = {Software cost estimation with Cocomo II},
  year = 2000,
  language = {english}
}
@BOOK{Kelton:2004,
  author = {Кельтон, В. Дэвид and Лоу, Аверилл М.},
  title = {Имитационное моделирование},
  year = 2004,
  language = {russian}
}
\end{filecontents}

\begin{document}
\nocite{*}
\bibliographystyle{gost2008s}
\bibliography{\jobname}
\end{document}

1 Answer 1

5

You get the same dash if you add a suitable definition for \cyrdash

\documentclass{scrreprt}
\usepackage[T2A]{fontenc}
\usepackage[utf8]{inputenc} % change with the actual encoding you're using
\usepackage[english, russian]{babel}
\usepackage{filecontents}

%%% since T2A is loaded we can define \cyrdash to use it
\DeclareTextCommandDefault{\cyrdash}{{\fontencoding{T2A}\selectfont---}}

\begin{filecontents}{\jobname.bib}
@BOOK{Boehm:2000,
  author = {Boehm, Barry W.},
  title = {Software cost estimation with Cocomo II},
  year = 2000,
  language = {english}
}
@BOOK{Kelton:2004,
  author = {Кельтон, В. Дэвид and Лоу, Аверилл М.},
  title = {Имитационное моделирование},
  year = 2004,
  language = {russian}
}
\end{filecontents}

\begin{document}
\nocite{*}
\bibliographystyle{gost2008s}
\bibliography{\jobname}
\end{document}
6
  • Thanks, it works! Actually, it seems that \DeclareTextCommandDefault{\cyrdash}{{\fontencoding{T2A}\selectfont\hbox to.8em{---}}} is more correct.
    – Yury Bayda
    Commented Oct 20, 2013 at 19:42
  • 1
    @megabyde When you do --- in a Cyrillic context you get a character 8.77225pt wide, while 0.8em is 8.71033pt, which means a difference slightly less than 0.022mm. Why should it be “more correct”?
    – egreg
    Commented Oct 20, 2013 at 22:46
  • babel with the russian option does \def\cyrdash{\hbox to.8em{--\hss--}}
    – Yury Bayda
    Commented Oct 20, 2013 at 23:42
  • @megabyde That's just for emulating the dash of the cyrillic font.
    – egreg
    Commented Oct 21, 2013 at 7:29
  • 1
    @megabyde The command \cyrdash might appear in contexts where no Cyrillic font is loaded, so the developers of gost2008s decided to provide a default that doesn't rely on Cyrillic fonts.
    – egreg
    Commented Oct 21, 2013 at 11:32

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .