X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Fgrace-engraver.cc;h=59550ba8326c17c9c2bd5bb74360020ccd40573f;hb=2bbacb364aa29041af9cbbbd32cfad2e8e387cb3;hp=42b6742dbc7274d0c33c6581fdab38ebfc856561;hpb=18d9bcf40f630efefdeb42e3d15653c7aae73ec3;p=lilypond.git diff --git a/lily/grace-engraver.cc b/lily/grace-engraver.cc index 42b6742dbc..59550ba832 100644 --- a/lily/grace-engraver.cc +++ b/lily/grace-engraver.cc @@ -41,7 +41,8 @@ protected: void grace_change (SCM); }; -Grace_engraver::Grace_engraver () +Grace_engraver::Grace_engraver (Context *c) + : Engraver (c) { grace_settings_ = SCM_EOL; last_moment_ = Moment (Rational (-1, 1)); @@ -100,7 +101,7 @@ Grace_engraver::consider_change_grace_settings () SCM grob = scm_cadr (elt); SCM cell = scm_cddr (elt); - Grob_property_info (Context::unsmob (context), grob).matched_pop (cell); + Grob_property_info (unsmob (context), grob).matched_pop (cell); } grace_settings_ = SCM_EOL; } @@ -120,10 +121,7 @@ Grace_engraver::consider_change_grace_settings () if (!scm_is_pair (sym)) sym = scm_list_1 (sym); - Context *c = context (); - while (c && !c->is_alias (context_name)) - c = c->get_parent_context (); - + Context *c = find_context_above (context (), context_name); if (c) { SCM cell = Grob_property_info (c, grob).push (sym, val); @@ -160,6 +158,12 @@ Grace_engraver::derived_mark () const Engraver::derived_mark (); } +void +Grace_engraver::boot () +{ + +} + ADD_TRANSLATOR (Grace_engraver, /* doc */ "Set font size and other properties for grace notes.",