1TEXTFMT(1) General Commands Manual TEXTFMT(1)
2
3
4
6 textfmt - convert text to POSTSCRIPT® for facsimile transmission
7
9 /usr/sbin/textfmt [ -O config ] [ options ] [ files... ]
10
12 textfmt takes ASCII text and generates formatted POSTSCRIPT® suitable
13 for facsimile transmission. It is usually invoked as a filter program
14 by the sendfax(1) program. Input files may be specified on the command
15 line. If none are given, then textfmt will read from standard input.
16
17 By default, textfmt will generate an output document that is formatted
18 with a single vertical column of text, set in a 10 point fixed width
19 font, and with a simple page header that consists of the file name,
20 last modification date, and the page number. Pages are generated
21 according to the default page dimensions (see pagesizes(5F)). When
22 multi-column output is requested, text is set by default with a 7 point
23 fixed width font.
24
26 Many of the options to textfmt have been chosen for compatibility with
27 the Adobe Systems' enscript program; other options are for features
28 that are not provided by enscript.
29
30 -1 Set text in one column.
31
32 -2 Set text two columns.
33
34 -B Suppress page headers.
35
36 -c Clip long text lines instead of wrapping them at word boundaries
37 near page margins.
38
39 -D Do not use ISO 8859-1 encoding in the generated POSTSCRIPT.
40
41 -f font
42 Set text using the POSTSCRIPT font named font.
43
44 -F fontdir(s)
45 Path(s) to afm font files.
46
47 -G Use a gaudy-style page header.
48
49 -m cols
50 Set text in cols columns.
51
52 -Ml=#,r=#,t=#,b=#
53 Set the page margins; the default margins are: left and right
54 .25 inch, top .85 inch, bottom .5 inch.
55
56 -o Draw an outline around each column of text; the specified number
57 defines the width of the line that is drawn.
58
59 -O config
60 Treat config as a configuration parameter specification that is
61 interpreted after reading the configuration file. For example,
62 ``-O Host:fax.example.com'' would set the Host configuration
63 parameter to ``fax.example.com'', overriding any setting in the
64 configuration file.
65
66 -p pts Set text using fonts with pts point size (integer only).
67
68 -r Set pages rotated by 90 degrees (in ``Landscape mode'').
69
70 -R Set pages unrotated (in ``Portrait mode'').
71
72 -s size
73 Set the output size according to the named page size. Images
74 are normally created with a system-default page size (usually
75 letter-size pages, 8.5" by 11", for sites in North America).
76 Alternate page sizes are specified symbolically using either the
77 name or abbreviation of an entry in the pagesizes(5F) database;
78 e.g. a3 (ISO A3), a4 (ISO A4), a5 (ISO A5), a6 (ISO A6), b4
79 (ISO B4), na-let (North American Letter), us-leg (American
80 Legal), us-led (American Ledger), us-exe (American Executive),
81 jp-let (Japanese Letter), and jp-leg (Japanese Legal). Compar‐
82 isons are case-insensitive and any match of a substring of the
83 full page-size name is sufficient; e.g. ``legal'' would match
84 ``American Legal''.
85
86 -U Reverse collate pages; that is the last page will appear first
87 in the resultant POSTSCRIPT, then the next-to-last page, etc.
88
89 -V spacing
90 Set the line height; the default height is 1.2 x point size.
91
93 textfmt reads configuration information from the files
94 /etc/hylafax/hyla.conf, and ~/.hylarc; in that order. Configuration
95 files follow the conventions described in hylafax-client(1). The fol‐
96 lowing configuration parameters are recognized:
97 Tag Type Default Description
98 Columns integer 1 number of columns in formatted output
99 GaudyHeaders boolean No enable/disable guady page headers
100 FontMap string see below location of ghostscript Fontmap file
101 FontPath string see below directory for font metric files
102 ISO8859 boolean Yes use ISO 8859-1 character encoding
103 LineWrap boolean Yes wrap/truncate text lines
104 Orientation string portrait orientation of text on page
105 OutlineMargin inches 0 width of outline line
106 PageCollation string forward collate pages in forward or reverse direction
107 PageHeaders boolean Yes enable/disable page headers
108 PageHeight float - output page height
109 PageMargins string see below margins for formatted page
110 PageSize string default output page size from database
111 PageWidth float - output page width
112 TabStop integer 8 inter-stop setting in characters
113 TextFont string Courier name of font for setting text
114 TextLineHeight inches - text formatting line height control
115 TextPointSize inches see below size to use in setting text
116 UTF8 boolean No input is encoded with UTF-8
117
118 The configuration parameters are explained below. Most parameters cor‐
119 respond to a command line option. Parameter values identified above as
120 inches are converted according to the following conventions (where
121 ``#.##'' is a decimal number):
122 #.##bp big point (1in = 72bp)
123 #.##cc cicero (1cc = 12dd)
124 #.##cm centimeter
125 #.##dd didot point (1157dd = 1238pt)
126 #.##in inch
127 #.##mm millimeter (10mm = 1cm)
128 #.##pc pica (1pc = 12pt)
129 #.##pt point (72.27pt = 1in)
130 #.##sp scaled point (65536sp = 1pt)
131
132 Unit names can be upper or lower case but no white space is permitted
133 between the number and the unit. Values specified with no unit are
134 interpreted as big points.
135
136 Columns The number of columns to set text in. (Equivalent to
137 the -m option.)
138
139 FontMap The directory or directories where the ghostscript
140 Fontmap file(s) are located; multiple paths are sepa‐
141 rated by a colon (":"). The Fontmap table allows the
142 translation of the descriptive name of the font (as used
143 by the TextFont parameter) to the ghostscript font file‐
144 names. Setting the value to "" (zero length string) dis‐
145 ables this translation and provides functionality with
146 RIPs other than ghostscript.
147
148 FontPath The path where Adobe Font Metric (AFM) files are
149 located; by default /usr/share/ghost‐
150 script/Resource/Init:/usr/share/ghost‐
151 script/lib:/usr/share/ghost‐
152 script/Resource/Font:/usr/share/ghost‐
153 script/fonts:/usr/share/fonts/urw-
154 base35:/usr/share/fonts/google-droid. (Equivalent to the
155 -F option.)
156
157 GaudyHeaders Control whether or not to use a gaudy-style page header.
158 (Equivalent to the -G option.)
159
160 ISO8859 Control the use of ISO 8859-1 encoding in the generated
161 POSTSCRIPT (Equivalent to the -D option.)
162
163 LineWrap Control whether long text lines are wrapped or truncated
164 at word boundaries near the right hand margin. (Equiva‐
165 lent to the -c option.)
166
167 Orientation Control whether pages are oriented horizontally (``land‐
168 scape'') or vertically (``portrait''). (Equivalent to
169 the -r and -R options.)
170
171 OutlineMargin Control whether columns of text have a line drawn around
172 them and the width of the line. Setting this parameter
173 to 0 disables outlines. (Equivalent to the -o option.)
174
175 PageCollation Control whether the output file has pages collated in
176 the same order as the input file (``forward'') or in
177 reverse order (``reverse). (Equivalent to the -U
178 option.)
179
180 PageHeaders Control whether page headers are generated. (Equivalent
181 to the -B option.)
182
183 PageHeight Set the output page height in inches (in inches).
184
185 PageMargins Set the output page dimensions. Dimensions are speci‐
186 fied as string of the form: ``l=#,r=#,t=#,b=#'' where l
187 indicates the left margin, r indicates the right margin,
188 t indicates the top margin, b indicates the bottom mar‐
189 gin, and numbers are interpreted as inches. (Equivalent
190 to the -M option.)
191
192 PageSize Set the output page dimensions by name. (Equivalent to
193 the -s option.)
194
195 PageWidth Set the output page width in inches (in inches).
196
197 TabStop Set the tab stop distance; in characters.
198
199 TextFont Set the descriptive name of font to use for setting
200 text. (Equivalent to the -f option.)
201
202 TextLineHeight Set the vertical text line height and spacing. (Equiva‐
203 lent to the -V option.)
204
205 TextPointSize Set the point size to use in setting text. (Equivalent
206 to the -p option.)
207
208 UTF8 Interpret the input according to Unicode (UTF-8).
209
211 If textfmt is unable to locate font metric information for a font, then
212 it will use a fixed-width metric that is 60% of the text point size;
213 this metric will almost certainly result in incorrectly formatted POST‐
214 SCRIPT.
215
216 textfmt is distantly related to the lptops program written by Don
217 Beebe.
218
220 /etc/hylafax/hyla.conf system-wide configuration file
221 ~/.hylarc per-user configuration file
222 /etc/hylafax/pagesizes page size database
223 /usr/share/ghostscript/Resource/Init:/usr/share/ghostscript/lib:/usr/share/ghostscript/Resource/Font:/usr/share/ghostscript/fonts:/usr/share/fonts/urw-base35:/usr/share/fonts/google-droid font metric files
224
226 hylafax-client(1), sendfax(1), pagesizes(5F)
227
228
229
230 May 17, 1996 TEXTFMT(1)