]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/music.cc
* lily/include/music.hh (class Music): unvirtualize transpose().
[lilypond.git] / lily / music.cc
index edaed5e3f3abf1670fab5f6f90bccdc5fa924a21..958eedc221bcb1092a3161709c5678b8c12fdf30 100644 (file)
@@ -171,11 +171,17 @@ Music::compress (Moment factor)
     m->compress (factor);
 
   compress_music_list (get_property ("elements"), factor);
+  Duration *d =  unsmob_duration (get_property ("duration"));
+  if (d)
+    set_property ("duration", d ->compressed (factor.main_part_).smobbed_copy ());
 }
 
 void
 Music::transpose (Pitch delta)
 {
+  if (to_boolean (get_property ("untransposable")))
+    return ;
+  
   for (SCM s = this->get_property_alist (true); scm_is_pair (s); s = scm_cdr (s))
     {
       SCM entry = scm_car (s);
@@ -188,7 +194,7 @@ Music::transpose (Pitch delta)
 
          if (abs (transposed.get_alteration ()) > DOUBLE_SHARP)
            {
-             warning (_f ("Transposition by %s makes alteration larger than two",
+             warning (_f ("Transposition by %s makes alteration larger than double",
                           delta.to_string ()));
            }
        }