[Tex/LaTex] \xRightarrow (text)

amsmatharrowsmath-mode

I know it's possible to have \xrightarrow (text), but if I try to do \xRightarrow (text) I get an error each time. Does anybody know if it's a syntax error or if there is a other way to produce the \Rightarrow with text above?

Best Answer

enter image description here

Just taking the definition of \xrightarrow and replacing r by R :

\documentclass{article}
\usepackage{amsmath}


\makeatletter
\newcommand{\xRightarrow}[2][]{\ext@arrow 0359\Rightarrowfill@{#1}{#2}}
\makeatother

\begin{document}

$\xrightarrow{\mathit{hello}}$


$\xRightarrow{\mathit{hello}}$


\end{document}