2

In this code:

\starttext
  \underbar{foo}-bar
\stoptext

ConTeXt also underlines the dash after foo instead of just underlining foo. How can I fix that?

4
  • 1
    What version are you using? In latest LMTX it works fine Mar 10 at 12:25
  • @JairoA.delRio I'm using MacTeX 2020. ConTeXt version is 2020.03.10 14:44. Will update everything and check if that fixes it.
    – flyx
    Mar 10 at 12:28
  • In the meantime, you could add \zwj, \kern0pt or another possibility, but they are only workarounds. I'll ask to the mailing list Mar 10 at 12:40
  • @JairoA.delRio \zwj works and I'd accept it as answer since updating MacTeX did not bring a new ConTeXt version. Might eventually switch to installing ConTeXt standalone besides MacTeX but I don't fancy it.
    – flyx
    Mar 10 at 12:57
4

It's a bug, as ConTeXt LMTX (version 2021.03.09 11:42) gives the correct result (right):

enter image description here enter image description here

I've already sent a message to the mailing list to report this issue.

In the meantime, among other alternatives, a \zwj (zero-width joiner) counts as a workaround.

\starttext
\underbar{foo}\zwj-bar
\stoptext

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.