groff
[Top][All Lists]
Advanced

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

Re: [Groff] -mm formatting macros question


From: Ralph Corderoy
Subject: Re: [Groff] -mm formatting macros question
Date: Fri, 02 Oct 2015 13:41:52 +0100

Hi Marisa,

> Yes this made it start putting in the paragraph separations, but it
> also made the document be 1000 lines long, like 800 of them blank. Is
> there some way to prevent it from filling up to the page size?

Sorry, I should have guessed you would ask that next.  I think the
general technique is to see the page length at the end of the text to
the current position down the very long single page we've so far
produced.

Here, .pl sets the page length to three lines.  .bp has no effect
because we're already at the bottom of the first page.  Then content 1
to 7 take three pages of three lines each.

    $ printf '%s\n' .nf {1..3} '.pl \n(nlu' .bp {1..7} | nroff | cat -n
         1  1
         2  2
         3  3
         4  1
         5  2
         6  3
         7  4
         8  5
         9  6
        10  7
        11  
        12  
    $

IIRC, man(1) does something like this to present a single long page.

Cheers, Ralph.



reply via email to

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