]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/auto-beam-engraver.cc
* lily/include/translator.hh (class Translator): remove
[lilypond.git] / lily / auto-beam-engraver.cc
index 9559e044cd1ab303809def3f71f6ae11c80daeb1..aa020c7e16b632b397be0125c0103d05b97833fb 100644 (file)
@@ -26,9 +26,9 @@ class Auto_beam_engraver : public Engraver
   TRANSLATOR_DECLARATIONS (Auto_beam_engraver);
 
 protected:
-  PRECOMPUTED_VIRTUAL void stop_translation_timestep ();
-  PRECOMPUTED_VIRTUAL void start_translation_timestep ();
-  PRECOMPUTED_VIRTUAL void process_music ();
+  void stop_translation_timestep ();
+  void start_translation_timestep ();
+  void process_music ();
   virtual bool try_music (Music *);
   virtual void finalize ();
 
@@ -37,7 +37,7 @@ protected:
   DECLARE_ACKNOWLEDGER(bar_line);
   DECLARE_ACKNOWLEDGER(stem);
   
-  PRECOMPUTED_VIRTUAL void process_acknowledged ();
+  void process_acknowledged ();
 
 private:
   bool test_moment (Direction, Moment);
@@ -177,17 +177,13 @@ Auto_beam_engraver::create_beam ()
   if (to_boolean (get_property ("skipTypesetting")))
     return 0;
 
+  for (int i = 0; i < stems_->size (); i++)
+    if (Stem::get_beam ((*stems_)[i]))
+      return 0;
+
   Spanner *beam = new Spanner (beam_settings_, context ()->get_grob_key ("Beam"));
   for (int i = 0; i < stems_->size (); i++)
     {
-      /*
-       watch out for stem tremolos and abbreviation beams
-      */
-      if (Stem::get_beam ((*stems_)[i]))
-       {
-         scm_gc_unprotect_object (beam->self_scm ());
-         return 0;
-       }
       Beam::add_stem (beam, (*stems_)[i]);
     }
 
@@ -306,6 +302,7 @@ Auto_beam_engraver::finalize ()
 void
 Auto_beam_engraver::acknowledge_beam (Grob_info info)
 {
+  (void)info;
   check_bar_property ();
   if (stems_)
     {
@@ -316,6 +313,7 @@ Auto_beam_engraver::acknowledge_beam (Grob_info info)
 void
 Auto_beam_engraver::acknowledge_bar_line (Grob_info info)
 {
+  (void)info;
   check_bar_property ();
   if (stems_)
     end_beam ();
@@ -324,6 +322,7 @@ Auto_beam_engraver::acknowledge_bar_line (Grob_info info)
 void
 Auto_beam_engraver::acknowledge_rest (Grob_info info)
 {
+  (void)info;
   check_bar_property ();
   if (stems_)
     end_beam ();
@@ -435,6 +434,5 @@ ADD_TRANSLATOR (Auto_beam_engraver,
                "@code{stemRightBeamCount}. ",
                /* creats*/ "Beam",
                /* accepts */ "beam-forbid-event",
-               /* acks  */ "",
                /* reads */ "autoBeaming autoBeamSettings beatLength subdivideBeams",
                /* write */ "");