[latex2html] Re: [l2h] incorrect equation
John A. Turner
Thu, 28 Dec 2000 17:55:13 -0500 (EST)
>>>>> "RM" == Ross Moore <email@example.com>:
RM> There is an alternative approach, using (La)TeX macros.
RM> 1. Write your math-environment code in a shortened form,
RM> using home-grown macros with parameters, instead of
RM> repeating large chunks of code.
RM> Now you need a way to stop LaTeX2HTML from expanding the macros
RM> early in the processing. Since they are destined to be used for
RM> images anyway, there is absolutely no need for LaTeX2HTML to do
RM> this expansion. Thus there will be a performance saving as well.
RM> 2. Make the macro definitions in a package, and produce a .perl
RM> module for this package.
RM> Macros defined using \def \newcommand etc. are expanded;
RM> but macros defined inside a .perl module are not expanded.
RM> The Perl coding for your macros is easy; since you just have
RM> to ask LaTeX2HTML to ignore all of them.
RM> %%%% homegrown_macros.perl %%%%%%%%
RM> # these macros are only ever used within math-environments
RM> # and made into images;
RM> # so just ignore them for all other processing
RM> &ignore_commands( <<_IGNORED_CMDS_);
RM> %%%% end of homegrown_macros.perl %%%%%%%%
RM> Note that it isn't even necessary to encode the argument structure
RM> of these macros as the whole (unexpanded) code block will just
RM> be passed into images.tex, when it comes time to prepare the images.
OK, as you and I both found, this solves the problems with the incorrect
However, I noticed a problem - if a macro cmd appears within the text
rather than in a displaymath or equation environment, the math doesn't
Examples are always best, so look here:
So my question is, is this intended behavior (i.e. misunderstanding on my
part) or a bug?
John A. Turner, Ph.D. Senior Research Associate
Blue Sky Studios, 44 S. Broadway, White Plains, NY 10601
http://www.blueskystudios.com/ (914) 259-6319