1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
|
.TH grohtml @MAN1EXT@ "@MDATE@" "groff @VERSION@"
.SH Name
grohtml, post\-grohtml, pre\-grohtml \- groff output driver for HTML
.
.
.\" ====================================================================
.\" Legal Terms
.\" ====================================================================
.\"
.\" Copyright (C) 1999-2021 Free Software Foundation, Inc.
.\"
.\" Permission is granted to make and distribute verbatim copies of this
.\" manual provided the copyright notice and this permission notice are
.\" preserved on all copies.
.\"
.\" Permission is granted to copy and distribute modified versions of
.\" this manual under the conditions for verbatim copying, provided that
.\" the entire resulting derived work is distributed under the terms of
.\" a permission notice identical to this one.
.\"
.\" Permission is granted to copy and distribute translations of this
.\" manual into another language, under the above conditions for
.\" modified versions, except that this permission notice may be
.\" included in translations approved by the Free Software Foundation
.\" instead of in the original English.
.
.
.\" Save and disable compatibility mode (for, e.g., Solaris 10/11).
.do nr *groff_grohtml_1_man_C \n[.cp]
.cp 0
.
.
.\" ====================================================================
.SH Synopsis
.\" ====================================================================
.
.SY pre\-grohtml
.RB [ \-epV ]
.RB [ \-a
.IR anti-aliasing-text-bits ]
.RB [ \-D
.IR image-directory ]
.RB [ \-F
.IR font-directory ]
.RB [ \-g
.IR anti-aliasing-graphic-bits ]
.RB [ \-i
.IR resolution ]
.RB [ \-I
.IR image-stem ]
.RB [ \-o
.IR image-vertical-offset ]
.RB [ \-x
.IR html-dialect ]
.RI [ file
\&.\|.\|.\&]
.YS
.
.
.SY pre\-grohtml
.B \-\-help
.YS
.
.
.SY pre\-grohtml
.B \-v
.
.SY pre\-grohtml
.B \-\-version
.YS
.
.
.SY post\-grohtml
.RB [ \-bCGhlnrVy ]
.RB [ \-F
.IR font-directory ]
.RB [ \-j
.IR output-stem ]
.RB [ \-s
.IR base-point-size ]
.RB [ \-S
.IR heading-level ]
.RB [ \-x
.IR html-dialect ]
.RI [ file
\&.\|.\|.\&]
.YS
.
.
.SY post\-grohtml
.B \-\-help
.YS
.
.
.SY post\-grohtml
.B \-v
.
.SY post\-grohtml
.B \-\-version
.YS
.
.
.\" ====================================================================
.SH Description
.\" ====================================================================
.
The GNU
.I roff
system's HTML support consists of a preprocessor,
.IR pre\-grohtml ,
and a device driver,
.IR post\-grohtml ;
together,
they translate
.IR roff (@MAN7EXT@)
documents to HTML.
.
Users should always invoke
.I grohtml
via the
.IR groff (@MAN1EXT@)
command with the
.B \-Thtml
option.
.
If no operands are given,
or if
.I file
is
.RB \[lq] \- \[rq],
.I grohtml
reads the standard input stream.
.
Output is written to the standard output stream.
.
When
.I grohtml
is run by
.IR groff ,
options can be passed to
.I grohtml
using
.IR groff 's
.B \-P
option.
.
.
.PP
.I grohtml
invokes
.I groff
twice.
.
In the first pass,
the preprocessor
.I pre\-grohtml
renders
pictures,
equations,
and tables as images in PostScript format using the
.B ps
output driver.
.
In the second pass,
the output driver
.I post\-grohtml
translates the output of
.IR \%@g@troff (@MAN1EXT@)
to HTML.
.
.
.PP
.I grohtml
always writes output encoded in \%UTF-8 and has built-in entities for
all non-composite Unicode characters.
.
In spite of this,
.I groff
may issue warnings about unknown special characters if they can't be
found during the first pass.
.
Such warnings can be safely ignored unless the special characters
appear inside a table or equation.
.
.
.\" ====================================================================
.SH Options
.\" ====================================================================
.
.B \-\-help
displays a usage message,
while
.B \-v
and
.B \-\-version
show version information;
all exit afterward.
.
.
.TP
.BI \-a \~anti-aliasing-text-bits
Number of bits of antialiasing information to be used by
.I text
when generating PNG images.
.
The default is\~4 but valid values are 0,
1,
2,
and\~4.
.
Note that your version of
.I gs
needs to support the
.B \%\-dTextAlphaBits
and
.B \%\-dGraphicAlphaBits
options in order to exploit antialiasing.
.
A value of\~0 stops
.I grohtml
from issuing antialiasing commands to
.IR gs .
.
.
.TP
.B \-b
Initialize the background color to white.
.
.
.TP
.B \-C
Suppress output of \[lq]CreationDate:\[rq] HTML comment.
.
.
.TP
.BI \-D \~image-directory
Instruct
.I grohtml
to place all image files into directory
.IR image-directory .
.
.
.TP
.B \-e
This option should not be directly specified;
it is an internal option used by
.I groff
when
.B \-Thtml
or
.B \-Txhtml
is specified.
.
.IR grohtml 's
preprocessor uses it to determine whether
.I eqn
should be directed to produce MathML
(if
.B \-Txhtml
is specified).
.
.
.TP
.BI \-F \~font-directory
Prepend directory
.RI font-directory /dev name
to the search path for font and device description files;
.I name
is the name of the device,
usually
.BR html .
.
.
.TP
.B \-G
Suppress output of \[lq]Creator:\[rq] HTML comment.
.
.
.TP
.BI \-g \~anti-aliasing-graphic-bits
Number of bits of antialiasing information to be used by
.I graphics
when generating PNG images.
.
The default is\~4 but valid values are 0,
1,
2,
and\~4.
.
Note your version of
.I gs
needs to support the
.B \%\-dTextAlphaBits
and
.B \%\-dGraphicAlphaBits
options in order to exploit antialiasing.
.
A value of\~0 stops
.I grohtml
from issuing antialiasing commands to
.IR gs .
.
.
.TP
.B \-h
Generate section and number headings by using
.BR <B> .\|.\|. </B>
and increasing the font size,
rather than using the
.BI <H n >\c
\&.\|.\|.\c
.BI </H n >
tags.
.
.
.TP
.BI \-i \~resolution
Select the resolution for all images.
.
By default this is 100 pixels per inch.
.
Example:
.B \-i200
indicates 200 pixels per inch.
.
.
.TP
.BI \-I \~image-stem
Determine the image file name stem.
.
If omitted grohtml uses
.IR \%grohtml\- XXXXX
(where
.I XXXXX
is the process ID).
.
.
.TP
.BI \-j \~output-stem
Instruct
.I grohtml
to split the HTML output into multiple files.
.
Output is written to a new file at each section heading
(but see option
.B \-S
below)
named
.IR output-stem\- n .html .
.
.
.TP
.B \-l
Turn off the production of automatic section links at the top of the
document.
.
.
.TP
.B \-n
Generate simple heading anchors whenever a section/number heading is
found.
.
Without the option the anchor value is the textual heading.
.
This can cause problems when a heading contains a \[lq]?\[rq] on older
versions of some browsers.
.
This flag is automatically turned on if a heading contains an image.
.
.
.TP
.BI \-o \~image-vertical-offset
Specify the vertical offset of images in points.
.
.
.TP
.B \-p
Display page rendering progress to the standard error stream.
.
.I grohtml
only displays a page number when an image is required.
.
.
.TP
.B \-r
Turn off the automatic header and footer line
(HTML rule).
.
.
.TP
.BI \-s \~base-point-size
Set the base point size of the source file.
.
Thereafter when this point size is used in the source it will correspond
to the HTML base size.
.
Every increase of two points in the source will yield a
.B <big>
tag, and conversely when a decrease of two points is seen a
.B <small>
tag is emitted.
.
.
.TP
.BI \-S \~heading-level
When splitting HTML output
(see option
.B \-j
above),
split at each nested heading level defined by
.IR heading-level ,
or higher).
.
The default is
.BR 1 .
.
.
.TP
.B \-V
Create an XHTML or HTML validator button at the bottom of each page of
the document.
.
.
.TP
.BI \-x \~html-dialect
Select HTML dialect.
.
Currently,
.I html-dialect
should be either the
.RB digit\~ 4
or the
.RB letter\~ x ,
which indicates whether
.I grohtml
should generate HTML\~4 or XHTML,
respectively.
.
This option should not be directly invoked by the user as it is
an internal option utilized by
.I groff
when
.B \-Thtml
or
.B \-Txhtml
is specified.
.
.
.TP
.B \-y
Produce a right-justified
.I groff
signature at the end of the document.
.
This is only generated if the
.B \-V
flag is also specified.
.
.
.\" ====================================================================
.SH Usage
.\" ====================================================================
.
Font styles called
.BR R ,
.BR I ,
.BR B ,
and
.B BI
are mounted at font positions\~1 to\~4,
respectively.
.
.
.\" ====================================================================
.SH Dependencies
.\" ====================================================================
.
.I grohtml
is dependent upon the PNG utilities
.RI ( \%pnmcut ,
.IR \%pnmcrop ,
.IR \%pnmtopng )
and GhostScript
.RI ( gs ).
.
.I \%pnmtopng
(version 2.37.6 or greater)
and
.I \%pnmcut
from the netpbm package (version 9.16 or greater) will work also.
.
It is also dependent upon
.I \%psselect
from the PSUtils package.
.
Images are generated whenever a table,
picture,
equation or line
(such as a baseline rule or box rule)
is encountered.
.
.
.\" ====================================================================
.SH Files
.\" ====================================================================
.
.I grohtml
uses temporary files.
.
See
.IR groff (@MAN1EXT@)
for details about where such files are created.
.
.
.\" ====================================================================
.SH Environment
.\" ====================================================================
.
.TP
.I GROFF_FONT_PATH
A list of directories in which to seek the selected output device's
directory of device and font description files.
.
See
.IR \%@g@troff (@MAN1EXT@)
and
.IR \%groff_font (@MAN5EXT@).
.
.
.TP
.I SOURCE_DATE_EPOCH
A timestamp
(expressed as seconds since the Unix epoch)
to use as the creation timestamp in place of the current time.
.
The time is converted to human-readable form using
.IR ctime (3)
and recorded in an HTML comment.
.
.
.TP
.I TZ
The time zone to use when converting the current time
(or value of
.IR SOURCE_DATE_EPOCH )
to human-readable form;
see
.IR tzset (3).
.
.
.\" ====================================================================
.SH Bugs
.\" ====================================================================
.
.I grohtml
is still beta code.
.
.
.PP
.I grohtml
does not truly support hyphenation,
but you can fool it into hyphenating long input lines,
which can appear in HTML output with a hyphenated word followed by a
space but no line break.
.
.
.\" ====================================================================
.SH "See also"
.\" ====================================================================
.
.\" IR afmtodit (@MAN1EXT@),
.IR groff (@MAN1EXT@),
.IR \%@g@troff (@MAN1EXT@),
.\" IR psbb (1), \" XXX: what is this?
.\" IR groff_out (@MAN5EXT@),
.\" IR groff_char (@MAN7EXT@),
.IR groff_font (@MAN5EXT@)
.
.
.\" Restore compatibility mode (for, e.g., Solaris 10/11).
.cp \n[*groff_grohtml_1_man_C]
.
.
.\" Local Variables:
.\" fill-column: 72
.\" mode: nroff
.\" End:
.\" vim: set filetype=groff textwidth=72:
|