Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

nroff with me package problem

1 view
Skip to first unread message

Anton Shepelev

unread,
Feb 7, 2009, 4:20:19 PM2/7/09
to
Hello all!

I can't figure out how to make nroff with the -me package output
text without inter-page space. Whatever I do, it keeps putting
one empty line between pages.

I have set the tm value to zero, and when I try to zero the bm
(bottom margin) value, nroff exits with a crash saying: input
stack limit exceeded, possible infinite loop.

Since nroff itself doesn't insert extra emtyline between pages,
I suppose this has something to do with the me package.

Thanks in advance,
Anton


Michael Paoli

unread,
Feb 19, 2009, 6:37:16 AM2/19/09
to Anton Shepelev

With a quick skim of the -me documentation, I didn't see any
supported/documented means of doing so (at least that fully works) ...
but that doesn't mean it can't be done, ... just may not be
particularly
(or at all) portable, and may also end up being rather to quite
version
specific. Using a different macro package may also offer much more
flexibility in these regards.

Your version certainly may vary, but ... inspecting and poking at the
-me macro file I have at my fingertips, I find the following would
seem
to be rather effective - it removes the macro that would seem to be
responsible for top/bottom of page header/footer processing.

It may have undesired side effects - I haven't fully checked.
Alternative approaches could also include setting a sufficiently long
page length (longer than the output of all the formatted text), or
close inspection of macro(s), and making relevant changes,
redefinitions, removals, etc. (e.g. perhaps tweaking some specific
numeric variables would also, or better, do what's desired).

Here's a "before" and "after" example:
$ { head -c `expr 66 '*' 81 '*' 3` /usr/share/dict/words
> echo; } | nroff -me | col -b | expand | nl -ba | expand |
> sed -ne '1,10p;58,76p'
1
2
3
4
5
6
7
8 A A's AOL AOL's Aachen Aachen's Aaron Aaron's Abbott
9 Abbott's Abby Abby's Abdul Abdul's Abe Abe's Abel Abel's
10 Abelard Abelard's Abelson Abelson's Aberdeen Aberdeen's
58 Alford Alford's Alfred Alfred's Alfreda Alfreda's Alfredo
59 Alfredo's Algenib Algenib's Alger Alger's Algeria Algeria's
60 Algerian Algerians Algieba Algieba's Algiers Algiers's Algol
61
62
63
64
65
66
67
68
69
70
71
72
73
74 Algol's Algonquian Algonquian's Algonquians Algonquin Algo-
75 nquin's Alhambra Alhambra's Alhena Alhena's Ali Ali's Alice
76 Alice's Alicia Alicia's Alighieri Alighieri's Aline Aline's
$ { echo '.rm @h'; head -c `expr 66 '*' 81 '*' 3` /usr/share/dict/
words
> echo; } | nroff -me | col -b | expand | nl -ba | expand |
> sed -ne '1,10p;58,76p'
1 A A's AOL AOL's Aachen Aachen's Aaron Aaron's Abbott
2 Abbott's Abby Abby's Abdul Abdul's Abe Abe's Abel Abel's
3 Abelard Abelard's Abelson Abelson's Aberdeen Aberdeen's
4 Abernathy Abernathy's Abidjan Abidjan's Abigail Abigail's
5 Abilene Abilene's Abner Abner's Abraham Abraham's Abram
6 Abram's Abrams Abuja Abyssinia Abyssinia's Abyssinian Ac
7 Ac's Acadia Acadia's Acapulco Acapulco's Accra Accra's
8 Acevedo Acevedo's Achaean Achaean's Achebe Achebe's Achernar
9 Achernar's Acheson Acheson's Achilles Aconcagua Aconcagua's
10 Acosta Acosta's Acropolis Acropolis's Acrux Acrux's Actaeon
58 son's Alissa Alissa's Alistair Alistair's Alkaid Alkaid's
59 Allah Allah's Allahabad Allahabad's Allan Allan's Alleghe-
60 nies Allegheny Allegheny's Allen Allen's Allende Allende's
61 Allentown Allentown's Allie Allie's Allison Allison's All-
62 state Allstate's Allyson Allyson's Alma Alma's Almach
63 Almach's Almaty Almaty's Almighty Almighty's Alnilam
64 Alnilam's Alnitak Alnitak's Alonzo Alonzo's Alpert Alpert's
65 Alphard Alphard's Alphecca Alphecca's Alpheratz Alpheratz's
66 Alphonse Alphonse's Alphonso Alphonso's Alpine Alps Alsace
67 Alsace's Alsatian Alsatian's Alsop Alsop's Alston Alston's
68 Alta Alta's Altai Altai's Altaic Altaic's Altair Altair's
69 Althea Althea's Altiplano Altiplano's Alton Alton's Aludra
70 Aludra's Alva Alva's Alvarado Alvarado's Alvarez Alvarez's
71 Alvaro Alvaro's Alvin Alvin's Alyce Alyce's Alyson Alyson's
72 Alyssa Alyssa's Alzheimer Alzheimer's Am Am's Amadeus
73 Amadeus's Amado Amado's Amalia Amalia's Amanda Amanda's
74 Amarillo Amarillo's Amati Amati's Amazon Amazon's Amazons
75 Amber Amber's Amelia Amelia's Amenhotep Amenhotep's
76 Amerasian Amerasians America America's American Americana
$

0 new messages