[texhax] Puzzling (La)TeX output
Barbara Beeton
bnb at ams.org
Thu May 4 23:52:31 CEST 2006
I tripped over this and can't explain it; I hope someone here will
show me what I am missing:
Using this source:
=====
\newcommand{\dx}{\rm dx}
$\Phi(\dx_i)=dx_i$.
=====
the braces get stripped off the expansion of the
command, so the \rm isn't scoped. you could change
this to
\newcommand{\dx}{{\rm dx}}
but it would be better to use the latex2e method of
indicating font changes in math by this:
\newcommand{\dx}{\mathrm{dx}}
that definitively limits the scope of the roman to
its argument {dx} .
-- bb
More information about the texhax
mailing list