Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ ch06.t ch07.t ch08.t ch09.t ch10.t ch11.t ch12.t ch13.t ch14.t \
ch15.t ch16.t ch17.t ch18.t appa.t appb.t appc.t appd.t appe.t \
appf.t appg.t

utp_book.ps: toc.t utp_ix.t
$(GROFF) -step -ms -rRef=0 utp_book.t >$@.tmp
utp_book.ps: toc.t utp_ix.t utp.mac
$(GROFF) -b -step -ms -rRef=0 utp_book.t >$@.tmp
mv $@.tmp $@

clean::
rm -f utp_book.ps utp_book.ps.tmp

toc.t: $(CHAPTERS)
toc.t: $(CHAPTERS) utp.mac
$(GROFF) -step -ms -rRef=1 ix.macro utp_book.t >/dev/null 2>utp.aux.tmp
mv utp.aux.tmp utp.aux
$(AWK) -f toc.awk utp.aux >$@.tmp
Expand Down
10 changes: 5 additions & 5 deletions src/appa.t
Original file line number Diff line number Diff line change
Expand Up @@ -522,10 +522,10 @@ command.
.\" larger, for readability and to match the paper UTP.
.\" /Andreas 2002-10-21
.TS
tab(#), expand;
cbw(1i) 2 L 2 cbw(1.2i) 2 L 2 cbw(6i-3i)
tab(#);
cbw(1i) 2 L 2 cbw(1.2i) 2 L 2 cb
cb L cb L cb
LfCW L CfCW L L.
LfCW L CfCW L Lx.
Option
(Abbreviation)##Default##Description
_##_##_
Expand Down Expand Up @@ -1126,8 +1126,8 @@ Ahead or back to line matching
.\" The list below need larger space between items.
.\" /Andreas 2002-10-21
.TS
tab(#), expand;
lfCW lw(4i).
tab(#);
lfCW lx.
abbrev#T{
.CW ab[\c
.I "string text"\c
Expand Down
2 changes: 0 additions & 2 deletions src/appb.t
Original file line number Diff line number Diff line change
Expand Up @@ -2416,5 +2416,3 @@ l:n:l:l:n.
.TE
.poE
.ix %end [pic] preprocessor, summary~of command~characters %key pic preprocessor, summary of command~characters


1 change: 0 additions & 1 deletion src/appg.t
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,3 @@ A concise but thorough description of the UNIX
.CW make
utility.
(63 pp.)

1 change: 0 additions & 1 deletion src/ch01.t
Original file line number Diff line number Diff line change
Expand Up @@ -1048,4 +1048,3 @@ it can let you do just what a word processor does.
In many more
instances, it lets you use more of the computer to do things
that a word processor either can't do or can't do very well.

1 change: 0 additions & 1 deletion src/ch02.t
Original file line number Diff line number Diff line change
Expand Up @@ -1191,4 +1191,3 @@ for users of the UNIX system\c
\(em\c
the mechanism by which all the other tools can be made
to work together.

1 change: 0 additions & 1 deletion src/ch03.t
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

.ig
ch03.t
Typed by: Heinz-J�rgen Oertel
Expand Down
1 change: 0 additions & 1 deletion src/ch05.t
Original file line number Diff line number Diff line change
Expand Up @@ -2258,4 +2258,3 @@ Many of these features are covered in Chapters 14 through 18,
where, for example, we show macros for formatting numbered lists.
.ix %end [ms] macros %key ms macros
.\" end of chapter 5

1 change: 0 additions & 1 deletion src/ch06.t
Original file line number Diff line number Diff line change
Expand Up @@ -4591,4 +4591,3 @@ In Chapter 14, you will learn about writing macro definitions,
which should give
you the information you need to write these supplementary
\(lquser exit macros.\(rq

3 changes: 0 additions & 3 deletions src/ch07.t
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@


.ig
Typed up by: Heinz-J�rgen Oertel
Marked up by: Heinz-J�rgen Oertel
Expand Down Expand Up @@ -2862,4 +2860,3 @@ because you can store the commands in named buffers
and access them in any file you edit.
.ix %end [ex] editor %key ex editor
.ix %end [vi] editor %key vi editor

1 change: 0 additions & 1 deletion src/ch08.t
Original file line number Diff line number Diff line change
Expand Up @@ -2353,4 +2353,3 @@ Assets\\a@41,645.8@34,434.7@32,876.6@27,987.6
.Pe
.Fe " Input for Figure 8-3"
.ix %end [tbl] preprocessor %key tbl preprocessor

1 change: 0 additions & 1 deletion src/ch09.t
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

.ig
Typed by: Michael Hobgood
Marked up by: Michael Hobgood
Expand Down
2 changes: 0 additions & 2 deletions src/ch10.t
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@

.ig
Typed by: Michael Hobgood
Marked up by: Michael Hobgood
Proofed on: 17 Oct 2002
..

.so utp.mac
.utp
.ig
Expand Down
2 changes: 0 additions & 2 deletions src/ch11.t
Original file line number Diff line number Diff line change
Expand Up @@ -4236,5 +4236,3 @@ using
Keeping a script of a procedure is also a good start for
building a shell script that performs a routine task
automatically.


27 changes: 22 additions & 5 deletions src/ch12.t
Original file line number Diff line number Diff line change
Expand Up @@ -3162,16 +3162,16 @@ selections a user would select to reach a given command.
For example:
.LP
.in 5n
.BX "\s-2M\s0"\c
.BX \s-2M\s0
ain menu
.in +5n
.BX "\s-2P\s0"\c
.BX \s-2P\s0
ortfolio commands
.in +5n
.BX "\s-2E\s0"\c
.BX \s-2E\s0
valuate portfolios
.in +5n
.BX "\s-2S\s0"\c
.BX \s-2S\s0
hock factors
.in 0
.PP
Expand Down Expand Up @@ -3211,6 +3211,12 @@ aside: The
.CW \ec
escape sequence brings text from the
following line onto the current line.
.\" XXX: Not _exactly_. No forward scanning is performed. When
.\" filling, `\c` instructs the formatter to suppress the word space
.\" that an input line break normally places on the output. When not
.\" filling, it suppresses the _line_ break and input line break
.\" the formatter normally places on the output.
.\" --GBR, 2024-10-08
You would use this,
for example, when you don't want the argument to a macro to
be separated from the first word on the next line by the space
Expand All @@ -3219,7 +3225,18 @@ The fact that the
.CW .BX
macro already makes provision for this case,
and allows you to supply continued text in a second optional
argument, is somewhat irrelevant to this example.
argument,
.\" XXX: Eh? What version of ms did this? Just considering formatters
.\" extant circa 1987 when UTP was written, V6 Unix didn't. V7 Unix
.\" didn't. 4.2BSD didn't. 4.3BSD didn't. DWB 3.3 (which was later,
.\" 1993 or so, but is all we have) didn't.
.\" --GBR, 2024-10-08
.\" https://minnie.tuhs.org/cgi-bin/utree.pl?file=V6/usr/lib/tmac.s
.\" https://minnie.tuhs.org/cgi-bin/utree.pl?file=V7/usr/lib/tmac/tmac.s
.\" https://minnie.tuhs.org/cgi-bin/utree.pl?file=4.2BSD/usr/lib/tmac/tmac.s
.\" https://minnie.tuhs.org/cgi-bin/utree.pl?file=4.3BSD/usr/lib/tmac/tmac.s
.\" https://github.com/n-t-roff/DWB3.3/blob/master/macros/ms/tmac.s.sr
is somewhat irrelevant to this example.
The files had
been coded as shown here, the mistake had been made, and there
were hundreds, perhaps thousands, of instances to correct).
Expand Down
6 changes: 3 additions & 3 deletions src/ch15.t
Original file line number Diff line number Diff line change
Expand Up @@ -386,8 +386,8 @@ Table \\$1: \\$2
. \" left or right margin depending on whether if falls on
. \" an odd or even page, if you change something prior to
. \" calling this, it might shift sides on you.
.if e .tl '\b:\\$1:'''
.if o .tl '''\b:\\$1:'
.if e .tl '\b@\\$1@'''
.if o .tl '''\b@\\$1@'
.lt -.5i
.po +.25i
.cs B
Expand Down Expand Up @@ -1927,7 +1927,7 @@ drawing command as if it were a separate word.
.page 459
.RS
.TS
lf(CW) lw(4.5i).
lf(CW) lx.
T{
\\v'-.25i'\\c
T} T{
Expand Down
10 changes: 5 additions & 5 deletions src/toc.awk
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,16 @@ BEGIN {
/^Se:/ {
if ( $4 == "Contents" )
next;
gsub(/\\f\(CW/, "\\f\(CB" );
gsub(/\\f\[CW\]/, "\\f\[CB\]" );
gsub(/\\fC/, "\\f\[CB\]" );
gsub(/\\f\(CW/, "\\f(CB" );
gsub(/\\f\[CW\]/, "\\f[CB]" );
gsub(/\\fC/, "\\f[CB]" );
print ".ps 12\n.sp";
print $3"\\h'|.25i'\\fB"$4"\\fR "$2;
print ".ps 10\n.sp";
}
/^Ah:/ {
gsub(/\\f\(CB/, "\\f\(CW" );
gsub(/\\f\[CB\]/, "\\f\[CW\]" );
gsub(/\\f\(CB/, "\\f(CW" );
gsub(/\\f\[CB\]/, "\\f[CW]" );
print "\\h'|.25i'"$3""$2;
}
# default (skip index entries)
Expand Down
17 changes: 7 additions & 10 deletions src/utp.mac
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ book available again.

Version of 16 November 2002
..
.ftr C CR
.ftr CW CR
.ftr H HR
.RT
.nr nH 0 \" don't number [ABCD]-heads
.nr gE 0 \" don't add chapter number to [ABCD]-heads
Expand Down Expand Up @@ -157,10 +160,7 @@ Version of 16 November 2002
.de Se \" Section. $1: number, $2: name
. \" $3: type (Chapter, Appendix, ...)
. \" $4: non-null => don't map to uppercase
.if e \{\
\&
.bp
.\}
.if e .bp
.ds chapter_name \\$2
.ie !'\\$1'' \{. \" If we have a section number
. ds chapter_head \\$1
Expand Down Expand Up @@ -201,8 +201,6 @@ Version of 16 November 2002
. \" Might be Preface, etc. so no error diag.
.\}
.nr chapter_page2 1 \" Next page starts a chapter, so no header
.if \\n[%]>1 .bp
.nr PN \\n[%]
.ie '\\$3'NONE' .af PN i
.el .af PN 1
.nr chapter_page 1 \" This page starts a chapter, number at bottom
Expand Down Expand Up @@ -255,12 +253,12 @@ Version of 16 November 2002
.\}
.el .ds chapter_type Chapter
.\" If there is a section number, output Type and section number
.if !'\\$1'' \s14\fB\\*[chapter_type] \\$1\fP\s0
.if !'\\$1'' \s(14\fB\\*[chapter_type] \\$1\fP\s0
.\" If there is no section number, but there is a type, then ouput it
.if '\\$1'' .if !'\\$3'' \s14\fB\\*[chapter_type]\fP\s0
.if '\\$1'' .if !'\\$3'' \s(14\fB\\*[chapter_type]\fP\s0
.sp 5p
.\" Print the section title if there is one
\#.if !'\\$2'' \s14\fB\\$2\fP\s0
\#.if !'\\$2'' \s(14\fB\\$2\fP\s0
.if !'\\$2'' \{\
.ps 14
.B
Expand Down Expand Up @@ -637,7 +635,6 @@ Version of 16 November 2002
\#
.de utp_top
.ev header_footer
.nr PN \\n[%]
.if !\\n[chapter_page2] \{. \" if this page doesn't start a chapter
. ie o .tl ''\\*[chapter_name]'\\n[PN]'
. el .tl '\\n[PN]'\*[square] Unix Text Processing \*[square]''
Expand Down