1

I'm getting the error for missing glyphs in LyX using XeTeX with fontspec on Windows. The error is Missing character: There is no ^^C in font [lmroman10-regular]:mapping=tex-text;!

The wierf thing is that the font LM Roman 10 actually supports the Lambda Character (https://fonts2u.com/lmroman10-regular.font).

Please Help!

The WME in TeX is:

% Preview source code

%% LyX 2.3.1 created this file.  For more info, see http://www.lyx.org/.
%% Do not edit unless you really know what you are doing.
\documentclass[english]{article}
\usepackage[T1]{fontenc}

\makeatletter
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.
\usepackage{fontspec}

\makeatother

\usepackage{babel}
\begin{document}
$\mathrm{\Lambda}$
\end{document}

The WME in LyX is just adding \usepackage{fontspec} to the preamble, and writing $\mathrm{\Lambda}$ in the body of the document.

EDIT: Also happens without fontenc:

% Preview source code

%% LyX 2.3.1 created this file.  For more info, see http://www.lyx.org/.
%% Do not edit unless you really know what you are doing.
\documentclass[english]{article}
\usepackage{fontspec}
\usepackage{polyglossia}
\setdefaultlanguage[variant=american]{english}
\begin{document}
$\mathrm{\Lambda}$
\end{document}

EDIT 2: Verified that it happend also on Ubuntu.

Thanks!

  • 1
    You can't use arbitrary symbols inside \mathrm. Why don't you use simply \Lambda? – Ulrike Fischer Dec 26 '18 at 10:16
  • First of all, with pdflatex it works, but unfortunately I have to use XeTeX. I don't want to just use \Lambda, because it's generated from the .bib file. – EZSlaver Dec 26 '18 at 10:18
  • well \mathrm{\Lambda} is wrong code. That it works with pdflatex is more or less by chance. So you better correct whatever is generating this. – Ulrike Fischer Dec 26 '18 at 10:22
  • never use \usepackage[T1]{fontenc} with xetex, you disable all its Unicode support and force incorrect hyphenation for anything except unaccented English. – David Carlisle Dec 26 '18 at 11:52
  • Is there a way to tell the compiler to just use \Lambda whenever he looks for \mathrm{\Lambda}? – EZSlaver Dec 26 '18 at 12:40
2

This works:

\documentclass[english]{article}

\usepackage{babel}
\usepackage[no-math]{fontspec}

\begin{document}

$\mathrm{\Lambda}$

\end{document}

And also

\documentclass{article}

\usepackage[no-math]{fontspec}
\usepackage{polyglossia}

\setmainlanguage{english}

\begin{document}

$\mathrm{\Lambda}$

\end{document}
2

Instead of loading fontspec with the no-math option, you could instead load unicode-math to set up your math alphabets with Unicode. You could also use mathastext to set up your Greek letters or, in XeLaTeX, mathspec, or for a legacy NFSS font, isomath.

You can also copy-and-paste a Λ into your UTF-8 source.

The reason you’re getting the message about missing character 003, or ^C, is that that’s the character slot for Λ in the legacy OML encoding, but in a Unicode font, 0x03 is a control character, control-C.

  • It's a terrific answer. Thank you. I need to see what I choose to do. – EZSlaver Dec 26 '18 at 21:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.