bug-groff
[Top][All Lists]
Advanced

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

Bug report, mgm macros (tmac.m)


From: Wayne Marshall
Subject: Bug report, mgm macros (tmac.m)
Date: Fri, 9 Mar 2001 08:44:32 -0800 (PST)

2001.03.09
(Fri)

Joergen,

Please find attached bug report for mgm (tmac.m)
macros.

Attachment also as gzipped file (mm_bug.txt.gz), in
order to preserve line lengths, that are otherwise
corrupted by this yahoo mailer.  I regret the
inconvenience.

Thank you!

Wayne Marshall
address@hidden


__________________________________________________
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail. 
http://personal.mail.yahoo.com/
‹Ôú¨:
2001.03.08
(Wed)

Joergen Haag <address@hidden>
Ted Harding <address@hidden>
Werner Lemberg <address@hidden>
bug-groff <address@hidden>


RE:  bug report/fixes for mgm macros (tmac.m)

Groff version:  1.15
mgm version:    1.32
Platform:       FreeBSD 4.2 (intel)


Greetings!

I had occasion to work with Joergen's excellent mgm package
recently (tmac.m), and came across a couple small issues that you
may want to fix in future release.


1.  Page offset (near line 189).

Current:
.\" page offset
.ie r O .po \n[O]

Suggested:
.ie r O .po \n[O]u

Discussion:
The default scale indicator for the .po request is v.  The suggested
change allows the user to specify register O in other dimensions,
such as:

.nr  O  8P
.mso tmac.m



2.  MC macro (near line 1438).

Current:
.\" MC column-size [ column-separation ]
<..snip..>
.nr pg*cols-per-page \
(u;\\n[.l]/(\\n[pg*column-size]+\\n[pg*column-sep]+1))
 
Suggested:
.nr pg*cols-per-page \
(u;(\\n[.l]+\\n[pg*column-sep])/(\\n[pg*column-size]+\\n[pg*column-sep]))


Discussion:

The formula for calculating the number of columns in the original
MC macro is not quite right, as it incorrectly allows for one
additional gutter width.  Consider first the trivial case of one
column, set to span a width exactly equal to the line length.  The
formula as it is won't permit this, as it adds in a gutter width
that won't be used in the layout.

The correct algegraic formula for calculating number of columns
(N) per page is:

       N = (L + G)/(C + G)

where:
       L is current line length,
       C is column width,
       G is gutter width,
       N equal number of columns in line length

and can be derived from the relation:

       (N * C) + ( (N-1) * G) = L

The suggested change will allow users to specify:

.nr  L  30P
.mso tmac.m
.MC  14.5P  1P

This will now work as expected.


My apologies if this is old news.  Thank you for your great work
on this package!

Wayne Marshall
address@hidden


reply via email to

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