[comp.unix.questions] Getting an English pound symbol out of troff

rog@rtech.rtech.com (Roger Taranto) (10/25/88)

	A friend of mine would like to be able to print an English pound 
symbol (you know, the script L with the bar through the middle), using 
her Sun, and a Sun laser printer.  Does anyone have any suggestions?

Thanks,
-Roger
{mtxinu,pacbell,amdahl,sun,hoptoad}!rtech!rog   rog@rtech.com

whh@pbhya.PacBell.COM (Wilson Heydt) (10/26/88)

In article <2502@rtech.rtech.com>, rog@rtech.rtech.com (Roger Taranto) writes:
> 
> 	A friend of mine would like to be able to print an English pound 
> symbol (you know, the script L with the bar through the middle), using 
> her Sun, and a Sun laser printer.  Does anyone have any suggestions?

Per my wife (who has done a *lot* of troffing), use \z-L.

   --Hal

=========================================================================
  Hal Heydt                             |    "Hafnium plus Holmium is
  Analyst, Pacific*Bell                 |     one-point-five, I think."
  415-645-7708                          |       --Dr. Jane Robinson
  {att,bellcore,sun,ames,pyramid}!pacbell!pbhya!whh   

jimi@h-three.UUCP (jimi) (11/01/88)

In article <2502@rtech.rtech.com>, rog@rtech.rtech.com (Roger Taranto) writes:
> 
> 	A friend of mine would like to be able to print an English pound 
> symbol (you know, the script L with the bar through the middle), using 
> her Sun, and a Sun laser printer.  Does anyone have any suggestions?

The following general approach works. Without knowing some specifics,
however, it's hard to say exactly what needs to be done.

Assumptions:

	Sun is running some flavor of ditroff
	the laser printer supports PostScript

	If the Sun is running troff (not ditroff), then this won't work.
	In the rest of this posting, "troff" refers to ditroff.

Notes:

	The troff name "ps" for the pound symbol is chosen for
	convenience; there is no standard troff name for the
	symbol.

The "regular" PostScript typefaces (e.g. Times Roman, Helvetica)
have the pound symbol as a character. The character set, defined for
each output device in a file called DESC, lists the (troff names of)
all characters in all the fonts that are available on the output device
in a table called "charset".

This table specifies the set of characters that are recognized by the
output device described in DESC. In other words, there must be a troff
name in DESC for all troff character names that occur in any of the font
width tables for a particular device.

The troff name "ps" should be one of the troff names in the charset in
the DESC file for the laser printer. If "ps" is not present in the
charset, add it (use the rest of the table as a guide).

Make sure that the font width tables for the laser printer have a line
in their charset tables that looks like this (field descriptions not
part of font width table):

TROFF 		     POSTSCRIPT POSTSCRIPT
NAME  WIDTH    A/D   OCTAL CODE NAME

charset
	.
	.
	.
ps	56	2	0243	# sterling
	. 
	. 
	. 

In text, the user refers to the pound symbol as \(ps, e.g.:

.P
In London, currency trading went wild as the pound fell at
an alarming rate. By mid-afternoon, shoppers queued outside
shops as the price of a loaf of bread reached \(ps5.
.TS
c s
l n .
New Food Prices
Bread	\(ps5.00
Fish and Chips	\(ps22.50
London Times	\(ps4.25
.TE

Adding characters to DESC and font width tables works similarly
for other output devices, although font widths, of course, will
vary, as will a character's code, for various output devices.

Followups to comp.fonts?
-- 
Jim Ingram	          uunet!h-three!jimi | jimi%h-three@uunet.uu.net
h-three Systems Corporation   P.O. Box 12557 RTP NC 27709   919 549 8334