I am trying to get a listing into my LaTeX document.

A simple listing would be the following XML:

<!-- Lüscher-Weiß with β -->

Then I try to get this into my document.




\RequirePackage[charter, greekuppercase=italicized]{mathdesign}






What I get is somewhat close, but not good:

enter image description here

There are two issues:

  • The two hyphens are combined into an en-dash, which is not what I want.
  • The literal UTF-8 “beta” is removed. At least the “ü” and the “ß” are there with luainputenc.

With listings instead of minted I get similar results:

enter image description here

listingsutf8 package does the same.

Why is this literal “beta” missing? I thought that LuaLaTeX and everything with UTF-8 would finally free me from encoding problem? 😫


I think that beramono does not include Greek character support. Try a different font.

\setmonofont{DejaVu Sans Mono}[Scale=MatchLowercase]
With listings:
<!-- Lüscher-Weiß with β -->
With minted:
<!-- Lüscher-Weiß with β -->

enter image description here

  • Indeed, it is an issue with the font! – Martin Ueding Jul 30 '17 at 13: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.