]> git.donarmstrong.com Git - lilypond.git/commitdiff
* lily/include/music.hh (class Music): unvirtualize transpose().
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 14 Jan 2005 17:15:40 +0000 (17:15 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 14 Jan 2005 17:15:40 +0000 (17:15 +0000)
* lily/sequential-music.cc: remove file.

* lily/include/music.hh (class Music): replace Music::start_mom()
by start-callback property

* lily/time-scaled-music.cc: remove file.

* lily/include/music.hh (class Music): include SCM init argument.
(class Music): replace Music::get_length() virtual by
length-callback property everywhere.

ChangeLog
lily/beam-quanting.cc
lily/include/music.hh
lily/include/untransposable-music.hh
lily/music.cc

index 4d85ffb9258ab3811b796d1669d815f9cfceacbd..cbabb55bb743f146b39763662979970a70829519 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,7 @@
 2005-01-14  Han-Wen Nienhuys  <hanwen@xs4all.nl>
 
+       * lily/include/music.hh (class Music): unvirtualize transpose().
+
        * lily/sequential-music.cc: remove file.
 
        * lily/include/lyric-combine-music.hh ("music.hh"): remove file.
index d2b3dc576e3bd05cec03f6e056f1174f75472b0a..df1e6ca5fe135c11a4feaed94e9db1d9557ddaec 100644 (file)
@@ -238,9 +238,6 @@ Beam::quanting (SCM smob)
     }
 
   Real rad = Staff_symbol_referencer::staff_radius (me);
-
-  
-  
   Drul_array<int> edge_beam_counts
     (Stem::beam_multiplicity (stems[0]).length  () + 1,
      Stem::beam_multiplicity (stems.top ()).length  () + 1);
@@ -252,8 +249,8 @@ Beam::quanting (SCM smob)
     if (qscores[i].demerits < reasonable_score)
       {
        Real d = score_forbidden_quants (qscores[i].yl, qscores[i].yr,
-                                    rad, slt, thickness, beam_translation,
-                                    edge_beam_counts, ldir, rdir); 
+                                        rad, slt, thickness, beam_translation,
+                                        edge_beam_counts, ldir, rdir); 
        qscores[i].demerits += d;
 
 #if DEBUG_QUANTING
index 664b8be6b4bbf8067de6fd236ba74da760f2756e..16536ccc2d01d153d665fadfdefc26024e35c101 100644 (file)
@@ -51,8 +51,8 @@ public:
   void print () const;
 
   /// Transpose, with the interval central C to #p#
-  virtual void transpose (Pitch p);
-
+  void transpose (Pitch p);
+  
   /// Scale the music in time by #factor#.
   void compress (Moment factor);
   
index 7e88a21b07aa22aa2a07c293c91616d6aa667846..e240f96572cc245474c29e672de1294f134be794 100644 (file)
@@ -19,7 +19,6 @@ public:
   VIRTUAL_COPY_CONSTRUCTOR (Music, Untransposable_music);
 
   virtual Pitch to_relative_octave (Pitch);
-  virtual void transpose (Pitch); 
 };
 
 
index 4ebfc6a13ccac6ecc30aae58e86dfcc7330747df..958eedc221bcb1092a3161709c5678b8c12fdf30 100644 (file)
@@ -179,6 +179,9 @@ Music::compress (Moment factor)
 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);
@@ -191,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 ()));
            }
        }