groff
[Top][All Lists]
Advanced

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

[Groff] trying to understand .ad request


From: Dave Kemper
Subject: [Groff] trying to understand .ad request
Date: Thu, 20 Sep 2012 21:28:30 -0500

Hi all,

I'm getting some curious results with the .ad request.  In the first case
below, a documented example does not seem to work as it should.  In the
second, I'm not sure whether I'm misunderstanding the documentation,
or groff is. :)

If you run the example given for the .ad request in the groff info manual:

   text
   .ad r
   .nr ad \n[.j]
   text
   .ad c
   text
   .na
   text
   .ad         \" back to centering
   text
   .ad \n[ad]  \" back to right justifying

you'll find it doesn't actually work, which seems to be because .ad
does not produce a break.  Adding a .br after every one of the "text"
lines makes it do what's advertised.

What I'm not understanding, though, is the behavior in a much simpler
case:

   text
   .br
   .ad r
   text
   .br
   .ad   \" should go back to the default....
   but doesn't seem to
   .br

The second .ad, made without an argument, should return groff to the
mode it was in before the first .ad call; in the case, the default,
'b' mode.  Instead, the last line is output still in 'r' mode.



reply via email to

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