My code as follows:


E(\Delta p_{r,j}^s)&=g^s_r\tilde{\tau}_r+d\tilde{t}_r-d\tilde{t}^s+\mu_j\tilde{\iota}_r^s+\tilde{d}_{r,j}-\tilde{d}^s_{,j},


DVI output \Delta symbol came in roman font, but in HTML output, it came in italic font. how can I fix it?

I am running the command:

htlatex filename "xhtml,mathml,mathml-" " -cunihft" " -cvalidate -p"

Please suggest...

  • 1
    Please do not introduce tags that are not reusable. – TeXnician Dec 24 '18 at 13:38

The mathematical characters are output in the <mi> character by tex4ht, which is rendered as italics by browser by default. The following configuration will require the normal font:

\def\Delta{\HCode{<mi mathvariant="normal">}\PauseMathClass\oldDelta\EndPauseMathClass\HCode{</mi>}}

The \PauseMathClass command will prevent insertion of the second <mi> element, which would happen otherwise.

This is the result:

enter image description here

| improve this answer | |
  • Many thanks, so need to redefine all Uppercase Greek else any global options available? – MadyYuvi Dec 24 '18 at 14:43
  • @MadyYuvi yes, they need to be redefined as well. I may add it to tex4ht sources. – michal.h21 Dec 24 '18 at 15:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.