diff options
author | wl <wl> | 2006-03-28 12:32:04 +0000 |
---|---|---|
committer | wl <wl> | 2006-03-28 12:32:04 +0000 |
commit | 48aec1f008daad2e1e285defd2e4b536c3d15379 (patch) | |
tree | 50ffcfd2d298b85d39886390d9560e9f845c8204 | |
parent | 3aa1d693c86f4772c4219d51bc41f33a867e68ae (diff) | |
download | groff-48aec1f008daad2e1e285defd2e4b536c3d15379.tar.gz |
. Hardwire first four font positions with R, I, B, and BI -- the
documentation explicitly refers to this feature (cf. the `HF'
string register).
. Don't use `%' register in numeric calculations because it is
affected by `.af'.
Patches for both problems have been contributed by Nick Stoughton
<nick@usenix.org>.
* m.tmac: s/@language/@country/.
s/\n[%]/\n[P]/ where appropriate.
s/\fR/\f1/.
s/.ft R/.ft 1/.
s/\fI/\f2/.
s/.ft I/.ft 2/.
s/\fB/\f3/.
s/.ft B/.ft 3/.
* mse.tmac: s/@language/@country/.
* groff_mm.man (Fonts): New subsection.
* groff_mmse.man: Load `sv.tmac'.
Reformatted.
examples/README: Cleanups and updates.
-rw-r--r-- | contrib/mm/ChangeLog | 30 | ||||
-rw-r--r-- | contrib/mm/examples/README | 35 | ||||
-rw-r--r-- | contrib/mm/groff_mm.man | 34 | ||||
-rw-r--r-- | contrib/mm/groff_mmse.man | 97 | ||||
-rw-r--r-- | contrib/mm/m.tmac | 54 | ||||
-rw-r--r-- | contrib/mm/mse.tmac | 9 |
6 files changed, 184 insertions, 75 deletions
diff --git a/contrib/mm/ChangeLog b/contrib/mm/ChangeLog index 6a00e9b9..0ae431b8 100644 --- a/contrib/mm/ChangeLog +++ b/contrib/mm/ChangeLog @@ -1,3 +1,33 @@ +Tue Mar 28 14:00:06 2006 Werner LEMBERG <wl@gnu.org> + + . Hardwire first four font positions with R, I, B, and BI -- the + documentation explicitly refers to this feature (cf. the `HF' + string register). + + . Don't use `%' register in numeric calculations because it is + affected by `.af'. + + Patches for both problems have been contributed by Nick Stoughton + <nick@usenix.org>. + + * m.tmac: s/@language/@country/. + s/\n[%]/\n[P]/ where appropriate. + s/\fR/\f1/. + s/.ft R/.ft 1/. + s/\fI/\f2/. + s/.ft I/.ft 2/. + s/\fB/\f3/. + s/.ft B/.ft 3/. + + * mse.tmac: s/@language/@country/. + + * groff_mm.man (Fonts): New subsection. + + * groff_mmse.man: Load `sv.tmac'. + Reformatted. + + examples/README: Cleanups and updates. + Mon Mar 27 15:44:24 2006 Werner LEMBERG <wl@gnu.org> * groff_mm.man: Completely revised and reformatted to use as many diff --git a/contrib/mm/examples/README b/contrib/mm/examples/README index 833b82b5..f45e1b7e 100644 --- a/contrib/mm/examples/README +++ b/contrib/mm/examples/README @@ -1,32 +1,33 @@ This directory contains examples of my enhancements to MM. -APP The appendix macro -B1B2 Box macro with text +APP The appendix macro. +B1B2 Box macro with text. COVER My general cover macro, this example is using ms.cov. -IND A general indexing method, see manual for INITI -LT The letter macro -LT.se A swedish example with the extra - swedish macros for getting a letter conforming - to swedish standard letter, both left and right adjusted. -ML Marked list, an extended list type +IND A general indexing method, see manual for INITI. +LT The letter macro. +LT.se A Swedish example with the extra + Swedish macros for getting a letter conforming + to Swedish standard letter, both left and right adjusted. +ML Marked list, an extended list type. MOVE The MOVE macro, how to begin to print on an exact position. MUL Enhanced multicolumn mode. NCOL Start on next column. (Not for MUL*) -ND New date, with iso date example -References How to use references -SETR General reference system, see manual for INITR +ND New date, with ISO date example. +References How to use references. +SETR General reference system, see manual for INITR. Examples that I should have: -PIC How to include postscript pictures, see manual for PIC -VERBON Begin verbatim output +PIC How to include postscript pictures, see manual for PIC. +VERBON Begin verbatim output. And remember, check the manual for all string and number registers, -I've made shure that mgm will be useful in several languages -and all english output can be redefined. -Check the manual for groff_mse (swedish format) and the -macro file, mse.tmac. +I've made sure that mgm is useful in several languages; +all English output can be redefined. + +For Swedish localization, check the manual for groff_mse and the +macro files `mse.tmac' and `sv.tmac'. diff --git a/contrib/mm/groff_mm.man b/contrib/mm/groff_mm.man index 6f713594..3174438f 100644 --- a/contrib/mm/groff_mm.man +++ b/contrib/mm/groff_mm.man @@ -1,5 +1,5 @@ .\" -.\" $Id: groff_mm.man,v 2.16 2006/03/27 13:49:31 wl Exp $ +.\" $Id: groff_mm.man,v 2.17 2006/03/28 12:32:04 wl Exp $ .\" .de T2 . vpt 0 @@ -73,7 +73,7 @@ which is the ISO 3166 two-letter code for the A file called .B locale or -.IB lang _locale +.IB country _locale is read after the initialization of the global variables. It is therefore possible to localize the macros with a different company name and so on. @@ -167,6 +167,36 @@ Set the format with .RE . . +.SS Fonts +. +In +.BR m@TMAC_M_PREFIX@m , +the fonts (or rather, font styles) +.B R\c +\~(normal), +.B I\c +\~(italic), and +.B B\c +\~(bold) are hardwired to font positions +.BR 1 , +.BR 2 , +and\~\c +.BR 3 , +respectively. +Internally, font positions are used for backwards compatibility. +From a practical point of view it doesn't make a big difference \[en] +a different font family can still be selected with a call to the +.B .fam +request or using +.BR groff 's +.B \-f +command line option. +On the other hand, if you want to replace just, say, font +.BR B , +you have to replace the font at position\~2 (with a call to +`.fp\~2\~.\|.\|.'). +. +. .SS Macros . .TP diff --git a/contrib/mm/groff_mmse.man b/contrib/mm/groff_mmse.man index 5ec182b9..5d00b658 100644 --- a/contrib/mm/groff_mmse.man +++ b/contrib/mm/groff_mmse.man @@ -1,78 +1,124 @@ .\" -.\" $Id: groff_mmse.man,v 2.3 2006/03/03 08:20:03 wl Exp $ +.\" $Id: groff_mmse.man,v 2.4 2006/03/28 12:32:04 wl Exp $ .\" Skrivet av Jörgen Hägg, Lund, Sverige .\" +. +.mso sv.tmac +. .TH GROFF_MMSE @MAN7EXT@ "@MDATE@" "Groff Version @VERSION@" +. +. .SH NAMN +. groff_mmse \- svenska mm makro för groff +. +. .SH SYNTAX +. .B groff .B \-m@TMAC_M_PREFIX@mse [ -.IR flaggor .\|.\|. +.IR flaggor .\|.\|.\& ] [ -.IR filer .\|.\|. +.IR filer .\|.\|.\& ] +. +. .SH BESKRIVNING -\fBm@TMAC_M_PREFIX@mse\fP är en svensk variant av \fBm@TMAC_M_PREFIX@m\fP. Alla texter -är översatta. En A4 sida får text som är 13 cm bred, 3.5 cm indragning -samt är 28.5 cm hög. +. +.B m@TMAC_M_PREFIX@mse +är en svensk variant av +.BR m@TMAC_M_PREFIX@m . +Alla texter är översatta. +En A4 sida får text som är 13\~cm bred, +3.5\~cm indragning samt är 28.5\~cm hög. Det finns stöd för brevuppställning enligt svensk standard för vänster och högerjusterad text. +. .LP -\fBCOVER\fP kan använda \fIse_ms\fP som argument. Detta ger ett -svenskt försättsblad. -Se \fBgroff_mm(@MAN7EXT@)\fP för övriga detaljer. +.B COVER +kan använda +.I se_ms +som argument. +Detta ger ett svenskt försättsblad. +Se +.BR groff_mm (@MAN7EXT@) +för övriga detaljer. +. +. .SH BREV +. Tillgängliga brevtyper: +. .TP .B ".LT SVV" Vänsterställd löptext med adressat i position T0 (vänsterställt). +. .TP .B ".LT SVH" Högerställd löptext med adressat i position T4 (passar fönsterkuvert). +. .LP Följande extra LO-variabler används. +. .TP -.B ".LO DNAMN\fI namn\fP" +.BI ".LO DNAMN\ " namn Anger dokumentets namn. +. .TP -.br -.B ".LO MDAT\fI datum\fP" -Mottagarens datum, anges under \fBErt datum:\fP (\fBLetMDAT\fP). +.BI ".LO MDAT\ " datum +Mottagarens datum, anges under +.B Ert datum: +.RB ( LetMDAT ). +. .TP -.br -.B ".LO BIL\fI sträng\fP" -Anger bilaga, nummer eller sträng med \fBBilaga\fP (\fBLetBIL\fP) +.BI ".LO BIL\ " sträng +Anger bilaga, nummer eller sträng med +.B Bilaga +.RB ( LetBIL ) som prefix. +. .TP -.br -.B ".LO KOMP\fI text\fP" +.BI ".LO KOMP\ " text Anger kompletteringsuppgift. +. .TP -.br -.B ".LO DBET\fI beteckning\fP" +.BI ".LO DBET\ " beteckning Anger dokumentbeteckning eller dokumentnummer. +. .TP -.br -.B ".LO BET\fI beteckning\fP" +.BI ".LO BET\ " beteckning Anger beteckning (ärendebeteckning i form av diarienummer eller liknande). +. .TP -.br -.B ".LO SIDOR\fI antal\fP" +.BI ".LO SIDOR\ " antal Anger totala antalet sidor och skrivs ut efter sidnumret inom parenteser. +. .LP -Om makrot \fB.TP\fP är definierat anropas det efter utskrift av brevhuvudet. +Om makrot +.B .TP +är definierat anropas det efter utskrift av brevhuvudet. Där lägger man lämpligen in postadress och annat som brevfot. +. +. .SH "SKRIVET AV" +. Jörgen Hägg, Lund, Sweden <Jorgen.Hagg@axis.se> +. +. .SH FILER +. +.TP .B @MACRODIR@/@TMAC_M_PREFIX@mse.tmac +.TP .B @TMAC_MDIR@/se_*.cov +. +. .SH "SE OCKSÅ" +. .BR groff (@MAN1EXT@), .BR @g@troff (@MAN1EXT@), .BR @g@tbl (@MAN1EXT@), @@ -82,5 +128,6 @@ Jörgen Hägg, Lund, Sweden <Jorgen.Hagg@axis.se> .BR groff_mm (@MAN7EXT@) . .\" Local Variables: +.\" coding: latin-1 .\" mode: nroff .\" End: diff --git a/contrib/mm/m.tmac b/contrib/mm/m.tmac index c0d1a0e3..da97db19 100644 --- a/contrib/mm/m.tmac +++ b/contrib/mm/m.tmac @@ -3,11 +3,11 @@ .ds RE \\$2 .. .\" -.\" $Id: m.tmac,v 2.28 2006/03/03 08:20:03 wl Exp $ -.@revision $Revision: 2.28 $ +.\" $Id: m.tmac,v 2.29 2006/03/28 12:32:04 wl Exp $ +.@revision $Revision: 2.29 $ .ig -Copyright (C) 1991-2000, 2001, 2002, 2003, 2004, 2005 +Copyright (C) 1991-2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. mgm is written by Jörgen Hägg <jh@axis.com> @@ -150,7 +150,7 @@ Index array!index .\" Internal global variables .\" .\" This is for cover macro .MT -.\" .ds @language +.\" .ds @country .\" .nr @copy_type 0 .if r C .nr @copy_type \n[C] @@ -361,7 +361,7 @@ Index array!index .\" .\"--------------------------------------------- .\" set local variables. -.ie d @language .mso mm/\*[@language]_locale +.ie d @country .mso mm/\*[@country]_locale .el .mso mm/locale .\"--------------------------------------------- .if \n[D] .tm Groff mm, version \*[RE]. @@ -1233,7 +1233,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] . ie d TP .TP . el \{\ ' sp 3 -. ie ((\\n[%]=1)&((\\n[N]=1):(\\n[N]=2))) .sp +. ie ((\\n[P]=1)&((\\n[N]=1):(\\n[N]=2))) .sp . el .tl \\*[pg*header] . ie o .tl \\*[pg*odd-header] . el .tl \\*[pg*even-header] @@ -1307,7 +1307,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .el \{\ . ie o .tl \\*[pg*odd-footer] . el .tl \\*[pg*even-footer] -. ie (\\n[%]=1)&(\\n[N]=1) .tl \\*[pg*header] +. ie (\\n[P]=1)&(\\n[N]=1) .tl \\*[pg*header] . el .tl \\*[pg*footer] . tl ''\\*[Pg_type!\\n[@copy_type]]'' .\} @@ -2593,7 +2593,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] . ti 0 .\} .el .ce 1 -\fB\\$1\fP\\$2 +\f3\\$1\fP\\$2 .br .ev .\" save line for LIST OF XXX, wth is the width of the label @@ -2616,11 +2616,11 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] \!.ie (\w@\\$1\\$2@)>(\\\\n[.l]-\\\\n[.i]) \{\ . in +\w@\\$1@u \!. ti 0 -\!\fB\\$1\fP\\$2 +\!\f3\\$1\fP\\$2 \!.\} \!.el \{\ . ce 1 -\!\fB\\$1\fP\\$2 +\!\f3\\$1\fP\\$2 \!.\} \!.br \!.ev @@ -2680,7 +2680,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .\"########################### module fnt ############################ .\" some font macros. .de R -.ft R +.ft 1 .ul 0 .. .\"----------- @@ -2699,30 +2699,30 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .. .\"----------- .de B -.ie \\n[.$] .fnt@switch \fB \f[\\n[.f]] \\$@ -.el .ft B +.ie \\n[.$] .fnt@switch \f3 \f[\\n[.f]] \\$@ +.el .ft 3 .. .de I -.ie \\n[.$] .fnt@switch \fI \f[\\n[.f]] \\$@ -.el .ft I +.ie \\n[.$] .fnt@switch \f2 \f[\\n[.f]] \\$@ +.el .ft 2 .. .de IB -.if \\n[.$] .fnt@switch \fI \fB \\$@ +.if \\n[.$] .fnt@switch \f2 \f3 \\$@ .. .de BI -.if \\n[.$] .fnt@switch \fB \fI \\$@ +.if \\n[.$] .fnt@switch \f3 \f2 \\$@ .. .de IR -.if \\n[.$] .fnt@switch \fI \fR \\$@ +.if \\n[.$] .fnt@switch \f2 \f1 \\$@ .. .de RI -.if \\n[.$] .fnt@switch \fR \fI \\$@ +.if \\n[.$] .fnt@switch \f1 \f2 \\$@ .. .de RB -.if \\n[.$] .fnt@switch \fR \fB \\$@ +.if \\n[.$] .fnt@switch \f1 \f3 \\$@ .. .de BR -.if \\n[.$] .fnt@switch \fB \fR \\$@ +.if \\n[.$] .fnt@switch \f3 \f1 \\$@ .. .\"########################### module box ############################ .\" draw a box around some text. Text will be kept on the same page. @@ -2846,7 +2846,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .de ref@print-refs .toc@save 1 "" "\\*[Rp]" \\n[%] .ce -\fI\\*[Rp]\fP +\f2\\*[Rp]\fP .sp .nr ref*ll \\n[.l] .misc@ev-keep ref*ev @@ -2916,15 +2916,15 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .toc@save 1 "" "\\*[App] \\$1: \\$2" \\n[%] .. .\"------------ -.\" app@heaer name text +.\" app@header name text .de app@header .bp .SP (u;\\n[Lsp]*4) .ce 1 -\s+4\fB\\*[App]\ \\$1\fP\s0 +\s+4\f3\\*[App]\ \\$1\fP\s0 .SP (u;\\n[Lsp]*2) .if \w@\\$2@<\\n[.l] .ce 1 -\fB\s+2\\$2\s0\fP +\f3\s+2\\$2\s0\fP .SP (u;\\n[Lsp]*4) .. .als APPX app@header @@ -3052,7 +3052,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .el .ds cov*mt-type 1 .ds cov*mt-addresse "\\$2 .ds cov*mt-type-text "\\$1 -.ie d @language .ds cov*str mm/\\*[@language]_ +.ie d @country .ds cov*str mm/\\*[@country]_ .el .ds cov*str mm/ .mso \\*[cov*str]\\*[cov*mt-file!\\*[cov*mt-type]] .. @@ -3060,7 +3060,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .ie !\\n[.$] .ds cov*cov-type ms .el .ds cov*cov-type \\$1 .pg@disable-top-trap -.ie d @language .ds cov*str mm/\\*[@language]_\\*[cov*cov-type].cov +.ie d @country .ds cov*str mm/\\*[@country]_\\*[cov*cov-type].cov .el .ds cov*str mm/\\*[cov*cov-type].cov .mso \\*[cov*str] .. diff --git a/contrib/mm/mse.tmac b/contrib/mm/mse.tmac index 123c47d1..35041947 100644 --- a/contrib/mm/mse.tmac +++ b/contrib/mm/mse.tmac @@ -1,11 +1,12 @@ -.\" $Id: mse.tmac,v 2.2 2006/03/03 08:20:03 wl Exp $ +.\" $Id: mse.tmac,v 2.3 2006/03/28 12:32:04 wl Exp $ +.\" +.\" Swedish version of mm .\" -.\" swedish version of mm .\" See m.tmac for version-information. -.ds @language se +.ds @country se . .mso m.tmac -.\" The two-letter code for Sweden is `sv', not `se' (this is Northern Sami) +.\" The two-letter code for Swedish is `sv', not `se' (this is Northern Sami) .mso sv.tmac . .ISODATE |