]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/mensural-ligature-engraver.cc
* lily/include/scm-hash.hh (class Scheme_hash_table): idem.
[lilypond.git] / lily / mensural-ligature-engraver.cc
index 913580a2d34e407add6760056a64e21f1582ff1f..f8786b43142723b9d4a8e946e94341a41675f5b4 100644 (file)
@@ -325,26 +325,18 @@ Mensural_ligature_engraver::transform_heads (Array<Grob_info> primitives)
   // TODO: if (state == STATE_ERROR) { ... }
 }
 
-void set_delta_pitch (Item *primitive, Grob_info info1, Grob_info info2)
-{
-  Pitch pitch1 = *unsmob_pitch (info1.music_cause ()->get_mus_property ("pitch"));
-  Pitch pitch2 = *unsmob_pitch (info2.music_cause ()->get_mus_property ("pitch"));
-  int delta_pitch = (pitch2.steps () - pitch1.steps ());
-  primitive->set_grob_property ("delta-pitch", gh_int2scm (delta_pitch));
-}
-
 /*
- * A MensuralLigature grob consists of a bunch of LigatureHead grobs
- * that are glued together.  It (a) does not make sense to change
+ * A MensuralLigature grob consists of a bunch of NoteHead grobs that
+ * are glued together.  It (a) does not make sense to change
  * properties like thickness or flexa-width from one head to the next
  * within a ligature (this would totally screw up alignment), and (b)
  * some of these properties (like flexa-width) are specific to
  * e.g. the MensuralLigature (as in contrast to e.g. LigatureBracket),
- * and therefore should not be handled in the generic LigatureHead
- * (which is also used by LigatureBracket).  Therefore, we let the
- * user control these properties via the concrete Ligature grob (like
+ * and therefore should not be handled in the NoteHead code (which is
+ * also used by LigatureBracket).  Therefore, we let the user control
+ * these properties via the concrete Ligature grob (like
  * MensuralLigature) and then copy these properties as necessary to
- * each of the LigatureHead grobs.  This is what
+ * each of the NoteHead grobs.  This is what
  * propagate_properties() does.
  */
 void
@@ -354,7 +346,7 @@ Mensural_ligature_engraver::propagate_properties (Spanner *ligature,
   SCM thickness_scm = ligature->get_grob_property ("thickness");
   Real thickness = (thickness_scm != SCM_EOL) ?
     gh_scm2double (thickness_scm) : 1.4;
-  thickness *= ligature->get_paper ()->get_var ("linethickness");
+  thickness *= ligature->get_paper ()->get_realvar (ly_symbol2scm ("linethickness"));
 
   Real head_width =
     Font_interface::get_default_font (ligature)->
@@ -390,8 +382,6 @@ Mensural_ligature_engraver::propagate_properties (Spanner *ligature,
                                        gh_double2scm (half_flexa_width));
          primitive->set_grob_property ("flexa-width",
                                        gh_double2scm (flexa_width));
-         set_delta_pitch (primitive,
-                          primitives[i], primitives[i+1]);
          break;
        default:
          programming_error (_f ("unexpected case fall-through"));
@@ -448,7 +438,7 @@ Mensural_ligature_engraver::join_primitives (Array<Grob_info> primitives)
          if (output & MLP_ANY)
            {
              int delta_pitch = (pitch.steps () - last_pitch.steps ());
-             primitive->set_grob_property ("join-left",
+             primitive->set_grob_property ("join-left-amount",
                                            gh_int2scm (delta_pitch));
            }
        }
@@ -470,6 +460,6 @@ ENTER_DESCRIPTION (Mensural_ligature_engraver,
 /* descr */       "Handles Mensural_ligature_events by glueing special ligature heads together.",
 /* creats*/       "MensuralLigature",
 /* accepts */     "ligature-event abort-event",
-/* acks  */      "ligature-head-interface note-head-interface rest-interface",
+/* acks  */      "note-head-interface rest-interface",
 /* reads */       "",
 /* write */       "");