\documentclass{article} \usepackage{amsmath} \makeatletter \newcommand{\xLeftrightarrow}[2][]{\ext@arrow 0099\Leftrightarrowfill@{#1}{#2}} \makeatother \begin{document} $A \xLeftrightarrow{\mathit{hello}} B$ \end{document}