[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [groff] mark/lineup in eqn

From: Tadziu Hoffmann
Subject: Re: [groff] mark/lineup in eqn
Date: Wed, 2 May 2018 00:33:50 +0200
User-agent: NeoMutt/20170421 (1.8.2)

> [...] generalizing the application of "mark" and "lineup" in
> eqn to work in columns and piles as well as in separately
> displayed equations.

I'm not sure I understand you correctly.  There is no need
for mark and lineup in columns and piles, because they
already do the right thing.  (?)

> A typical use of mark and lineup is to align = signs in
> a sequence of equations. If the = signs signify steps of a
> derivation, the equations should obviously be connected,
> as in a pile. Displaying them separately, each with its
> own EQ-EN, spreads them out vertically. One can play
> with number registers (e.g. PD and DD in -ms) to try
> to get the pile-like results, but it would much cleaner
> if that could happen for free.

I think this is purely a matter of macro package support which
eqn cannot do itself.  For example, eqn has no idea whether
your displayed equations are left aligned or centered.  Also,
equation numbering is done by the EQ/EN macros, not by eqn,
so to have the different equations of your derivation numbered,
it is necessary to have separate EQ/EN calls.

> There is even a situation that EQ-EN can't handle, but
> piles could:
> .EQ L
> xhortid mark = expression1
> .EN
> .EQ
> longidentifier lineup = expression2
> .EN
> The marked place doesn't leave room for the subsequent
> lineup. Piles, being typeset as a whole, would be
> immune to this trouble.

Actually, I have a proof of concept for this kind of thing in
my own macros, so this is definitely doable with EQ and EN.
I only support centered equations and not left-aligned ones
for now, but I'm sure it can be easily adapted to other cases.
It works by writing the widths to an external file, similar
to the idea of forward references.  If anyone is interested,
I can post my code.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]