## tex4ht - Bugs: bug #259, mathtools and starred version of a...

Show feedback again

You are not allowed to post comments on this tracker with your current authentification level.

## bug #259: mathtools and starred version of a DeclarePaireDelimiter macro

 Submitted by: Nicolas Richard Submitted on: Mon 20 Jul 2015 12:46:33 PM EEST Category: None Priority: 5 - Normal Severity: 5 - Normal Status: None Privacy: Public Assigned to: None Open/Closed: Open

Mon 03 Aug 2015 04:15:38 PM EEST, comment #1:

I dno't really know what is the issue, but it seems that this code is the culprit:

\mathopen{}\mathclose\bgroup ##1 ##2 \aftergroup\egroup ##3
and the parameters are {left(}{expression}{\right)}

The problem is that it is declared as macro at the time of calling \DeclarePairedDelimiter, which is in the preamble in your case. As configurations from .4ht files are included after the preamble, we probably can't configure that. One solution which is possible is to use alternative4ht package from helpers4ht bundle[1], for which I provided some configurations[2].

Modified file which works for me:

\documentclass{article}
\usepackage{alternative4ht}
\altusepackage{mathtools}
\makeatletter
\makeatother
\DeclarePairedDelimiter{\paren}{(}{)}
\begin{document}
Examples:

eq1: $c^{2} \paren{a^{2}+b}$ !

eq2: $c^{2} \paren*{a^{2}+b}$ !
\end{document}

I am curious that there aren't any way to provide configurations for commands in the preamble, at least I don't know about any :(

Michal Hoftich <michal_h21>
Mon 20 Jul 2015 12:46:33 PM EEST, original submission:

Running htlatex on the sample file below shows that the non-starred version of \paren is rendered ok, but the starred version is made into a subscript.

Trying to run "htlatex xhtml,mathml" on it produces an error. I guess the two problems are related.

\documentclass{article}
\usepackage{mathtools}
\DeclarePairedDelimiter{\paren}{(}{)}
\begin{document}
Examples:

eq1: $c^{2} \paren{a^{2}+b}$ !

eq2: $c^{2} \paren*{a^{2}+b}$ !
\end{document}

Nicolas Richard <youngfrog>

No files currently attached

Depends on the following items: None found

Items that depend on this one: None found

Carbon-Copy List
• -unavailable- added by michal_h21 (Posted a comment)
• -unavailable- added by youngfrog (Submitted the item)
•

Do you think this task is very important?
This task has 0 encouragements so far.

Only logged-in users can vote.

Please enter the title of George Orwell's famous dystopian book (it's a date):