groff
[Top][All Lists]
Advanced

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

Re: implementing K-P in a macro (was Re: Mission statement and Knuth-Pla


From: Dave Kemper
Subject: Re: implementing K-P in a macro (was Re: Mission statement and Knuth-Plass reconsidered)
Date: Wed, 10 May 2023 16:30:35 -0500

On 5/8/23, Douglas McIlroy <douglas.mcilroy@dartmouth.edu> wrote:
> K-P would not be a mere add-on to groff. K-P knows in advance the
> shape of the space into which a paragraph must fit, but groff doesn't.
> This means a whole lot of groff state must be carried along with the
> K-P dynamic program.

I don't doubt your analysis of the challenges of implementing K-P, but
it's been done in at least two other roff systems (Heirloom and
neatroff), so it's attainable in a roff framework.  In both of those
it's implemented in the core language, not macro space.

I don't know how feasible Branden's macro idea is, but I like the
novel concept!  Plus, a macro implementation is a whole lot easier for
users to tinker with if they're largely happy with K-P but don't like
this or that particular aspect of it.  They could tweak it and try
their changes immediately without needing to rebuild groff.

And doubtless whatever core language features would need to be added
to enable a hypothetical K-P macro set will find other creative uses
as well.



reply via email to

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