diff --git a/contrib/chem/chem.1.man b/contrib/chem/chem.1.man index 6af94282b..c8b23bc73 100644 --- a/contrib/chem/chem.1.man +++ b/contrib/chem/chem.1.man @@ -52,16 +52,20 @@ .SH Synopsis .YS . . +.P .SY @g@chem .B \-h +.YS . .SY @g@chem .B \-\-help .YS . . +.P .SY @g@chem .B \-v +.YS . .SY @g@chem .B \%\-\-version diff --git a/contrib/eqn2graph/eqn2graph.1.man b/contrib/eqn2graph/eqn2graph.1.man index 1944c111a..e72be1c3e 100644 --- a/contrib/eqn2graph/eqn2graph.1.man +++ b/contrib/eqn2graph/eqn2graph.1.man @@ -43,13 +43,16 @@ .SH Synopsis .YS . . +.P .SY eqn2graph .B \-\-help .YS . . +.P .SY eqn2graph .B \-v +.YS . .SY eqn2graph .B \%\-\-version diff --git a/contrib/gdiffmk/gdiffmk.1.man b/contrib/gdiffmk/gdiffmk.1.man index 55536efa2..1d5a027e9 100644 --- a/contrib/gdiffmk/gdiffmk.1.man +++ b/contrib/gdiffmk/gdiffmk.1.man @@ -73,11 +73,13 @@ .SH Synopsis .YS . . +.P .SY gdiffmk .B \-\-help .YS . . +.P .SY gdiffmk .B \%\-\-version .YS diff --git a/contrib/glilypond/glilypond.1.man b/contrib/glilypond/glilypond.1.man index b0bab5bb6..b6d8130fe 100644 --- a/contrib/glilypond/glilypond.1.man +++ b/contrib/glilypond/glilypond.1.man @@ -62,7 +62,7 @@ .SH Synopsis .RB [{ \-v | \-V }] .RB [ \-\- ] .RI [ file\~ .\|.\|.] -. +.YS . .SY glilypond .RB [{ \-\-ly2eps | \-\-pdf2eps }] @@ -81,24 +81,35 @@ .SH Synopsis .YS . . +.P .SY glilypond .B \-? +.YS +. .SY glilypond .B \-h +.YS +. .SY glilypond .B \-\-help +.YS +. .SY glilypond .B \-\-usage .YS . . +.P .SY glilypond .B \-l +.YS +. .SY glilypond .B \-\-license .YS . . +.P .SY glilypond .B \%\-\-version .YS diff --git a/contrib/gperl/gperl.1.man b/contrib/gperl/gperl.1.man index d37181b1c..761cf6771 100644 --- a/contrib/gperl/gperl.1.man +++ b/contrib/gperl/gperl.1.man @@ -51,15 +51,20 @@ .SH Synopsis .YS . . +.P .SY gperl .B \-h +.YS . .SY gperl .B \-\-help .YS . +. +.P .SY gperl .B \-v +.YS . .SY gperl .B \%\-\-version diff --git a/contrib/gpinyin/gpinyin.1.man b/contrib/gpinyin/gpinyin.1.man index b9ea14ef8..b40e12e8e 100644 --- a/contrib/gpinyin/gpinyin.1.man +++ b/contrib/gpinyin/gpinyin.1.man @@ -61,15 +61,20 @@ .SH Synopsis .YS . . +.P .SY gpinyin .B \-h +.YS . .SY gpinyin .B \-\-help .YS . +. +.P .SY gpinyin .B \-v +.YS . .SY gpinyin .B \%\-\-version diff --git a/contrib/grap2graph/grap2graph.1.man b/contrib/grap2graph/grap2graph.1.man index 54fc58513..63047e19d 100644 --- a/contrib/grap2graph/grap2graph.1.man +++ b/contrib/grap2graph/grap2graph.1.man @@ -44,13 +44,16 @@ .SH Synopsis .YS . . +.P .SY grap2graph .B \-\-help .YS . . +.P .SY grap2graph .B \-v +.YS . .SY grap2graph .B \%\-\-version diff --git a/contrib/mm/groff_mm.7.man b/contrib/mm/groff_mm.7.man index 164b12cff..72fa6814e 100644 --- a/contrib/mm/groff_mm.7.man +++ b/contrib/mm/groff_mm.7.man @@ -54,6 +54,7 @@ .SH Synopsis .SY "groff \-m@TMAC_M_PREFIX@m" .RI [ option\~ .\|.\|.\&] .RI [ file\~ .\|.\|.] +.YS . .SY "groff \-m m@TMAC_M_PREFIX@m" .RI [ option\~ .\|.\|.\&] diff --git a/contrib/mm/groff_mmse.7.man b/contrib/mm/groff_mmse.7.man index 94c8ab63c..02c5600a1 100644 --- a/contrib/mm/groff_mmse.7.man +++ b/contrib/mm/groff_mmse.7.man @@ -55,6 +55,7 @@ .SH Syntax .SY "groff \-m@TMAC_M_PREFIX@mse" .RI [ flaggor\~ .\|.\|.\&] .RI [ filer\~ .\|.\|.] +.YS . .SY "groff \-m m@TMAC_M_PREFIX@mse" .RI [ flaggor\~ .\|.\|.\&] diff --git a/contrib/mm/mmroff.1.man b/contrib/mm/mmroff.1.man index 97fe9d4c4..bf9d6016f 100644 --- a/contrib/mm/mmroff.1.man +++ b/contrib/mm/mmroff.1.man @@ -57,11 +57,13 @@ .SH Synopsis .YS . . +.P .SY mmroff .B \-\-help .YS . . +.P .SY mmroff .B \%\-\-version .YS diff --git a/contrib/mom/groff_mom.7.man b/contrib/mom/groff_mom.7.man index ac7ca39e7..195a16f95 100644 --- a/contrib/mom/groff_mom.7.man +++ b/contrib/mom/groff_mom.7.man @@ -87,6 +87,7 @@ .SH Synopsis .B \-mom .RI [ option\~ .\|.\|.\&] .RI [ file\~ .\|.\|.] +.YS . .SY groff .B "\-m mom" diff --git a/contrib/pdfmark/pdfroff.1.man b/contrib/pdfmark/pdfroff.1.man index 828ea4535..1f2b8a0d4 100644 --- a/contrib/pdfmark/pdfroff.1.man +++ b/contrib/pdfmark/pdfroff.1.man @@ -65,18 +65,22 @@ .SH Synopsis .YS . . +.P .SY pdfroff .B \-h +.YS . .SY pdfroff .B \-\-help .YS . . +.P .SY pdfroff .B \-v .RI [ groff-option \&.\|.\|.\&] +.YS . .SY pdfroff .B \%\-\-version diff --git a/contrib/pic2graph/pic2graph.1.man b/contrib/pic2graph/pic2graph.1.man index f8b867f32..af45e439e 100644 --- a/contrib/pic2graph/pic2graph.1.man +++ b/contrib/pic2graph/pic2graph.1.man @@ -46,13 +46,16 @@ .SH Synopsis .YS . . +.P .SY pic2graph .B \-\-help .YS . . +.P .SY pic2graph .B \-v +.YS . .SY pic2graph .B \%\-\-version diff --git a/src/devices/grodvi/grodvi.1.man b/src/devices/grodvi/grodvi.1.man index 4d5758c26..1a2d0d1f7 100644 --- a/src/devices/grodvi/grodvi.1.man +++ b/src/devices/grodvi/grodvi.1.man @@ -75,13 +75,16 @@ .SH Synopsis .YS . . +.P .SY grodvi .B \-\-help .YS . . +.P .SY grodvi .B \-v +.YS . .SY grodvi .B \%\-\-version diff --git a/src/devices/grohtml/grohtml.1.man b/src/devices/grohtml/grohtml.1.man index ef617703f..963b98c18 100644 --- a/src/devices/grohtml/grohtml.1.man +++ b/src/devices/grohtml/grohtml.1.man @@ -75,19 +75,23 @@ .SH Synopsis .YS . . +.P .SY pre\-grohtml .B \-\-help .YS . . +.P .SY pre\-grohtml .B \-v +.YS . .SY pre\-grohtml .B \%\-\-version .YS . . +.P .SY post\-grohtml .RB [ \-bCGhlnrVy ] .RB [ \-F @@ -104,13 +108,16 @@ .SH Synopsis .YS . . +.P .SY post\-grohtml .B \-\-help .YS . . +.P .SY post\-grohtml .B \-v +.YS . .SY post\-grohtml .B \%\-\-version diff --git a/src/devices/grolbp/grolbp.1.man b/src/devices/grolbp/grolbp.1.man index e42f48691..69e95a65f 100644 --- a/src/devices/grolbp/grolbp.1.man +++ b/src/devices/grolbp/grolbp.1.man @@ -69,6 +69,7 @@ .SH Synopsis .RB [ \-w\~\c .IR width ] .RI [ file\~ .\|.\|.] +.YS . .SY grolbp [\c @@ -88,16 +89,20 @@ .SH Synopsis .YS . . +.P .SY grolbp .B \-h +.YS . .SY grolbp .B \-\-help .YS . . +.P .SY grolbp .B \-v +.YS . .SY grolbp .B \%\-\-version diff --git a/src/devices/grolj4/grolj4.1.man b/src/devices/grolj4/grolj4.1.man index 9d6180a15..a4762ae8e 100644 --- a/src/devices/grolj4/grolj4.1.man +++ b/src/devices/grolj4/grolj4.1.man @@ -75,13 +75,16 @@ .SH Synopsis .YS . . +.P .SY grolj4 .B \-\-help .YS . . +.P .SY grolj4 .B \-v +.YS . .SY grolj4 .B \%\-\-version diff --git a/src/devices/gropdf/gropdf.1.man b/src/devices/gropdf/gropdf.1.man index 1a48e01f3..cc1971858 100644 --- a/src/devices/gropdf/gropdf.1.man +++ b/src/devices/gropdf/gropdf.1.man @@ -78,13 +78,16 @@ .SH Synopsis .YS . . +.P .SY gropdf .B \-\-help .YS . . +.P .SY gropdf .B \-v +.YS . .SY gropdf .B \%\-\-version diff --git a/src/devices/gropdf/pdfmom.1.man b/src/devices/gropdf/pdfmom.1.man index 77397fded..8d88b4d46 100644 --- a/src/devices/gropdf/pdfmom.1.man +++ b/src/devices/gropdf/pdfmom.1.man @@ -60,6 +60,7 @@ .SH Synopsis .YS . . +.P .SY pdfmom .RB [ \-\-roff ] .B \-Tps @@ -69,8 +70,10 @@ .SH Synopsis .YS . . +.P .SY pdfmom .B \-v +.YS . .SY pdfmom .B \%\-\-version diff --git a/src/devices/grops/grops.1.man b/src/devices/grops/grops.1.man index 9f4b73fd9..b42ad9f5d 100644 --- a/src/devices/grops/grops.1.man +++ b/src/devices/grops/grops.1.man @@ -80,13 +80,16 @@ .SH Synopsis .YS . . +.P .SY grops .B \-\-help .YS . . +.P .SY grops .B \-v +.YS . .SY grops .B \%\-\-version diff --git a/src/devices/grotty/grotty.1.man b/src/devices/grotty/grotty.1.man index bf88065d9..29d98b101 100644 --- a/src/devices/grotty/grotty.1.man +++ b/src/devices/grotty/grotty.1.man @@ -60,6 +60,7 @@ .SH Synopsis .YS . . +.P .SY "grotty \-c" .RB [ \-bBdfhouU ] .RB [ \-F\~\c @@ -68,13 +69,16 @@ .SH Synopsis .YS . . +.P .SY grotty .B \-\-help .YS . . +.P .SY grotty .B \-v +.YS . .SY grotty .B \%\-\-version diff --git a/src/devices/xditview/gxditview.1.man b/src/devices/xditview/gxditview.1.man index fc504ea94..5ddeaf9b7 100644 --- a/src/devices/xditview/gxditview.1.man +++ b/src/devices/xditview/gxditview.1.man @@ -73,16 +73,20 @@ .SH Synopsis .YS . . +.P .SY gxditview .B \-help +.YS . .SY gxditview .B \-\-help .YS . . +.P .SY gxditview .B \-version +.YS . .SY gxditview .B \%\-\-version diff --git a/src/preproc/eqn/eqn.1.man b/src/preproc/eqn/eqn.1.man index e8d977c03..8c29b5790 100644 --- a/src/preproc/eqn/eqn.1.man +++ b/src/preproc/eqn/eqn.1.man @@ -78,13 +78,16 @@ .SH Synopsis .YS . . +.P .SY @g@eqn .B \-\-help .YS . . +.P .SY @g@eqn .B \-v +.YS . .SY @g@eqn .B \%\-\-version diff --git a/src/preproc/grn/grn.1.man b/src/preproc/grn/grn.1.man index be753a52b..5244a33cb 100644 --- a/src/preproc/grn/grn.1.man +++ b/src/preproc/grn/grn.1.man @@ -64,16 +64,20 @@ .SH Synopsis .YS . . +.P .SY @g@grn .B \-? +.YS . .SY @g@grn .B \-\-help .YS . . +.P .SY @g@grn .B \-v +.YS . .SY @g@grn .B \%\-\-version diff --git a/src/preproc/pic/pic.1.man b/src/preproc/pic/pic.1.man index 49e8f1274..af464f7c3 100644 --- a/src/preproc/pic/pic.1.man +++ b/src/preproc/pic/pic.1.man @@ -74,6 +74,7 @@ .SH Synopsis .YS . . +.P .SY @g@pic .B \-t .RB [ \-cCSUz ] @@ -81,13 +82,16 @@ .SH Synopsis .YS . . +.P .SY @g@pic .B \-\-help .YS . . +.P .SY @g@pic .B \-v +.YS . .SY @g@pic .B \%\-\-version diff --git a/src/preproc/preconv/preconv.1.man b/src/preproc/preconv/preconv.1.man index 2eb89b3ad..837720c7d 100644 --- a/src/preproc/preconv/preconv.1.man +++ b/src/preproc/preconv/preconv.1.man @@ -60,16 +60,20 @@ .SH Synopsis .YS . . +.P .SY preconv .B \-h +.YS . .SY preconv .B \-\-help .YS . . +.P .SY preconv .B \-v +.YS . .SY preconv .B \%\-\-version diff --git a/src/preproc/refer/refer.1.man b/src/preproc/refer/refer.1.man index 8bd7d38ce..21a0535f0 100644 --- a/src/preproc/refer/refer.1.man +++ b/src/preproc/refer/refer.1.man @@ -77,13 +77,16 @@ .SH Synopsis .YS . . +.P .SY @g@refer .B \-\-help .YS . . +.P .SY @g@refer .B \-v +.YS . .SY @g@refer .B \%\-\-version diff --git a/src/preproc/soelim/soelim.1.man b/src/preproc/soelim/soelim.1.man index df65e5cea..935267a5e 100644 --- a/src/preproc/soelim/soelim.1.man +++ b/src/preproc/soelim/soelim.1.man @@ -70,13 +70,16 @@ .SH Synopsis .YS . . +.P .SY @g@soelim .B \-\-help .YS . . +.P .SY @g@soelim .B \-v +.YS . .SY @g@soelim .B \%\-\-version diff --git a/src/preproc/tbl/tbl.1.man b/src/preproc/tbl/tbl.1.man index 92bb5b137..75302ffaf 100644 --- a/src/preproc/tbl/tbl.1.man +++ b/src/preproc/tbl/tbl.1.man @@ -58,13 +58,16 @@ .SH Synopsis .YS . . +.P .SY @g@tbl .B \-\-help .YS . . +.P .SY @g@tbl .B \-v +.YS . .SY @g@tbl .B \%\-\-version diff --git a/src/roff/groff/groff.1.man b/src/roff/groff/groff.1.man index 7718142c9..318ee0445 100644 --- a/src/roff/groff/groff.1.man +++ b/src/roff/groff/groff.1.man @@ -94,18 +94,22 @@ .SH Synopsis .YS . . +.P .SY groff .B \-h +.YS . .SY groff .B \-\-help .YS . . +.P .SY groff .B \-v .RI [ option\~ .\|.\|.\&] .RI [ file\~ .\|.\|.] +.YS . .SY groff .B \%\-\-version diff --git a/src/roff/nroff/nroff.1.man b/src/roff/nroff/nroff.1.man index 424be4992..5653fd242 100644 --- a/src/roff/nroff/nroff.1.man +++ b/src/roff/nroff/nroff.1.man @@ -85,13 +85,16 @@ .SH Synopsis .YS . . +.P .SY @g@nroff .B \-\-help .YS . . +.P .SY @g@nroff .B \-v +.YS . .SY @g@nroff .B \%\-\-version diff --git a/src/roff/troff/troff.1.man b/src/roff/troff/troff.1.man index 2dcbe6db0..046cfbd4b 100644 --- a/src/roff/troff/troff.1.man +++ b/src/roff/troff/troff.1.man @@ -84,13 +84,16 @@ .SH Synopsis .YS . . +.P .SY @g@troff .B \-\-help .YS . . +.P .SY @g@troff .B \-v +.YS . .SY @g@troff .B \%\-\-version diff --git a/src/utils/addftinfo/addftinfo.1.man b/src/utils/addftinfo/addftinfo.1.man index fd995ea29..53b5283ac 100644 --- a/src/utils/addftinfo/addftinfo.1.man +++ b/src/utils/addftinfo/addftinfo.1.man @@ -75,13 +75,16 @@ .SH Synopsis .YS . . +.P .SY addftinfo .B \-\-help .YS . . +.P .SY addftinfo .B \-v +.YS . .SY addftinfo .B \%\-\-version diff --git a/src/utils/afmtodit/afmtodit.1.man b/src/utils/afmtodit/afmtodit.1.man index d436f7fdb..ae901a25e 100644 --- a/src/utils/afmtodit/afmtodit.1.man +++ b/src/utils/afmtodit/afmtodit.1.man @@ -73,13 +73,16 @@ .SH Synopsis .YS . . +.P .SY afmtodit .B \-\-help .YS . . +.P .SY afmtodit .B \-v +.YS . .SY afmtodit .B \%\-\-version diff --git a/src/utils/grog/grog.1.man b/src/utils/grog/grog.1.man index d51cc4190..40ca9a8f6 100644 --- a/src/utils/grog/grog.1.man +++ b/src/utils/grog/grog.1.man @@ -55,16 +55,20 @@ .SH Synopsis .YS . . +.P .SY grog .B \-h +.YS . .SY grog .B \-\-help .YS . . +.P .SY grog .B \-v +.YS . .SY grog .B \%\-\-version diff --git a/src/utils/hpftodit/hpftodit.1.man b/src/utils/hpftodit/hpftodit.1.man index d28c90032..f39aebbbc 100644 --- a/src/utils/hpftodit/hpftodit.1.man +++ b/src/utils/hpftodit/hpftodit.1.man @@ -62,6 +62,7 @@ .SH Synopsis .YS . . +.P .SY hpftodit .B \-d .I tfm-file @@ -69,13 +70,16 @@ .SH Synopsis .YS . . +.P .SY hpftodit .B \-\-help .YS . . +.P .SY hpftodit .B \-v +.YS . .SY hpftodit .B \%\-\-version diff --git a/src/utils/indxbib/indxbib.1.man b/src/utils/indxbib/indxbib.1.man index 261e32b97..54dab1598 100644 --- a/src/utils/indxbib/indxbib.1.man +++ b/src/utils/indxbib/indxbib.1.man @@ -75,13 +75,16 @@ .SH Synopsis .YS . . +.P .SY @g@indxbib .B \-\-help .YS . . +.P .SY @g@indxbib .B \-v +.YS . .SY @g@indxbib .B \%\-\-version diff --git a/src/utils/lkbib/lkbib.1.man b/src/utils/lkbib/lkbib.1.man index 46dfb020c..a23412463 100644 --- a/src/utils/lkbib/lkbib.1.man +++ b/src/utils/lkbib/lkbib.1.man @@ -63,13 +63,16 @@ .SH Synopsis .YS . . +.P .SY lkbib .B \-\-help .YS . . +.P .SY lkbib .B \-v +.YS . .SY lkbib .B \%\-\-version diff --git a/src/utils/lookbib/lookbib.1.man b/src/utils/lookbib/lookbib.1.man index ac1248f8e..390caa648 100644 --- a/src/utils/lookbib/lookbib.1.man +++ b/src/utils/lookbib/lookbib.1.man @@ -59,13 +59,16 @@ .SH Synopsis .YS . . +.P .SY @g@lookbib .B \-\-help .YS . . +.P .SY @g@lookbib .B \-v +.YS . .SY @g@lookbib .B \%\-\-version diff --git a/src/utils/pfbtops/pfbtops.1.man b/src/utils/pfbtops/pfbtops.1.man index e444f569e..9a664ddbe 100644 --- a/src/utils/pfbtops/pfbtops.1.man +++ b/src/utils/pfbtops/pfbtops.1.man @@ -55,13 +55,16 @@ .SH Synopsis .YS . . +.P .SY pfbtops .B \-\-help .YS . . +.P .SY pfbtops .B \-v +.YS . .SY pfbtops .B \%\-\-version diff --git a/src/utils/tfmtodit/tfmtodit.1.man b/src/utils/tfmtodit/tfmtodit.1.man index 891a77e47..942202677 100644 --- a/src/utils/tfmtodit/tfmtodit.1.man +++ b/src/utils/tfmtodit/tfmtodit.1.man @@ -72,13 +72,16 @@ .SH Synopsis .YS . . +.P .SY tfmtodit .B \-\-help .YS . . +.P .SY tfmtodit .B \-v +.YS . .SY tfmtodit .B \%\-\-version diff --git a/src/utils/xtotroff/xtotroff.1.man b/src/utils/xtotroff/xtotroff.1.man index c49c78b9d..b6bf025fc 100644 --- a/src/utils/xtotroff/xtotroff.1.man +++ b/src/utils/xtotroff/xtotroff.1.man @@ -62,13 +62,16 @@ .SH Synopsis .YS . . +.P .SY xtotroff .B \-\-help .YS . . +.P .SY xtotroff .B \-v +.YS . .SY xtotroff .B \%\-\-version diff --git a/tmac/an-ext.tmac b/tmac/an-ext.tmac index 5a2ede65c..e45fe0c8a 100644 --- a/tmac/an-ext.tmac +++ b/tmac/an-ext.tmac @@ -1,6 +1,6 @@ .\" groff extension macros for man(7) package .\" -.\" Copyright (C) 2007-2023 Free Software Foundation, Inc. +.\" Copyright (C) 2007-2024 Free Software Foundation, Inc. .\" .\" Written by Eric S. Raymond .\" Werner Lemberg @@ -55,35 +55,59 @@ .de mY . .\" Declare start of command synopsis. Sets up hanging indentation. .de SY -. ie !\\n(mS \{\ -. mY -. nh -. nr mS 1 -. nr mA \\n(.j +. ie \\n(.$ \{\ +. if !\\n(mS \{\ +. mY +. nh +. nr mS 1 +. nr mA \\n(.j +. nr mI \\n(.i +. nr mT \\n(.k+\w'\fB\\$1\fP' +. if \\n(.$=1 \ +. nr mT +\w'\ ' +. if \\n(.$>1 \ +. nr mT +\w'\fB\\$2\fP' +. \} +. . ad l -. nr mI \\n(.i -. sp +. \" Ensure that a partially collected line exists so that the `in` +. \" request affects only _subsequent_ output lines. (CSTR #54 §6) +\&\c +' in +\\n(mTu +. +. if \\n(.$=1 \{\ +. do nr .X +0 \" Ensure this Heirloom register exists for testing. +. \" If the formatter is not groff, work around DWB/Heirloom/ +. \" Solaris 10 glitch. Something in their man(7) defeats the +. \" rules set forth in CSTR #54 §6. +. if \\n(.g=0:\\n(.X \ +' ti -\\n(mTu +. B \\$1\ \c +. \} +. if \\n(.$>1 \ +. B \\$1\\$2\c . \} . el \{\ -. br -. ns +. \" If (invalidly) given no arguments, do as little as possible. +. \" Set these registers for subsequent `YS` use. +. nr mA \\n(.j +. nr mI \\n(.i . \} -. -. nr mT \w'\fB\\$1\fP\ ' -. HP \\n(mTu -. rr mT -. B "\\$1" .. . . -.\" End of command synopsis. Restores adjustment. +.\" End of command synopsis. .de YS . in \\n(mIu . ad \\n(mA . hy \\n(mH -. rr mA -. rr mI -. nr mS 0 +. +. if !\\n(.$ \{\ +. rr mA +. rr mI +. nr mS 0 +. rr mT +. \} .. . . diff --git a/tmac/groff_man.7.man.in b/tmac/groff_man.7.man.in index f8488c6b0..5f31d95b3 100644 --- a/tmac/groff_man.7.man.in +++ b/tmac/groff_man.7.man.in @@ -61,7 +61,7 @@ .SH Name .\" Legal Terms .\" ==================================================================== .\" -.\" Copyright (C) 1999-2023 Free Software Foundation, Inc. +.\" Copyright (C) 1999-2024 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 @@ -106,6 +106,7 @@ .SH Synopsis .SY "groff \-man" .RI [ option\~ .\|.\|.\&] .RI [ file\~ .\|.\|.] +.YS . .SY "groff \-m man" .RI [ option\~ .\|.\|.\&] @@ -181,13 +182,13 @@ .SH Description \&.SH Section heading Document structure macros \&.SM Small Font style macros \&.SS Subsection heading Document structure macros -\&.SY Synopsis start Command synopsis macros +\&.SY Synopsis start Synopsis macros \&.TH Title heading Document structure macros \&.TP Tagged paragraph Paragraphing macros \&.TQ Supplemental paragraph tag Paragraphing macros \&.UE URI end Hyperlink macros \&.UR URI start Hyperlink macros -\&.YS Synopsis end Command synopsis macros +\&.YS Synopsis end Synopsis macros .TE . . @@ -994,7 +995,7 @@ .SS "Paragraphing macros" . _endif()dnl .\" ==================================================================== -.SS "Command synopsis macros" +.SS "Synopsis macros" .\" ==================================================================== . Use @@ -1003,8 +1004,6 @@ .SS "Command synopsis macros" .B .YS to summarize syntax using familiar Unix conventions. . -These macros break the output line. -. .\" TODO: Determine whether this (is still? was ever?) true. .\" Furthermore, .\" some tools are able to interpret these macros semantically and treat @@ -1034,54 +1033,69 @@ .SS "Command synopsis macros" . . .TP -.BI .SY\~ keyword +.BI .SY\~ keyword\~\c +.RI [ suffix ] Begin synopsis. . -A new paragraph begins as with -.BR .P , -unless +Adjustment and automatic hyphenation are disabled. +. +If .B .SY has already been called without a corresponding .BR .YS , -in which case only a break is performed. -. -Adjustment and automatic hyphenation are disabled. +a break is performed. . .I keyword -is set in bold. +and +.I suffix +(if any) +are set in bold. . -If a break is required, -lines after the first are indented by the width of +If a break is required in subsequent text +(up to another paragraphing +sectioning, +or synopsis macro call), +lines after the first are indented. +. +The indentation amount is the width of +.I keyword +plus a space, +if that is the only argument, +and by the sum of the widths of .I keyword -plus a space. +and +.I suffix +otherwise. . . .TP -.B .YS -End synopsis. -. -Indentation, +.BR .YS\~ [\c +.IR reuse-indentation ] +End synopsis, +breaking the line and restoring +indentation, adjustment, and hyphenation -are restored to their previous states. +to their previous states. +. +If an argument is given, +the indentation corresponding to the previous +.B SY +call is remembered and reused by the next +.B YS +call. _ifstyle()dnl . . .P -Multiple +Interleave multiple .BR .SY / .YS -blocks can be specified, -for instance to distinguish differing modes of operation of a complex -command like -.MR tar 1 ; -each will be vertically separated as paragraphs are. -. +blocks with paragraphing macros to distinguish differing modes of +operation of a complex command like +.MR tar 1 . . -.P -.B .SY -can be repeated before -.B .YS -to indicate synonymous ways of invoking a particular mode of operation. +Omit the paragraphing macro to indicate synonymous ways of invoking a +particular mode of operation. . . .P @@ -1110,6 +1124,7 @@ .SS "Command synopsis macros" \&.YS \&. \&. +\&.P \&.SY groff \&.B \e\-h \&.YS @@ -1119,10 +1134,12 @@ .SS "Command synopsis macros" \&.YS \&. \&. +\&.P \&.SY groff \&.B \e\-v \&.RI [ option\e\(ti .\e|.\e|.\e&] \&.RI [ file\e\(ti .\e|.\e|.] +\&.YS \&. \&.SY groff \&.B \e\-\e\-version @@ -1136,6 +1153,7 @@ .SS "Command synopsis macros" produces the following output. . . +.P .RS .SY groff .RB [ \-abcCeEgGijklNpRsStUVXzZ ] @@ -1181,18 +1199,22 @@ .SS "Command synopsis macros" .YS . . +.P .SY groff .B \-h +.YS . .SY groff .B \-\-help .YS . . +.P .SY groff .B \-v .RI [ option\~ .\|.\|.\&] .RI [ file\~ .\|.\|.] +.YS . .SY groff .B \%\-\-version @@ -1275,6 +1297,62 @@ .SS "Command synopsis macros" and causing additional inter-sentence space to be placed after it. . See subsection \(lqPortability\(rq below. +. +. +.P +We might synopsize the standard C library function +.MR bsearch 3 +as follows. +. +. +.P +.RS +.EX +\&.P +\&.B void *\(rsc +\&.SY bsearch ( +\&.BI const\(rs\(tivoid\(rs\(ti*\(rs\(ti key , +\&.BI const\(rs\(tivoid\(rs\(ti*\(rs\(ti base , +\&.BI size_t\(rs\(ti nmemb , +\&.BI int\(rs\(ti(* compar )\(rsc +\&.B (const\(rs\(tivoid\(rs\(ti*, const\(rs\(tivoid\(rs\(ti*)); +\&.YS +.EE +.RE +. +. +.P +.I man +produces the following result. +. +. +.RS +.P +.B void *\c +.SY bsearch ( +.BI const\~void\~*\~ key , +.BI const\~void\~*\~ base , +.BI size_t\~ nmemb , +.BI int\~(* compar )\c +.B (const\~void\~*, const\~void\~*)); +.YS +.RE +. +. +.P +If you are presenting several synopses, +and want the indentation of their non-initial lines to align with that +of the first synopsis, +give each +.B YS +call an argument. +. +Leaving the argument off the last +.B YS +call ends the synopsis context; +the indentation of the next +.B YS +call will be computed anew. _endif()dnl . . @@ -4290,7 +4368,7 @@ .SH Notes . .IP Examples of ellipsis usage are shown above, -in subsection \[lq]Command synopsis macros\[rq]. +in subsection \[lq]Synopsis macros\[rq]. . The idiomatic .I roff diff --git a/tmac/groff_me.7.man b/tmac/groff_me.7.man index eedcace9a..dc87080d0 100644 --- a/tmac/groff_me.7.man +++ b/tmac/groff_me.7.man @@ -75,6 +75,7 @@ .SH Synopsis .SY "groff \-me" .RI [ option\~ .\|.\|.\&] .RI [ file\~ .\|.\|.] +.YS . .SY "groff \-m me" .RI [ option\~ .\|.\|.\&] diff --git a/tmac/groff_ms.7.man b/tmac/groff_ms.7.man index 6b89eb25b..39520cfba 100644 --- a/tmac/groff_ms.7.man +++ b/tmac/groff_ms.7.man @@ -55,6 +55,7 @@ .SH Synopsis .SY "groff \-m@TMAC_S_PREFIX@s" .RI [ option\~ .\|.\|.\&] .RI [ file\~ .\|.\|.] +.YS . .SY "groff \-m m@TMAC_S_PREFIX@s" .RI [ option\~ .\|.\|.\&] diff --git a/tmac/tests/an-ext_SY-and-YS-work.sh b/tmac/tests/an-ext_SY-and-YS-work.sh index 3ddc7d727..54c334539 100755 --- a/tmac/tests/an-ext_SY-and-YS-work.sh +++ b/tmac/tests/an-ext_SY-and-YS-work.sh @@ -37,14 +37,20 @@ foo \\- a command with a very short name This pre-synopsis text is not often used in practice. . . +.P .SY foo .I "operand1 operand2 operand3 operand4 operand5 operand6 operand6" .I "operand7 operand8 operand9" .YS . . -.SY "foo \\-h" -.SY "foo \\-\\-help" +.P +.SY foo +.B \\-h +.YS +. +.SY foo +.B \\-\\-help .YS . This post-synopsis text is not often used in practice.