I have set up my document using memoir and polyglossia for hyphenation in greek and english. I have also used my own fonts, using the commands below and it worked great. I am working on sharelatex because i have collaborators.

The problem apperead when, for some reason i wanted to see how my document would look with the default font which is computer modern if i'm not mistaken. So i found the cm otf files and loaded them in my project.

The result is that i get everything ok, except for the heading of chapters, sections, subsections etc, where the greek text doesn't appear at all (only english and numbers). The funny thing is that it did appear with the other otf files i used before.

First of all, i would like to ask if this is the right way to have the deafult cm fonts, actually i want the text to have the same font as math, that's why i used cm. Secondly, if anyone can tell what is the problem with missing greek text in headings.




\newfontfamily\greekfont[Script=Greek,Numbers = Lining,  Mapping=tex-text, BoldFont = cmunrb.otf, ItalicFont = cmunti.otf, BoldItalicFont = cmunbi.otf]{cmunrm.otf} % or other font with support for greek

\newfontfamily\englishfont[Scale = MatchUppercase, Numbers = Lining, Mapping=tex-text,BoldFont = cmunrb.otf, ItalicFont = cmunti.otf, BoldItalicFont = cmunbi.otf]{cmunrm.otf} % or other font with support for english

 Numbers = Lining,

\setmainlanguage[numerals=arabic, variant=monotonic]{greek} 


%My section styles

\section{Κοινωνική ευημερία}
\subsection{Κριτήρια ευημερίας}

\subsubsection*{Το θεώρημα του \textit{\en{Papado}}}

Υποθέτουμε ότι έχουμε δύο $A$ και ο $B$, διαφορετική κατανομή χρησιμότητας από ό,τι το αρχικό σημείο 0. Σύμφωνα με το κριτήριο του {\en \textit{Papado}}, η μετακίνηση από το αρχικό σημείο ισορροπίας

This is an example picture of my output enter image description here

  • Quite strange, because if I set the font with \setmainfont{CMU Serif}, boldface Greek appears.
    – egreg
    Dec 27, 2014 at 16:26
  • But don't i have to upload the fonts or a package first? If i set it just like this it puts an error saying it doesn't find cmu serif
    – S.M
    Dec 27, 2014 at 16:40
  • The instruction I used chooses the font among the system ones, that's the difference.
    – egreg
    Dec 27, 2014 at 16:43
  • maybe i am chosing the wrong otf files, but how can it work inside the main text?
    – S.M
    Dec 27, 2014 at 16:57
  • 2
    The cmunrb.otf you use as bold font seems not to have greek glyph. Try cmunbx.otf instead (that the font use when the command of egreg is used). Btw: You are loading xunicode to early. The best is not to load it at all, fontspec will do it in the correct place anyway. Dec 27, 2014 at 17:26


You must log in to answer this question.

Browse other questions tagged .