groff
[Top][All Lists]
Advanced

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

[Groff] recently introduced bug in -me macro .(b


From: Dave Kemper
Subject: [Groff] recently introduced bug in -me macro .(b
Date: Sun, 29 Dec 2013 09:07:00 -0600

Hi,

This bug report concerns the -me macro set's handling of the .(b and
.)b macro pair.  I'm posting it here rather than bug-groff because for
macro set problems, there is often an expert here who can figure out
the solution quickly.

An earlier bug in this macro pair was present in groff 1.21 (see
http://lists.gnu.org/archive/html/bug-groff/2012-12/msg00011.html);
in 1.22.2, this bug has been fixed, but a new one has taken its place.
I don't know for sure that the fix to the older bug caused the new bug,
but the -me macros aren't really undergoing a lot of change these days,
so it seems somewhat likely.

e.tmac's definition of .(b is the same in both releases.  The definition
of .)b has changed considerably, but I'm nowhere near adept enough at
reading these files to understand the change.  If anyone can figure this
out, I'd greatly appreciate it!

The bug: In 1.22.2, a block defined with .(b and .)b no longer has
the same amount of space above and below it.  meref.me documents that
it should: "All displays except centered blocks and block quotes are
preceded and followed by an extra \n(bs ... space."  So with the following
input file:

.mso me.tmac
.nr bs 2v
Above the block.
.(b L
In the block, with surrounding space = \n(bs.
.)b
Below the block.
.br
.
.nr bs 1v
Above the block.
.(b L
In the block, with surrounding space = \n(bs.
.)b
Below the block.
.br
.
.nr bs 0
Above the block.
.(b L
In the block, with surrounding space = \n(bs.
.)b
Below the block.
.br

in all three cases we should expect to see the "In the block" line
equidistantly spaced from the "Above" and "Below" lines.  (The results
are the same in PostScript and ASCII output; I've pasted the ASCII here.)
This does happen in 1.21; however, 1.22.2 puts one extra line above the
block in each case:

$ groff-1.21 -Tascii test.roff | head -25







Above the block.


In the block, with surrounding space = 80.


Below the block.
Above the block.

In the block, with surrounding space = 40.

Below the block.
Above the block.
In the block, with surrounding space = 0.
Below the block.



$ groff-1.22.2 -Tascii test.roff | head -25







Above the block.



In the block, with surrounding space = 80.


Below the block.
Above the block.


In the block, with surrounding space = 40.

Below the block.
Above the block.

In the block, with surrounding space = 0.
Below the block.
$



reply via email to

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