1 .TH GROFF_WWW @MAN7EXT@ "@MDATE@" "Groff Version @VERSION@"
2 .\" Copyright (C) 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
3 .\" Written by Gaius Mulley (gaius@glam.ac.uk)
5 .\" This file is part of groff.
7 .\" groff is free software; you can redistribute it and/or modify it under
8 .\" the terms of the GNU General Public License as published by the Free
9 .\" Software Foundation; either version 2, or (at your option) any later
12 .\" groff is distributed in the hope that it will be useful, but WITHOUT ANY
13 .\" WARRANTY; without even the implied warranty of MERCHANTABILITY or
14 .\" FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
17 .\" You should have received a copy of the GNU General Public License along
18 .\" with groff; see the file COPYING. If not, write to the Free Software
19 .\" Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21 .\" user level guide to using the -mwww macroset
24 .do nr groff_www_C \n[.C]
29 .\" we need the .LK here as we use it in the middle as an example --
30 .\" once the user requests .LK then the automatic generation of links
31 .\" at the top of the document is suppressed.
36 groff_www \- groff macros for authoring web pages
47 This manual page describes the GNU \-mwww macro package, which is part of
48 the groff document formatting system.
49 The manual page is very a basic guide, and the html device driver
51 has been completely rewritten but still remains as in an alpha state.
52 It has been included into the distribution so that a lot of people have a
54 Note that this macro file will be automatically called (via the
59 To see the hyperlinks in action, please format this man page with the
63 Here is a summary of the functions found in this macro set.
66 \&.JOBNAME split output into multiple files
67 \&.HX automatic heading level cut off;
68 $1 point for sections/headers
69 \&.BCL specify colours on a web page
70 \&.BGIMG specify background image
71 \&.URL create a url using two parameters
72 \&.FTP create an ftp reference
73 \&.MTO create a html email address
74 \&.FTP create an ftp reference
75 \&.TAG generate an html name
76 \&.IMG include an image file
77 \&.PIMG include png image
78 \&.MPIMG place png on the margin and
82 \&.LK emit automatically collected links.
83 \&.HR produce a horizontal rule
84 \&.NHR suppress automatic generation of rules.
85 \&.HTL only generate HTML title
86 \&.HEAD add data to <head> block
87 \&.ULS unorder list begin
88 \&.ULE unorder list end
89 \&.LI insert a list item
90 \&.DC generate a drop capital
91 \&.HTML pass an html raw request to the
93 \&.CDS code example begin
94 \&.CDE code example end
103 preprocessors is acceptable as input.
109 Split output into multiple HTML files.
110 A file is split whenever a .SH or .NH\ 1 is encountered.
111 Its argument is the file stem name for future output files.
112 This option is equivalent to
118 Specify the cut off depth when generating links from section headings.
119 For example, a parameter of\~2 would cause
121 to generate a list of links for
137 that no heading links should be created at all.
138 Another method for turning automatic headings off is by issuing the
139 the command line switch
145 .B .BCL foreground background active not-visited visited
146 This macro takes five parameters: foreground, background, active hypertext
147 link, hypertext link not yet visited, and visited hypertext link colour.
151 the only parameter to this macro is the background image file.
154 .B .URL url [description] [after]
157 a URL using either one, two or three arguments.
158 The first parameter is the actual URL, the second is the name of the link,
159 and the third is optional stuff to be printed immediately afterwards.
166 becomes the anchor text.
167 Hyphenation is disabled while printing the actual URL;
169 should be inserted with the
172 Here is how to encode
173 .URL http://\:foo.\:org/ "foo" :
176 .B .URL http://\[rs]:foo.\[rs]:org/ "foo" :
179 If this is processed by a device other than
184 \m[blue]foo\m[] \[la]\f[C]http://foo.org\f[]\[ra]:
187 The URL macro can be of any type; for example we can reference
188 .URL pic.html "Eric Raymond's pic guide"
192 .B .URL pic.html \[dq]Eric Raymond's pic guide\[dq]
196 .B .MTO address [description] [after]
197 Generate an email html reference.
198 The first argument is mandatory as the email address.
199 The optional second argument is the text you see in your browser
200 If an empty argument is given,
203 An optional third argument is stuff printed immediately afterwards.
204 Hyphenation is disabled while printing the actual email address.
206 .MTO joe@user.org "Joe User"
207 was achieved by the following macro:
210 .B .MTO joe@user.org \[dq]Joe User\[dq]
213 Note that all the URLs actually are treated as consuming no textual space
215 This could be considered as a bug since it causes some problems.
218 inserts a zero-width character which expands to a harmless space (only if
223 .B .FTP url [description] [after]
224 indicates that data can be obtained via ftp.
225 The first argument is the url and the second is the browser text.
226 A third argument, similar to the macros above, is intended for stuff printed
227 immediately afterwards.
228 The second and the third parameter are optional.
229 Hyphenation is disabled while printing the actual URL.
230 As an example, here the location of the
231 .FTP ftp://\:ftp.gnu.org/ "GNU ftp server" .
232 The macro example above was specified by:
235 .B .FTP ftp://\[rs]:ftp.gnu.org/ \[dq]GNU ftp server\[dq] .
240 Generates an html name tag from its argument.
241 This can then be referenced using the
244 As you can see, you must precede the tag name with
246 since it is a local reference.
247 This link was achieved via placing a TAG in the URL description above;
248 the source looks like this:
257 a URL using either two or three arguments.
264 .B .IMG [-R|-L|-C] filename [width] [height]
265 Include a picture into the document.
266 The first argument is the horizontal location: right, left, or center
271 Alignment is centered by default (-C).
272 The second argument is the filename.
273 The optional third and fourth arguments are the width and height.
274 If the width is absent it defaults to 1\~inch.
275 If the height is absent it defaults to the width.
276 This maps onto an html img tag.
277 If you are including a png image then it is advisable to use the
282 .B .PIMG [-R|-L|-C] filename [width [height]]
283 Include an image in PNG format.
284 This macro takes exactly the same parameters as the
286 macro; it has the advantage of working with postscript and html devices
287 also since it can automatically convert the image into the EPS format,
288 using the following programs
296 If the document isn't processed with
298 it is necessary to use the
303 .B .MPIMG [-R|-L] [-G gap] filename [width [height]]
304 Place a PNG image on the margin and wrap text around it.
305 The first parameters are optional.
306 The alignment: left or right
310 specifies the margin where the picture is placed at.
311 The default alignment is left
315 can be used to arrange a gap between the picture
316 and the text that wraps around it.
317 The default gap width is zero.
319 The first non-optional argument is the filename.
320 The optional following arguments are the width and height.
321 If the width is absent it defaults to 1\~inch.
322 If the height is absent it defaults to the width.
328 \&.MPIMG -L -G 2c foo.png 3c 1.5c
336 The numeric heading level
338 is specified by the first parameter.
339 Use this macro if your headings contain URL, FTP or MTO macros.
348 \&.URL http://groff.ffii.org (Groff)
350 \&.URL http://www.gnu.org/ GNU
353 \&.URL http://ffii.org/ FFII .
360 In this case you might wish to
361 disable automatic links to headings.
364 from the command line.
365 .\" or by using a call to `.HX 0'.
375 Force \%grohtml to place the automatically generated links at this position.
376 If this manual page has been processed with
378 those links can be seen right here.
384 Generate a full-width horizontal rule for
386 No effect for all other devices.
390 Suppress generation of the top and bottom rules which \%grohtml emits
395 Generate an HTML title only.
396 This differs from the
400 macro package which generates both an HTML title and an <H1> heading.
401 Use it to provide an HTML title as search engine fodder but a graphic title
403 The macro terminates when a space or break is seen (.sp, .br).
407 Add arbitrary HTML data to the <head> block.
408 Ignored if not processed with
414 .B ".HEAD" "\[dq]<link \[rs]"
415 .B " rel=\[dq]\[dq]icon\[dq]\[dq] \[rs]"
416 .B " type=\[dq]\[dq]image/png\[dq]\[dq] \[rs]"
417 .B " href=\[dq]\[dq]http://foo.org//bar.png\[dq]\[dq]/>\[dq]"
424 All text after this macro is treated as raw html.
425 If the document is processed without
427 then the macro is ignored.
428 Internally, this macro is used as a building block for other higher-level
439 \&. HTML <body background=\[rs]$1>
446 .B .DC l text [color]
447 Produce a drop capital.
448 The first parameter is the letter to be dropped and enlarged, the second
451 is the ajoining text whose height the first letter should not exceed.
452 The optional third parameter is the color of the dropped letter.
453 It defaults to black.
457 Start displaying a code section in constant width font.
463 .SH SECTION HEADING LINKS
466 generates links to all section headings and places these at the top of the
469 for details of how to switch this off or alter the position).
472 .SH LIMITATIONS OF GROHTML
475 information is currently rendered as a PNG image.
483 .BR groff (@MAN1EXT@),
484 .BR @g@troff (@MAN1EXT@)
485 .BR \%grohtml (@MAN1EXT@),
492 .MTO gaius@glam.ac.uk "Gaius Mulley"
497 .MTO bug-groff@\:gnu.org "Groff Bug Mailing List" .
498 Include a complete, self-contained example that will allow the bug to be
499 reproduced, and say which version of groff you are using.