Closed tpapp closed 2 years ago
It is not a font bug either. The issue you are linking to is saying it is a document bug so you have to fix your document. Furthermore, this repository maintains only the OpenType fonts, the LaTeX package you are using is maintained elsewhere.
The problem is amsmath, which should be loaded always before unicode-math. In your case it is loaded by mathtools, so it overrides some math definitions of unicode-math, which is loaded by libertinus-otf. Use:
\documentclass[a4paper]{article}
\usepackage{mathtools}
\usepackage{libertinus}
\setmathfont{Latin Modern Math}
\begin{document}
\begin{equation}
\underbrace{g_u \lambda_u \Gamma_u}_{\text{example}} =
\underbrace{\int g_e(\varphi) \delta(\varphi) d\varphi}_{\text{example}}
\end{equation}
\end{document}
(I reported this issue originally at latex3/mathtools#43, and was told that this isn't a bug with
mathtools
.)MWE:
results in
using TeXLive 2021.20220204-1 in Ubuntu 22.04. Exchanging the order of
libertinus
andmathtools
fixes the issue.