27.5 ProblemFix: xnamedef

Footnotes should not be generated from within the title argument. In our case a footnote prevented the maketitle command from showing a title page.

The problematic command was xnamedef. So our first attempt was

\def\@@xnamedef#1#2#3{\href{#3}{\useterm{#2}}}

to switch off footnotes.

Unfortunately, the generated XHTML code would be wrong since there appears now an index generation inside a link. We resolved it by exchanging href and useterm with adjusted arguments.

Note that the following definition heavily relies on the fact that the optional argument for xnamedef comes with an @ sign.

3394ht xname adjustment 339  (327)
\def\@xnamedefsplit#1@#2@{{#1}{#2}}
\def\@@xnamedef#1#2#3{\expandafter\@@@xnamedef\@xnamedefsplit#2@{#1}{#3}}
\def\@@@xnamedef#1#2#3#4{%
  \useterm[\href{#4}{\xnamedefstyle{#2}}]{#1@\xnamedefstyle{#2}}}