# Strange result with patch of \overarc

Triying to use a patch for \overarc from this answer https://tex.stackexchange.com/a/409106/54817

I got this result

\documentclass{article}

%\usepackage{fix-cm}

\usepackage{arcs}
\usepackage{etoolbox}

\makeatletter
\patchcmd{\over@under@arc}
{\relsize{-10}}{\renewcommand\RSpercentTolerance{5}\relsize{-10}}{}{\fail}
\makeatother

\begin{document}
\Huge

$$\overarc{AB}$$

\end{document}


Log file:
https://pastebin.com/T5NRMvtb

• The problem is just the same as explained by Ulrike: arcs tries larger sizes, but there aren't defined above \Huge and the bug reappears. – egreg Feb 8 at 13:11
• Same result without \Huge . – Salim Bou Feb 8 at 13:15
• Adding fix-cm package ( without the patch) I got the same thing – Salim Bou Feb 8 at 13:18
• Looks as if you found an example which shows that @egreg patch is needed too ... – Ulrike Fischer Feb 8 at 13:37
• My question is why those dimensions appear before \overarc ? – Salim Bou Feb 8 at 13:51

Different approach, based on Big tilde in math mode

\documentclass{article}
\usepackage{scalerel}
\usepackage{stackengine}

\newcommand\reallywidetilde[1]{\ThisStyle{%
\setbox0=\hbox{$\SavedStyle#1$}%
\stackengine{-.5\LMpt}{$\SavedStyle#1$}{%
\stretchto{\scaleto{\SavedStyle\mkern.2mu\frown}{.4\wd0}}{.5\ht0}%
}{O}{c}{F}{T}{S}%
}}

\def\test#1{$% \reallywidetilde{#1}\, \scriptstyle\reallywidetilde{#1}\, \scriptscriptstyle\reallywidetilde{#1}$\par}

\parskip 1ex
\begin{document}

\test{abcdefghijklm}
\test{abcdefghijk}
\test{abcdefghi}
\test{abcdefg}
\test{abcde}
\test{abc}
\test{ab}
\end{document}


• Thank's for the answer but my question is on the patch explained in my question why those dimensions appear in front of \overarc – Salim Bou Feb 8 at 16:27
\documentclass{article}

\usepackage{arcs}
\usepackage{etoolbox}

\makeatletter
\providecommand\@gobblethree[3]{}
\patchcmd{\over@under@arc}
{\@gobbletwo}
{\@gobblethree}
{}{}
\makeatother

\begin{document}

$$\overarc{AB}$$

\end{document}


I also have the same problem. I have tried to add the above code and it works prefectly.

Refer to the link https://xetex.tug.narkive.com/pBGTS2zG/the-arcs-package#post14, it stated out the problem of the package arcs. To update the code in the package arcs, I refer the link \overarc command from arcs package and xwatermark .