groff
[Top][All Lists]
Advanced

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

Re: [Groff] [groff] Formatting algorithm


From: Ulrich Lauther
Subject: Re: [Groff] [groff] Formatting algorithm
Date: Fri, 9 May 2014 13:07:02 +0200
User-agent: Mutt/1.5.23 (2014-03-12)

On Fri, May 09, 2014 at 10:48:08AM +0100, Denis M. Wilson wrote:
> The method used in TeX is the shortest path in a directed acyclic graph.
> This is a well-understood problem. There seems unfortunately to be
> nothing useful in the STL. The DAG would need to be a new data type.
> 
To build and use a DAG we need - in general - a node-object and an edge-object.
The node contains a list of outgoing edges, the edge points to its target node
and contains its length (or cost).
Possibly finding the shortest path and building the graph can be combined.
In that case, we do not need any edges, just a pointer in the node to the "best"
predecessor from which it was derived and the correspondig path length.

> The real problem is assigning the values in the DAG. Something of the
> sort must already be in Heirloom troff.
> 
and in the KP paper.

> As there are no modes in troff, I agree with Peter that new commands to
> begin and end a paragraph are required. A careful review of the effect
> of any troff command needs to be done, even possibly restricting the
> effects of some.
> 
> This is the time to introduce shaped paragraphs (also in Heirloom
> Troff).
> 
> IMHO the KP method *should* be used -- if anyone is going to do
> anything at all. It's not going to be me, I'm too old. It's going to be
> hard work, bit doable (Gunnar did it).

May I ask how old you are? (I am 71 years old).

        ulrich



reply via email to

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