> file foo: > > .nr q 1 > .nr N 1 > .af q i > .ie (\n[q]=1)&(\n[N]=1) .tm Ho! > .el .tm boo > .fp 1 PR > .fp 2 PI > .fp 3 PB > .fp 4 PBI > .fp 5 CW > .fp 6 CI > .fp 7 CB > .fp 8 H > .fp 9 HB > .ds HF 3 3 3 4 4 4 3 > .BR bold roman > > groff -ww -mm foo > foo.ps > > bug.r:4: expected `;' after scale-indicator (got `=') > boo > bug.r:16: warning: can't find font `B' > bug.r:16: warning: can't find font `R' > > > This report highlights two problems with the mm macro package. The > first is an already reported troff problem if the number register > '%' is in a format other than '1'.
Will apply your related changes soon, thanks. > The second is that if fonts have been explictly loaded into certain > positions, they should be referred to by number not name. The patch you provide is problematic. In GNU troff, positions 1-4 are associated with font styles, not with real names. This makes it possible to change the base font very conveniently without touching a `standard' document which uses R, B, I, and BI (and S) and nothing else. (Do this with either the `.fam' request or with the -f command line option of groff.) In my opinion it is an abuse to select fonts directly with numeric positions. The very reason why .ft and \f accept numerical values is that number register .f (which gives the ID of the current font) returns a numerical value. With other words, if the mm macros use \f[B], the bold series of the current font family (as set with the .fam request) should be used. > The convention that has always been used is that > position 1 = R > position 2 = I > position 3 = B > position 4 = S This is not correct. The example DESC file for a PostScript printer given in the Troff User's Manual (CSTR 54), section 23, is as follows. position 1 = R position 2 = I position 3 = B position 4 = BI ... position 10 = S So we already have a good reason to use font names instead of font positions: Using `S' instead of `BI' on position 4 gives, well, funny results. I propose to install a modified .fp in the mm macros which calls .ftr (to translate the font name) if the user specifies a font position in the range 1-4. .als fp-old fp . .ds font1 R\" .ds font2 I\" .ds font3 B\" .ds font4 BI\" . .de fp . ie d font\\$1 \{\ . fp-old \\n[.fp] \\$2 \\$3 . ftr \\*[font\\$1] \\$2 . \} . el \ . fp-old \\$1 \\$2 \\$3 .. Comments? Werner _______________________________________________ Groff mailing list Groff@gnu.org http://lists.gnu.org/mailman/listinfo/groff