]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/script-engraver.cc
Comment-out \fetaflat,
[lilypond.git] / lily / script-engraver.cc
index 0cf404e7b10dc7ed2b8dda17beca92cf660977c3..c5e8ff219035740e8d0ea2aeb3525e0edce8eda6 100644 (file)
@@ -9,8 +9,7 @@
 #include "context.hh"
 #include "directional-element-interface.hh"
 #include "engraver.hh"
-#include "event.hh"
-#include "new-slur.hh"
+#include "slur.hh"
 #include "note-column.hh"
 #include "paper-column.hh"
 #include "rhythmic-head.hh"
@@ -80,8 +79,8 @@ copy_property (Grob *g, SCM sym, SCM alist)
   if (g->internal_get_property (sym) == SCM_EOL)
     {
       SCM entry = scm_assoc (sym, alist);
-      if (ly_c_pair_p (entry))
-       g->internal_set_property (sym, ly_cdr (entry));
+      if (scm_is_pair (entry))
+       g->internal_set_property (sym, scm_cdr (entry));
     }
 }
 
@@ -105,18 +104,22 @@ void make_script_from_event (Grob *p, bool * follow, Context *tg,
       return;
     }
 
-  art = ly_cdr (art);
+  art = scm_cdr (art);
 
   SCM follow_scm = scm_assoc (ly_symbol2scm ("follow-into-staff"),
                              art);
 
-  *follow = ly_c_pair_p (follow_scm) && to_boolean (ly_cdr (follow_scm));
+  *follow = scm_is_pair (follow_scm) && to_boolean (scm_cdr (follow_scm));
   bool priority_found = false ; 
     
-  for (SCM s = art ; ly_c_pair_p (s); s = ly_cdr (s))
+  for (SCM s = art ; scm_is_pair (s); s = scm_cdr (s))
     {
-      SCM sym = ly_caar (s);
-      SCM val = ly_cdar (s);
+      SCM sym = scm_caar (s);
+      SCM type = scm_object_property (sym, ly_symbol2scm ("backend-type?"));
+      if (!ly_c_procedure_p (type))
+       continue;
+      
+      SCM val = scm_cdar (s);
 
       if (sym == ly_symbol2scm ("script-priority"))
        {
@@ -124,7 +127,7 @@ void make_script_from_event (Grob *p, bool * follow, Context *tg,
          /* Make sure they're in order of user input by adding index i.
             Don't use the direction in this priority. Smaller means closer
             to the head.  */
-         int prio  = ly_scm2int (val) +  index;
+         int prio  = scm_to_int (val) +  index;
          
         
          val = scm_int2num (prio);
@@ -216,7 +219,7 @@ Script_engraver::acknowledge_grob (Grob_info info)
            e->set_parent (info.grob_, X_AXIS);
        }
     }
-  else if (New_slur::has_interface (info.grob_))
+  else if (Slur::has_interface (info.grob_))
     slur_ = dynamic_cast<Spanner*> (info.grob_);
 }
 
@@ -236,11 +239,11 @@ Script_engraver::stop_translation_timestep ()
   scripts_.clear ();
 }
 
-ENTER_DESCRIPTION (Script_engraver,
+ADD_TRANSLATOR (Script_engraver,
 /* descr */       "Handles note scripted articulations.",
 /* creats*/       "Script",
 /* accepts */     "script-event articulation-event",
-/* acks  */       "stem-interface rhythmic-head-interface\
new-slur-interface note-column-interface",
+/* acks  */       "stem-interface rhythmic-head-interface " 
                "slur-interface note-column-interface",
 /* reads */       "scriptDefinitions",
 /* write */       "");