2

I have a tricky problem with combined diacritics and the CMU font family (CMU Serif). There seems to be no simple way to get the correct .pdf-output for a character like å̄, i.e. a + ring above (U+00E5) + macron (U+0304).

Here's an example:

\documentclass{article}
\usepackage{fontspec}
\setmainfont{CMU Serif}

\begin{document}

I’m stuck with this problem: å̄

\end{document}

Thanks for your help!

Oliver

1
  • I guess it's a specific problem with the font; if I try with different ones, I get the expected output. Not with Latin Modern, though, where the macron overprints the ring.
    – egreg
    Feb 23, 2018 at 13:46

2 Answers 2

2

It seems a specific problem with the font. If I use a different one, I get the expected result (but not with Latin Modern, where the macron overprints the ring).

I can offer a workaround:

\documentclass{article}
\usepackage{fontspec}
\setmainfont{CMU Serif}

\NewDocumentCommand{\aringmacron}{}{%
  \leavevmode
  \vbox{%
    \offinterlineskip
    \ialign{\hfil##\hfil\cr\accent"AF{}\cr\noalign{\kern-1.3ex}å\cr}%
  }%
}
\begin{document}

I’m stuck with this problem: å̄

\aringmacron

\end{document}

enter image description here

1

With lualatex I get

enter image description here

With xelatex

enter image description here

You must log in to answer this question.

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