bug-groff
[Top][All Lists]
Advanced

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

Re: Extra line injected in output


From: Werner LEMBERG
Subject: Re: Extra line injected in output
Date: Mon, 03 Mar 2008 07:04:29 +0100 (CET)

> > BTW, the reason for the additional blank line is that exactly at
> > that place a page transition has happened, and `.sp -1' can't move
> > up to the previous page and is ignored consequently.
> 
> Thanks -- I didn't know about page transitions at all.  The groff
> info doc mentions "page transition" only once.

Well, replace this with `start a new page'.

> I didn't realize that any kind of paging behavior was going on in
> groff man output for TTY.

Well, yes.

> Is there any way that I can completely suppress page transitions in
> TTY output for a particular man file?

Basically, you can't.  Reason is that you always need to set the page
length, and you might always be able to produce a man page which is
longer than that value.  It is actually possible to set the page
length to a very big value, and at the end of the man page you reset
the page length to the current position to avoid zillions of trailing
empty lines, but I don't recommend fiddling around at such a low
level.  Always remember that man pages are eventually converted to,
say, HTML, which doesn't have the concept of `.sp -1' at all.  With
other words, you should use the high-level man macros and only a
*very* limited set of other groff requests.

> Or is there instead a safe way that I can, when I need to, do
> negative vertical page movements even over a page transition?

You can say

  .ne xxx

where `xxx' is the number of lines you need.  Then you can move up
safely.  But again, this is something you shouldn't do -- it's not the
job of a man author to enforce a certain formatting.  It's very
tempting to do so, I know, but you should avoid it.

> Anyway, I've fixed this particular case by having my stylesheet
> output it as the following instead -- which avoids the need to try
> to adjust the vertical spacing.
> 
>   .SH "Authors"
>   .PP
>   \fBJason Gunthorpe\fR
>   .RS 4
>   Author.
>   .RE
>   .PP
>   \fBAPT team\fR
>   .RS 4
>   Author.
>   .RE
> 
> Is the above an acceptable way to mark it up?

Yes.


    Werner




reply via email to

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