]> git.donarmstrong.com Git - lilypond.git/commitdiff
Fix issue 1376.
authorFelipe Gonçalves Assis <felipegassis@gmail.com>
Tue, 28 Dec 2010 04:48:21 +0000 (01:48 -0300)
committerGraham Percival <graham@percival-music.ca>
Mon, 24 Jan 2011 15:05:43 +0000 (15:05 +0000)
When an ambitus consists of a single note with different alterations,
two accidentals should be printed, no matter the key signature.

lily/ambitus-engraver.cc

index d4bc39e7283c2cd9ebcb34944635f1c0cf0a6a76..221c1e8881ee950c70da5af60b29f202236d30ef 100644 (file)
@@ -178,7 +178,11 @@ Ambitus_engraver::finalize ()
            ? robust_scm2rational (scm_cdr (handle), Rational (0))
            : Rational (0);
 
-         if (sig_alter == p.get_alteration ())
+         const Pitch other = pitch_interval_[-d];
+
+         if (sig_alter == p.get_alteration ()
+             && !((p.steps () == other.steps ())
+                  && (p.get_alteration () != other.get_alteration ())))
            {
              accidentals_[d]->suicide ();
              heads_[d]->set_object ("accidental-grob", SCM_EOL);