I would like my document to have clickable hyperlinks inside \overset
environments. I'm using XeLaTeX because of the fonts…
This is a (rather) minimal example:
\documentclass[a4paper, 12pt]{article}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{amsthm}
\usepackage[xetex, colorlinks=true, citecolor=blue, linkcolor=blue]{hyperref}
\begin{document}
\begin{equation}
a = b \label{eq} \tag{$\ast$}
\end{equation}
\[ \eqref{eq} \] % working hyperlink here.
\[ c = a \overset{\eqref{eq}}{=} b \] % existing but non-clickable hyperlink here.
\end{document}
Any help is greatly appreciated!
pfdLaTeX
, but notXeLaTeX
.(\ref{eq})
rather than\eqref{eq}
it will work, even with xelatex\text{\ref{eq}}
in a math size other than\displaystyle
. So in display math mode you need a superscript to produce the problem (\overset
implicitly creates a superscript, and\eqref
uses the\textup
command that unravels to\text
), but in inline math the problem occurs without a superscript.$ c = a \overset{\mbox{\scriptsize\eqref{eq}}}{=} b $
works.