[comp.text] Hanging indent macro

anne@hall.cray.com (Anne Chenette) (02/19/88)

I'm trying to write a hanging indent macro.  I'm a semi-experienced
troff user, but a novice macro writer.  (I'm running on a SunOS 3.2 system;
I don't have ditroff.)

This is what I want:		COMMAND	This utility executes a
					command in any form
				OTHER	This is another command
					available for use

This is what I get:		COMMAND	This utility executes a
					command in any form
					OTHER	This is another command
						available for use

I started with .TP from the man macros, and took out everything I don't
 want (I left in the stuff I don't understand).  My macro doesn't reset
 the point size, line length, or space down before it starts.  But I
 can't get it to reset the original margins when the macro is finished.

In general, I don't understand how to clean up after a macro that resets
the indents.  I've tried a .in just about everywhere in the definition;
nothing seems to have the right effect.  I've also put a .ev 1 at the top
of the definition, but I must not have put the .ev in the right place at
the end - I got "cannot do ev" when I formatted my file. 

Can anyone help?  My macro definition (and some text to test it with)
is appended to this message.  Thanks in advance!

				  Anne Chenette
				  ...!ihnp4!cray!anne
				    or
				  anne%prolix.cray.com@uc.msc.umn.edu

'\" tagged paragraph macro and text
.deTP
.ps 8
.vs 9
.if!\\$1 .nr )I \\$1n
.sp\\n(PDu
.ne1.1v
.in\\n()Ru
.lg0
.ns
.it1 }N
.nr)E 1
.di]B
..
.de}1
.ds]X \&\\*(]B\\
.rm]B
.nr)E 0
.if!\\$1 .nr )I \\$1n
.ps 8
.vs 9
.ll 3.13i
.in\\n()Ru+\\n(INu+\\n()Iu
.ti\\n(INu
.ie!\\n()Iu+\\n()Ru-\w\\*(]Xu-3p \{\\*(]X
.br\}
.el\\*(]X\h|\\n()Iu+\\n()Ru\c
.ps 8
.vs 9
.lg
..
.de}N
.if\\n()E .br
.di
.if\\n()E0 .}f
.if\\n()E1 .}1
.if\\n()E2 .}2
..
.ll 3.13i
.ps 10
.vs 12
\fBcommand\fR \- Executes a command in any fashion
.sp
\fBcommand [\fB\-\fIoptions\fR] [\fIfiles\fR]
.sp
.ps 8
.vs 9.5
.TP 11
\fB\-b\fR
Shows latest commands first.
.TP
\fB\-v\fR
Excludes column headings from output
.TP
\fB\-n \fIpattern\fR
Shows commands matching \fIpattern\fR.
.sp 2
.ps 10
.vs 12
utility \- Makes a request to execute a utility
.sp
\fButility\fR \fIpathname\fR [\fB\-\fIoptions\fR]
.sp
.TP 12
\fIpathname\fR
Path name where utility actually resides
.TP
\fB\-n \fINAME\fR
Name associated with file
.TP
\fB\-i \fITERMID\fR
Terminal ID associated with
user
.TP
\fB\-u \fIUSER\fR
User ID associated with
terminal 
.ll 3.13i
.ps 10
.vs 12