From: Mats Bengtsson Date: Tue, 16 Feb 1999 23:27:44 +0000 (+0100) Subject: patch::: 1.1.30.mb1: Re: LilyPond 1.1.30 X-Git-Tag: release/1.1.31~1 X-Git-Url: https://git.donarmstrong.com/lilypond.git?a=commitdiff_plain;h=1f72695816f79df61958fc3649591fbf6b95a05a;p=lilypond.git patch::: 1.1.30.mb1: Re: LilyPond 1.1.30 pl 30.mb1 - Added support for magnification of TeX fonts ==> larger dynamics in 20pt scores. (Doesn't work in Postscript) --- Generated by (address unknown) using package-diff 0.62, >From = lilypond-1.1.30, To = lilypond-1.1.30.mb1 usage cd lilypond-source-dir; patch -E -p1 < lilypond-1.1.30.mb1.diff Patches do not contain automatically generated files or (urg) empty directories, i.e., you should rerun autoconf, configure and possibly make outdirs. --state 1.1.30 1.1.30.mb1 ++state --- diff --git a/NEWS b/NEWS index beb6a48c3c..e9700f9f65 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,13 @@ -pl 30.jcn1 +--- ../lilypond-1.1.30/NEWS Mon Feb 15 15:43:56 1999 +++ b/NEWS Wed Feb 17 00:10:16 1999 +@@ -1,3 +1,7 @@ +pl 30.mb1 + - Added support for magnification of TeX fonts ==> + larger dynamics in 20pt scores. (Doesn't work in Postscript) + + pl 30 (feb 15) + + pl 29.uu1pl 30.jcn1 - sm fixes, intl/ fixes pl 30 (feb 15) diff --git a/VERSION b/VERSION index 3d2c602782..ef473575fa 100644 --- a/VERSION +++ b/VERSION @@ -2,7 +2,7 @@ PACKAGE_NAME=LilyPond MAJOR_VERSION=1 MINOR_VERSION=1 PATCH_LEVEL=30 -MY_PATCH_LEVEL=jcn1 +MY_PATCH_LEVEL=mb1 # use the above to send patches: MY_PATCH_LEVEL is always empty for a # released version. diff --git a/lily/lookup.cc b/lily/lookup.cc index dcbafb3975..f873b92097 100644 --- a/lily/lookup.cc +++ b/lily/lookup.cc @@ -394,6 +394,9 @@ static Dict_initialiser cmr_init[] = { {0,0} }; +// Magic numbers from Knuths plain.tex: +static Real mag_steps[] = {1, 1, 1.200, 1.440, 1.7280, 2.074, 2.488}; + static Dictionary cmr_dict (cmr_init); Molecule @@ -401,13 +404,18 @@ Lookup::text (String style, String text) const { Molecule m; - + int font_mag = 1; Real font_h = paper_l_->get_var ("font_normal"); if (paper_l_->scope_p_->elem_b ("font_" + style)) { font_h = paper_l_->get_var ("font_" + style); } + if (paper_l_->scope_p_->elem_b ("magnification_" + style)) + { + font_mag = (int)paper_l_->get_var ("magnification_" + style); + } + if (cmr_dict.elem_b (style)) { style = String (cmr_dict [style]) + to_str ((int)font_h); // ugh @@ -432,6 +440,13 @@ Lookup::text (String style, String text) const } } + if (font_mag > 1 && font_mag < 7 ) + { + style = style + String(" scaled \\magstep ") + to_str (font_mag); + w *= mag_steps[font_mag]; + ydims *= mag_steps[font_mag]; + } + DOUT << "\n" << to_str (w) << "\n"; m.dim_.x () = Interval (0, w); m.dim_.y () = ydims; diff --git a/ly/paper20.ly b/ly/paper20.ly index 61f5951ed9..f26068d0e6 100644 --- a/ly/paper20.ly +++ b/ly/paper20.ly @@ -19,7 +19,9 @@ paper_twenty = \paper { "font_number-1" = 8.; %"font_number" = 10.; "font_number+1" = 12.; - + + % Ugh + magnification_dynamic = 2.; % ugh see table20 for sizes quartwidth = 6.61\pt;