[net.bugs] nroff bug query

egisin@watmath.UUCP (Eric Gisin) (01/18/84)

In term(5), the description of bdon (turn on boldface) says
`nroff assumes that bdon is reset by twnl (newline)'.
Therefore nroff should generate bdon for every line requiring
boldface, but it doesn't.
For example, in `nroff -Txerox -man /usr/man/man5/utmp.5'
all three lines beginning at `SYNOPSIS' should be bold,
but only the first is printed bold.
Does anyone have a fix to make nroff match the documentation?
I'm using V7/4BSD troff with tabxerox from 4.2 (I think).

guy@rlgvax.UUCP (Guy Harris) (01/22/84)

> In term(5), the description of bdon (turn on boldface) says
> `nroff assumes that bdon is reset by twnl (newline)'.
> Therefore nroff should generate bdon for every line requiring
> boldface, but it doesn't.
> For example, in `nroff -Txerox -man /usr/man/man5/utmp.5'
> all three lines beginning at `SYNOPSIS' should be bold,
> but only the first is printed bold.
> Does anyone have a fix to make nroff match the documentation?
> I'm using V7/4BSD troff with tabxerox from 4.2 (I think).

Is the term(5) mentioned is the one I posted a while ago?  The vanilla
V7 and USG "nroff" don't assume that "twnl" resets "bdon", but the idiots
at several printer manufacturers misdesigned the firmware in their printers
to reset the automatic boldfacing and underlining whenever they received a
CR.  Since we have one of those printers, I had to modify "nroff" to assume
that "twnl" (which either contains a CR, or contains an NL which is turned
by UNIX into CR/LF, in most cases) would reset "bdon".  This change is very
simple - but remember: if your printer *doesn't* have this deficiency, you have
to modify "twnl" to contain the "bdoff" string.  From the symptoms you mention,
and from the fact that Xerox's character printers are made by Diablo and,
according to their documentation, some Diablos implement this stupidity, I
suspect your printer does have this deficiency.

The fix to "n10.c", in any version of the C-language "nroff" (V7, S3, S5,
and possibly even V6 with "Phototypesetter, Version 7" stuff) is here.  This
refers to a modified S3 "nroff", so don't believe the line numbers or the
context exactly.  Just stick the "bdmode = 0" after the "oputs(t.twnl)".

*** /tmp/,RCSt1013155	Sat Jan 21 22:19:45 1984
--- /tmp/,RCSt2013155	Sat Jan 21 22:19:47 1984
***************
*** 136,141
  		move();
  		ptout1();
  		oputs(t.twnl);
  	}else{
  		lead += t.Newline;
  		move();

--- 136,142 -----
  		move();
  		ptout1();
  		oputs(t.twnl);
+ 		bdmode = 0;	/* twnl is assumed to turn bold mode off */
  	}else{
  		lead += t.Newline;
  		move();

	Guy Harris
	{seismo,ihnp4,allegra}!rlgvax!guy