cyrdash
is defined in T2A
, T2B
, T2C
and some other legacy encodings but seems to escape from EU1 (xetex) and EU2 (luatex) encodings. cyrdash
should, by idea, print something intermediate between \textemdash
and \textendash
(\cyrdash
is 20% shorter than emdash
). It is used in Russian, Ukrainian, Bulgarian and Mogolian languages instead of emdash
, so these languages are by fact discriminated.
If I am right and \cyrdash
is indeed lost, could the latex development team please extend EU1
and EU2
encodings to provide a text command for \cyrdash
? It might be called \textcyrdash
.
What is the codepoint of cyrdash
in Unicode tables?
UPDATE: Here is Minimal Working Example. Results depend on the engine used to compile the example. I tried xelatex and pdflatex.
\documentclass{article}
\usepackage{ifxetex}
\ifxetex
\else
\usepackage[T1,T2A]{fontenc}
\usepackage[utf8]{inputenc}
\fi
\usepackage[english,russian]{babel}
\begin{document}
\Large
Russian: \\
!---!=\verb!---!\\
!\foreignlanguage{english}{---}!=\verb!\foreignlanguage{english}{---}!\\
!\cyrdash!=\verb!\cyrdash!\\
!\textemdash!=\verb!\textemdash!\\
!\textendash!=\verb!\textendash!\\
%!---!\par
\selectlanguage{english}
%!---!
English: \\
!---!=\verb!---!\\
!\cyrdash!=\verb!\cyrdash!\\
!\textemdash!=\verb!\textemdash!\\
!\textendash!=\verb!\textendash!\\
\end{document}
Babel
with option russian
redefines ligature ---
through \cyrdash
. Pdflatex takes \cyrdash
and \textemdash
from a same codepoint of LH font if Russian language is selected; then their sizes are equal; if Englsih is current language than \cyrdash
is undefined (rises an error), and \textemdash
is taken from CM fonts and is longer as compared to itself in case if Russian is selected.
In case of xelatex
, \cyrdash
macro is not defined in current encoding so babel
fakes it as \hbox to 0.8em{--\hss--}
which turns out to be approximately 80% of \textemdash
.
Ulrike Fischer directed me to a valuable list of all available dashes in Unicode. I did not find a reasonable candidate for \cyrdash
there although from my own experience of publishing books I know that editors of Russian publishing houses sometimes are very rigorous regarding the size of dashes. I would also agree that Microsoft Word automatically produces correct dashes between russian words but I am not sure (and cannot check right now) if it produces longer dashes between English words.
So I don't see now a good uniform solution for \cyrdash
in case when it should be taken from the same font as \textemdash
. Perhaps, except that soultion which is currently used in babel-russian. Can some one propose a better way?
UPDATE 2: My original vision of the problem was wrong. With the aid of respected TeX'perts it became clear that legacy LaTeX engines take \cyrdash
and \textemdash
from the same codepoint 22
but possibly from different fonts. As a result, ligature ---
might change its length after \selectlanguage
. So, now I would reformulate my question as follows:
Is is good or bad practise to mix two versions of ligature ---
(which differ by their width) in the same multilanguage document?
TU
name, but these are not encodings in the traditional sense. They reflect that fact that for a Unicode font there is 'nothing to do here': each font slot is defined by the Unicode Consortium. If the latter don't provide a suitable dash then it can't appear inTU
, though one can of course define\cyrdash
as a macro.\textthreequartersemdash
which points to U+2012).