[texhax] What are possible side effects of faking \leqno?

Daniel H. Luecking luecking at uark.edu
Tue Jan 9 21:21:39 CET 2018


On Fri Jan 5 08:44:31 CET 2018  Vafa Khalighi wrote


> What are the possible side effects

The primitives \eqno and \leqno check if there is room for
The equation number. If there is not, they either shift the
equation slightly (i.e., uncenter it) or move the number to a
different line. In the latter case, \eqno puts it one line below
the equation and \leqno puts it one line above. In your example,
TeX thinks this is a _right_ equation number that is only 0.01 pt
wide so there will be cases where \leqno will shift the equation
right while your faked version will not:
$$
1+2=31+2=31+2=31+2=31+2=31+2=31+2=31+2=31+2=31+2=31+2=3\eqno\hbox{%
\hbox to .01pt{}\rlap{\hskip-\displaywidth
(1)}}
$$

$$
1+2=31+2=31+2=31+2=31+2=31+2=31+2=31+2=31+2=31+2=31+2=3\leqno(1)
$$

\bye

If you make the equation a little longer, the number will overlap
the equation in the first case. If you make it still longer. The
equation number will be on the line below in the first case and
on the line above in the second case.

Cheers,
Dan

Daniel H. Luecking, Graduate Coordinator
Dept. of Mathematical Sciences
University of Arkansas
Fayetteville, AR, USA

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/texhax/attachments/20180109/33c408fc/attachment.html>


More information about the texhax mailing list