On Sun, Nov 23, 2025 at 08:12:32PM +0000, Bjarni Ingi Gislason wrote:
> On Fri, Nov 21, 2025 at 08:28:49PM +0100, onf wrote:
> > Hi all,
> > 
> > there seems to be an off by one bug in sv's geometry in groff.
> > 
> > Given the input,
> >   .de x
> >   . br
> >   ..
> >   .wh 2v x
> >   Lorem
> >   .br
> >   .sv 1v
> >   ipsum
> >   .br
> >   dolor
> > 
> > groff gives the output
> >   Lorem
> >   ipsum
> >   dolor
> > 
> > whereas both Heirloom troff and Plan 9 troff give
> >   Lorem
> > 
> >   ipsum
> >   dolor
> > 
> > Groff gives the same output when the wh line is
> > changed to
> >   .wh 2v+1u x
> > 
> > (in troff mode; in nroff mode, +1v is needed due to lower resolution)
> > 
> > Cheers,
> > onf
> > 
>   The bug in the 'sv' request is in the heirloom's and plan9's version.
> 
>   A text baseline lands exactly on the next baseline after a 1v long jump.
> 
>   See "Troff User's Manual" (https://troff.org/54.pdf).

  My explanation is wrong.

  The difference between "groff" and the heirloom's and plan9's versions is
the position of the trap.

  Groff sets the vertical position at 24000
  Heirloom sets it at                 24001
  Plan9 sets it at                    241 (lower resolution)

Reply via email to