From: Werner Lemberg Date: Tue, 25 Jan 2005 01:33:00 +0000 (+0000) Subject: * mf/feta-autometric.mf (fet_beginfont): Set font_coding_scheme X-Git-Tag: release/2.5.14~223 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=32bc5ac1c42ea0beca27fc62d8ac6c0dc74bba12;p=lilypond.git * mf/feta-autometric.mf (fet_beginfont): Set font_coding_scheme to `asis'. (fet_begingroup): Save group name in string `feta_group'. (fet_endgroup): Updated. (fet_beginchar): Emit `glyph_name' special for mf2pt1. * mf/feta-bolletjes.mf: s/p/pat/ for paths. * mf/feta-pendaal.mf ("Pedal asterisk"): Add workaround for bug in metapost. --- diff --git a/ChangeLog b/ChangeLog index 5fe21675a2..074c32c159 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,16 @@ +2005-01-24 Werner Lemberg + + * mf/feta-autometric.mf (fet_beginfont): Set font_coding_scheme + to `asis'. + (fet_begingroup): Save group name in string `feta_group'. + (fet_endgroup): Updated. + (fet_beginchar): Emit `glyph_name' special for mf2pt1. + + * mf/feta-bolletjes.mf: s/p/pat/ for paths. + + * mf/feta-pendaal.mf ("Pedal asterisk"): Add workaround for bug + in metapost. + 2005-01-24 Graham Percival * Documentation/user/notation.itely: really minor editing. diff --git a/mf/feta-autometric.mf b/mf/feta-autometric.mf index 77b551e30c..1c138535a8 100644 --- a/mf/feta-autometric.mf +++ b/mf/feta-autometric.mf @@ -23,7 +23,7 @@ message ""; def fet_beginfont (expr name, size, encod) = font_identifier := name & decimal size; font_size size; - font_coding_scheme encod; + font_coding_scheme "asis"; message "@{font@:GNU@:LilyPond@:" & name & "@:" & decimal size & "@:" & encod @@ -39,18 +39,23 @@ enddef; % group or table? def fet_begingroup (expr name) = - message "@{group@:" & name +begingroup; + save feta_group; + string feta_group; + + feta_group := name; + + message "@{group@:" & feta_group & "@}"; message ""; -begingroup enddef; def fet_endgroup (expr name) = -endgroup; message "@{puorg@:" & name & "@}"; message ""; +endgroup; enddef; @@ -163,7 +168,7 @@ enddef; def no_dimen_beginchar (expr c) = -begingroup +begingroup; charcode := if known c: byte c else: 0; fi; charic := 0; clearxy; @@ -196,6 +201,11 @@ def fet_beginchar (expr name, id_lit) = charnamestr := name; idstr := id_lit; + % addition for mf2pt1 + if known bp_per_pixel: + special "% MF2PT1: glyph_name " & feta_group & "." & idstr; + fi; + no_dimen_beginchar (incr code) name; enddef; @@ -223,7 +233,7 @@ def breapth_endchar = chardx := (w + b); % what the heck is chardx shipit; -endgroup +endgroup; enddef; diff --git a/mf/feta-bolletjes.mf b/mf/feta-bolletjes.mf index d082c8cc2e..b7852cc657 100644 --- a/mf/feta-bolletjes.mf +++ b/mf/feta-bolletjes.mf @@ -61,19 +61,19 @@ define_whole_vertical_pixels (noteheight); def draw_outside_ellipse (expr ellipticity, tilt, superness, slant) = save attachment_y; - save p; - path p; + save pat; + path pat; - p := superellipse ((ellipticity, 0), (-slant * ellipticity, 1.0), - (-ellipticity, 0), (slant * ellipticity, -1.0), - superness); - p := p rotated tilt; + pat := superellipse ((ellipticity, 0), (-slant * ellipticity, 1.0), + (-ellipticity, 0), (slant * ellipticity, -1.0), + superness); + pat := pat rotated tilt; save top_point, right_point; pair top_point, right_point; - top_point := directionpoint left of p; - right_point := directionpoint up of p; + top_point := directionpoint left of pat; + right_point := directionpoint up of pat; save scaling, width; @@ -89,45 +89,45 @@ def draw_outside_ellipse (expr ellipticity, tilt, superness, slant) = charwy := ypart (right_point) * scaling#; charwx := width#; - p := p scaled scaling shifted (w / 2, .5 (h - d)); + pat := pat scaled scaling shifted (w / 2, .5 (h - d)); width := hround width; if test_outlines = 1: - draw p; + draw pat; else: - fill p; + fill pat; fi; enddef; def undraw_inside_ellipse (expr ellipticity, tilt, superness, clearance) = begingroup - save p; - path p; + save pat; + path pat; - p := superellipse ((ellipticity, 0), (0, 1.0), - (-ellipticity, 0), (0, -1.0), - superness); - p := p rotated tilt; + pat := superellipse ((ellipticity, 0), (0, 1.0), + (-ellipticity, 0), (0, -1.0), + superness); + pat := pat rotated tilt; save top_point, right_point; pair top_point, right_point; - top_point := directionpoint left of p; - right_point := directionpoint up of p; + top_point := directionpoint left of pat; + right_point := directionpoint up of pat; save height, scaling; height# = staff_space# + stafflinethickness# - clearance; scaling# = height# / (2 ypart (top_point)); define_pixels (scaling); - p := (p scaled scaling) shifted (w / 2, .5 (h - d)); + pat := pat scaled scaling shifted (w / 2, .5 (h - d)); if test_outlines = 1: - draw p; + draw pat; else: - unfill p; + unfill pat; fi endgroup; enddef; diff --git a/mf/feta-pendaal.mf b/mf/feta-pendaal.mf index af8e842b46..dfd87fa8cb 100644 --- a/mf/feta-pendaal.mf +++ b/mf/feta-pendaal.mf @@ -78,7 +78,19 @@ fet_beginchar ("Pedal asterisk", "*"); pat := pat .. cycle; - fill pat; + + % Uh, oh, there is a bug in metapost 0.641 which makes mf2pt1.mp's + % redefinion of `fill' fail for this particular path, using a + % wrong path orientation. + % + % Note that using `unfill' here makes the direct mpost output + % wrong, but the `mf2pt1' script fixes it for the Type 1 output. + + if known bp_per_pixel: + unfill pat; + else: + fill pat; + fi; pickup pencircle scaled (7/8 inner_r);