{
    "mode": "man",
    "parameter": "groff_www",
    "section": "7",
    "url": "https://www.chedong.com/phpMan.php/man/groff_www/7/json",
    "generated": "2026-10-07T03:23:34Z",
    "sections": {
        "Name": {
            "content": "groffwww - GNU roff macros for authoring web pages\n",
            "subsections": []
        },
        "Synopsis": {
            "content": "groff -m www [option ...] [file ...]\n",
            "subsections": []
        },
        "Description": {
            "content": "This  manual page describes the GNU www macro package, which is part of the groff(7) document\nformatting system.  This macro file is automatically loaded by the default troffrc file  when\nthe  formatter (usually groff(1)) is called with either of the options -Thtml or -Txhtml.  To\nsee hyperlinks in action, format this man page using one of those options.\n\nThis document is a basic guide; the HTML output driver (grohtml) remains in an  alpha  state.\nIt has been included with the distribution to encourage testing.\n\nHere is a summary of the functions found in this macro set.\n\n.JOBNAME     split output into multiple files\n.HX          automatic heading level cut off\n.BCL         specify colours on a web page\n.BGIMG       specify background image\n.URL         create a URL using two parameters\n.FTP         create an FTP reference\n.MTO         create an HTML email address\n.TAG         generate an HTML name\n.IMG         include an image file\n.PIMG        include PNG image\n.MPIMG       place PNG on the margin and wrap text around it\n.HnS         begin heading\n.HnE         end heading\n.LK          emit automatically collected links.\n.HR          produce a horizontal rule\n.NHR         suppress automatic generation of rules.\n.HTL         only generate HTML title\n.HEAD        add data to <head> block\n.ULS         unorder list begin\n.ULE         unorder list end\n.OLS         ordered list begin\n.OLE         ordered list end\n.DLS         definition list begin\n.DLE         definition list end\n.LI          insert a list item\n.DC          generate a drop capital\n.HTML        pass an HTML raw request to the device driver\n.CDS         code example begin\n.CDE         code example end\n.ALN         place links on left of main text.\n.LNS         start a new two-column table with links in the left.\n.LNE         end the two-column table.\n.LINKSTYLE   initialize default URL attributes.\n",
            "subsections": []
        },
        "Macros": {
            "content": "",
            "subsections": [
                {
                    "name": ".JOBNAME filename",
                    "content": "Split output into multiple HTML files.  A file is split whenever a .SH or .NH 1 is en‐\ncountered.   Its  argument is the file stem name for future output files.  This option\nis equivalent to grohtml's -j option.\n\n.HX n  Specify the cut off depth when generating links from section headings.  For example, a\nparameter of 2 would cause grohtml to generate a list of links for .NH 1 and .NH 2 but\nnot for .NH 3.  Whereas\n\n.HX 0\n\ntells grohtml that no heading links should be created  at  all.   Another  method  for\nturning automatic headings off is by issuing the command-line switch -P-l to groff.\n\n.BCL foreground background active not-visited visited\nThis  macro  takes five parameters: foreground, background, active hypertext link, hy‐\npertext link not yet visited, and visited hypertext link colour.\n"
                },
                {
                    "name": ".BGIMG imagefile",
                    "content": "the only parameter to this macro is the background image file.\n"
                },
                {
                    "name": ".URL url [description] [after]",
                    "content": "generates a URL using either one, two, or three arguments.  The first parameter is the\nactual URL, the second is the name of the link, and the third is optional stuff to  be\nprinted  immediately afterwards.  If description and after are absent then the URL be‐\ncomes the anchor text.  Hyphenation is disabled while printing  the  actual  URL;  ex‐\nplicit breakpoints should be inserted with the \\: escape sequence.  Here is how to en‐\ncode foo:\n\n.URL http://\\:foo\\:.org/ foo :\n\nIf this is processed by a device other than -Thtml or -Txhtml it appears as:\n\nfoo ⟨http://foo.org⟩:\n\nThe  URL  macro  can  be of any type; for example, we can reference Eric Raymond's pic\nguide by:\n\n.URL pic\\:.html \"Eric Raymond's pic guide\"\n"
                },
                {
                    "name": ".MTO address [description] [after]",
                    "content": "Generate an email HTML reference.  The first argument is mandatory as  the  email  ad‐\ndress.  The optional second argument is the text you see in your browser.  If an empty\nargument  is  given,  address  is  used  instead.  An optional third argument is stuff\nprinted immediately afterwards.  Hyphenation is disabled  while  printing  the  actual\nemail address.  For example, Joe User can be achieved by the following macro:\n\n.MTO joe@user.org \"Joe User\"\n\nAll  URLs currently are treated as consuming no textual space in groff.  This could be\nconsidered as a bug since it causes some problems.  To circumvent this,  www.tmac  in‐\nserts  a  zero-width  character  which  expands  to a harmless space (only if run with\n-Thtml or -Txhtml).\n"
                },
                {
                    "name": ".FTP url [description] [after]",
                    "content": "indicates that data can be obtained via FTP.  The first argument is the  URL  and  the\nsecond  is  the  browser  text.  A third argument, similar to the macros above, is in‐\ntended for stuff printed immediately afterwards.  The second and the  third  parameter\nare  optional.  Hyphenation is disabled while printing the actual URL.  As an example,\nhere is the location of the GNU FTP server.  The macro example above can be  specified\nas:\n\n.FTP ftp://\\:ftp\\:.gnu\\:.org/ \"GNU FTP server\" .\n"
                },
                {
                    "name": ".TAG name",
                    "content": "Generates  an  HTML name tag from its argument.  This can then be referenced using the\nURL macro.  As you can see, you must precede the tag name with # since it is  a  local\nreference.  This link was achieved via placing a TAG in the URL description above; the\nsource looks like this:\n\n.TP\n.B URL\ngenerates\n.TAG URL\na URL using either two or three arguments.\n...\n"
                },
                {
                    "name": ".IMG [-R|-L|-C] filename [width] [height]",
                    "content": "Include  a  picture into the document.  The first argument is the horizontal location:\nright, left, or center (-R, -L, or -C).  Alignment is centered by default  (-C).   The\nsecond  argument  is  the  filename.   The optional third and fourth arguments are the\nwidth and height.  If the width is absent it defaults to 1 inch.  If the height is ab‐\nsent it defaults to the width.  This maps onto an HTML img tag.  If you are  including\na PNG image then it is advisable to use the PIMG macro.\n"
                },
                {
                    "name": ".PIMG [-R|-L|-C] filename [width [height]]",
                    "content": "Include  an  image in PNG format.  This macro takes exactly the same parameters as the\nIMG macro; it has the advantage of working with PostScript and HTML devices also since\nit can automatically convert the image into the EPS format, using the  following  pro‐\ngrams  of  the  netpbm package: pngtopnm, pnmcrop, and pnmtops.  If the document isn't\nprocessed with -Thtml or -Txhtml it is necessary to use the -U option of groff.\n"
                },
                {
                    "name": ".MPIMG [-R|-L] [-G gap] filename [width [height]]",
                    "content": "Place a PNG image on the margin and wrap text around it.  The first parameters are op‐\ntional.  The alignment: left or right (-L or -R) specifies the margin where  the  pic‐\nture  is  placed  at.   The default alignment is left (-L).  Optionally, -G gap can be\nused to arrange a gap between the picture and the text that wraps around it.  The  de‐\nfault gap width is zero.\nThe first non-optional argument is the filename.  The optional following arguments are\nthe width and height.  If the width is absent it defaults to 1 inch.  If the height is\nabsent it defaults to the width.  Example:\n\n.MPIMG -L -G 2c foo.png 3c 1.5c\n\nThe  height  and width may also be given as percentages.  The PostScript device calcu‐\nlates the width from the .l register and the height from the .p register.   For  exam‐\nple:\n\n.MPIMG -L -G 2c foo.png 15%\n\n.HnS n Begin  heading.  The numeric heading level n is specified by the first parameter.  Use\nthis macro if your headings contain URL, FTP or MTO macros.  Example:\n\n.HnS 1\n.HR\nGNU Troff\n.URL https://\\:www\\:.gnu\\:.org/\\:software/\\:groff/\n\\[em]a\n.URL http://www\\:.gnu\\:.org/ GNU\nproject.\n.HR\n.HnE\n\nIn this case you might wish to disable automatic links to headings.  This can be  done\nvia -P-l from the command line.\n\n.HnE   End heading.\n\n.LK    Force grohtml to place the automatically generated links at this position.\n\n.HR    Generate a full-width horizontal rule for -Thtml and -Txhtml.  No effect for all other\ndevices.\n\n.NHR   Suppress generation of the top and bottom rules which grohtml emits by default.\n\n.HTL   Generate  an  HTML title only.  This differs from the TL macro of the ms macro package\nwhich generates both an HTML title and an <H1> heading.  Use it to provide an HTML ti‐\ntle as search engine fodder but a graphic title in the document.  The macro terminates\nwhen a space or break is seen (.sp, .br).\n\n.HEAD  Add arbitrary HTML data to the <head> block.  Ignored if not processed with -Thtml  or\n-Txhtml.  Example:\n\n.HEAD \"<link \\\nrel=\"\"icon\"\" \\\ntype=\"\"image/png\"\" \\\nhref=\"\"http://foo.org//bar.png\"\"/>\"\n\n.HTML  All  text after this macro is treated as raw HTML.  If the document is processed with‐\nout -Thtml or -Txhtml then the macro is ignored.  Internally, this macro is used as  a\nbuilding block for other higher-level macros.\n\nFor example, the BGIMG macro is defined as\n\n.de BGIMG\n.   HTML <body background=\\\\$1>\n..\n"
                },
                {
                    "name": ".DC l text [color]",
                    "content": "Produce a drop capital.  The first parameter is the letter to be dropped and enlarged,\nthe  second  parameter text is the adjoining text whose height the first letter should\nnot exceed.  The optional third parameter is the color of the dropped letter.  It  de‐\nfaults to black.\n\n.CDS   Start displaying a code section in constant width font.\n\n.CDE   End code display\n"
                },
                {
                    "name": ".ALN [color] [percentage]",
                    "content": "Place section heading links automatically to the left of the main text.  The color ar‐\ngument  is optional and if present indicates which HTML background color is to be used\nunder the links.  The optional percentage indicates the amount of width to  devote  to\ndisplaying  the links.  The default values are #eeeeee and 30 for color and percentage\nwidth, respectively.  This macro should only be called once at the  beginning  of  the\ndocument.   After calling this macro each section heading emits an HTML table consist‐\ning of the links in the left and the section text on the right.\n\n.LNS   Start a new two-column table with links in the left column.  This can be called if the\ndocument has text before the first .SH and if .ALN is used.  Typically this is  called\njust before the first paragraph and after the main title as it indicates that text af‐\nter this point should be positioned to the right of the left-hand navigational links.\n\n.LNE   End  a two-column table.  This should be called at the end of the document if .ALN was\nused.\n"
                },
                {
                    "name": ".LINKSTYLE color [ fontstyle [ openglyph closeglyph ] ]",
                    "content": "Initialize default URL attributes to be used if this macro set is not  used  with  the\nHTML device.  The macro set initializes itself with the following call\n\n.LINKSTYLE blue CR \\[la] \\[ra]\n\nbut these values will be superseded by a user call to LINKSTYLE.\n"
                }
            ]
        },
        "Section heading links": {
            "content": "By default grohtml generates links to all section headings and places these at the top of the\nHTML document.  (See LINKS for details of how to switch this off or alter the position).\n",
            "subsections": []
        },
        "Limitations of grohtml": {
            "content": "tbl(1) tables are rendered as PNG images.  Paul DuBois's approach with tblcvt(1), part of the\ntroffcvt distribution, should be explored.\n",
            "subsections": []
        },
        "Files": {
            "content": "/usr/share/groff/1.23.0/tmac/www.tmac\n",
            "subsections": []
        },
        "Authors": {
            "content": "The www macro package was written by Gaius Mulley, with additions by Werner Lemberg and Bernd\nWarken.\n\nSee also\ngroff(1), troff(1), grohtml(1), netpbm(1)\n\ngroff 1.23.0                                31 March 2024                               groffwww(7)",
            "subsections": []
        }
    },
    "flags": [],
    "examples": [],
    "see_also": []
}