From 7a70c89c831329b450958952c0b64dd4596c1a5d Mon Sep 17 00:00:00 2001 From: fred Date: Tue, 26 Mar 2002 22:43:21 +0000 Subject: [PATCH] lilypond-1.3.5 --- lily/chord.cc | 45 +++++++++++---------------------------------- scm/chord-names.scm | 20 ++++---------------- scripts/ly2dvi.py | 2 +- 3 files changed, 16 insertions(+), 51 deletions(-) diff --git a/lily/chord.cc b/lily/chord.cc index 8dbc57a6c7..f6e1341d9e 100644 --- a/lily/chord.cc +++ b/lily/chord.cc @@ -494,9 +494,8 @@ Chord::pitch2molecule (Musical_pitch p) const Molecule mol = lookup_l ()->text ("", p.str ().left_str (1).upper_str (), paper_l ()); if (p.accidental_i_) - // urg, how to select the feta-1 font? mol.add_at_edge (X_AXIS, RIGHT, - lookup_l ()->accidental (p.accidental_i_, 0), 0); + paper_l ()->lookup_l (-2)->accidental (p.accidental_i_, 0), 0); return mol; } @@ -575,23 +574,11 @@ Chord::banter (Array pitch_arr, Chord_name* name_p) const int accidental = p.accidental_i_ - scale[(step - 1) % 7].accidental_i_; if ((step < 16) && (has[step] != -1)) has[step] = accidental == -1 ? -1 : 1; + // only from guile table ? if ((step == 3) && (accidental == -1)) { mod_str = "m"; } - /* - urg. - This routine gets a lot simpler, if we don't try to be catch - the 'dim' chords. However, we'll have to list every exceptional - 'dim' chord in scm: otherwise we'll get stuff like Cdim7-, iso - Cdim7, etc - */ -#ifdef SMART_DIM - else if ((step == 5) && (accidental == -1) && (has[3] == -1)) - { - mod_str = "dim"; - } -#endif else if (accidental || (!(step % 2) || ((i == add_arr.size () - 1) && (step > 5)))) @@ -603,26 +590,11 @@ Chord::banter (Array pitch_arr, Chord_name* name_p) const add_str += "maj7"; } else -#ifdef SMART_DIM { - if ((step % 2) && (accidental == -1) - && (has[3] == -1) && (has[5] == -1)) - { - if (i != add_arr.size () - 1) - sep_str = ""; - else - add_str += to_str (step); - } - else -#endif - { - add_str += to_str (step); - if (accidental) - add_str += accidental < 0 ? "-" : "+"; - } -#ifdef SMART_DIM + add_str += to_str (step); + if (accidental) + add_str += accidental < 0 ? "-" : "+"; } -#endif } } @@ -652,7 +624,12 @@ Chord::banter (Array pitch_arr, Chord_name* name_p) const } } - +/* + This routine tries to guess tonic in a possibly inversed chord, ie + should produce: C. + This is only used for chords that are entered as simultaneous notes, + chords entered in \chord mode are fully defined. + */ int Chord::find_tonic_i (Array const* pitch_arr_p) { diff --git a/scm/chord-names.scm b/scm/chord-names.scm index 597679a2cf..3329c144d6 100644 --- a/scm/chord-names.scm +++ b/scm/chord-names.scm @@ -12,22 +12,10 @@ ;((6 . 0) . ("H" "")) ;((6 . -1) . ("B" ("feta-1" . ""))) - ; urg, temp hack for accidental size: can't set from Chord:: - ((0 . 1) . ("C" ("feta-1" . ""))) - ((1 . 1) . ("D" ("feta-1" . ""))) - ((2 . 1) . ("E" ("feta-1" . ""))) - ((3 . 1) . ("F" ("feta-1" . ""))) - ((4 . 1) . ("G" ("feta-1" . ""))) - ((5 . 1) . ("A" ("feta-1" . ""))) - ((6 . 1) . ("B" ("feta-1" . ""))) - - ((0 . -1) . ("C" ("feta-1" . ""))) - ((1 . -1) . ("D" ("feta-1" . ""))) - ((2 . -1) . ("E" ("feta-1" . ""))) - ((3 . -1) . ("F" ("feta-1" . ""))) - ((4 . -1) . ("G" ("feta-1" . ""))) - ((5 . -1) . ("A" ("feta-1" . ""))) - ((6 . -1) . ("B" ("feta-1" . ""))) + ; C-p/C-r current feta chars for sharp/flat + ; don't use them: ly2dvi breaks (inputenc package) + ;((0 . 1) . ("C" ("feta-1" . ""))) + ;((0 . -1) . ("C" ("feta-1" . ""))) ) pitch-names-alist)) diff --git a/scripts/ly2dvi.py b/scripts/ly2dvi.py index d2ab97ae06..57702825d5 100644 --- a/scripts/ly2dvi.py +++ b/scripts/ly2dvi.py @@ -468,7 +468,7 @@ class Properties: t='' if os.environ.has_key ('MFINPUTS'): t = os.environ['MFINPUTS'] - os.environ['MFINPUTS'] = os.pathsep + t + \ + os.environ['MFINPUTS'] = t + os.pathsep + \ os.path.join(this.get('root'), 'mf') if os.environ.has_key('TMP'): -- 2.39.5