# TeX4HT \textregistered and an unwanted semicolon

Using \textregistered{} and/or \textregistered result in ®; ®;

Is there a way I can redefine this symbol so that it doesn't include a semicolon or is there a package conflict that is causing this problem?

I had to redefine \textrademark in an if statement because it wasn't working \renewcommand{\texttrademark}{{\si{^{TM}}}} so I am concerned of a compatibility problem somewhere. Not quite sure what the offending package is however since the way I understand it, numerous packages redefine and avail a user of font and symbol controls.

• An example of code? – egreg Jan 19 '15 at 7:39

This is a bug in tex4ht, \textregistered is defined like this in html4.4ht:

\def\:tempc{\special{t4ht@+\string&{35}xAE{59}}x;}
\HLet\textregistered\:tempc


this may seem little bit cryptic, but \special{t4ht@+\string&{35}xAE{59}} outputs special instruction to replace letter x with html entity &#xAE;, this html entity is in later process translated to ® character. there is unnecessary ; character. to fix this, put this into the preamble:

\renewcommand\textregistered{\special{t4ht@+\string&{35}xAE{59}}x}


I posted a bug report with a patch to tex4ht bug db, so I hope it will be fixed quickly in TeXLive:

• Interestingly I can't seem to overwrite \textregistered. I am sure the code you posted should work, but even using \renewcommand{\textregistered}{^{\si{R}}} (which is similar to how I fixed TM doesn't change anything. – EngBIRD Jan 19 '15 at 14:41
• @EngBIRD maybe you use some package which redefines \textregistered? try to put that definition after begin{document}` – michal.h21 Jan 19 '15 at 14:58
• Great thanks! I usually put these sort of new commands in a tex document called immediately before the \begin{document} Turns out that wasn't enough. As per your suggestion, placing it inside \begin{document} fixed it right up. – EngBIRD Jan 19 '15 at 15:04