2

I am attempting to adapt the code for \reallywidehat from a 2016 post, What does \stackMath do?, into my fairly large project as I transition typesetting from LaTeX to LuaLaTeX.

Typesetting the following MWE with LuaLaTeX:

\PassOptionsToPackage{table,xcdraw,svgnames,x11names}{xcolor} 
\documentclass[12pt]{book}  

\usepackage{scalerel}
\usepackage{stackengine}    

\begin{document}

% From: What does \stackMath do?
% https://tex.stackexchange.com/questions/337988/what-does-stackmath-do
\newcommand\reallywidetilde[1]{\ThisStyle{%
     \setbox0=\hbox{$\SavedStyle#1$}%
     \stackengine{-.1\LMpt}{$\SavedStyle#1$}{%
        \stretchto{\scaleto{\SavedStyle\mkern.2mu\AC}{.5150\wd0}}{.6\ht0}%
     }{O}{c}{F}{T}{S}%
 }}

\reallywidetilde{Hypothesis}

\end{document}

Results in the following error:

reallywidetilde.tex:18: Undefined control sequence.
<argument> \SavedStyle \mkern .2mu\AC

Note: The MWE in the post at What does \stackMath do? runs w/o error, and creates a PDF file with the following image:

enter image description here

for the following code:

\reallywidetilde{A}
\test{abcdefghijklm}
\test{abcdefghijk}
\reallywidehat{abcde}

Any thoughts on what might be causing the Undefined control sequence. <argument> \SavedStyle \mkern .2mu\AC error in the above MWE emphasized textwould be greatly appreciated!

Thanks for reading.

4
  • the code you reference has \usepackage{wasysym} to define \AC May 29, 2023 at 11:07
  • @David Carlisle - Thank you ... Yes, of course, silly me if I overlooked that ... Let me have a look to see if my larger project is missing \usepackage{wasysym} ... could be a simple fix! If so, I'll let you know tomorrow ... Then, if you'd like, and can post an answer, I can give you credit. Thanks again! P.S. ... That was FAST! May 29, 2023 at 11:33
  • @David Carlisle - OK ... I just checked, and that worked!! Thank you ... if you don't mind posting your comment as an answer, I can give accept it to give you credit. Apologies for making such a silly error ... Thank you for all your help! Now I'm onto the next LaTeX -> LuaLaTeX typesetting conversion issue! May 29, 2023 at 11:53
  • @David Carlisle - Thank you! (I should have caught this one myself.) May 29, 2023 at 20:47

1 Answer 1

4

The code you reference has \usepackage{wasysym} to define \AC

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .