X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;ds=sidebyside;f=lily%2Frest.cc;h=f562f69534a1689d648efabb5d90051c9b0a42d3;hb=ef31f0442c7be02c90b9e6b2b9e9809def42ae37;hp=9e5dc046e14821fdced4de7ee10707c02f08b956;hpb=e86b2ea93e8b9e829520e258c24416060e296bdb;p=lilypond.git diff --git a/lily/rest.cc b/lily/rest.cc index 9e5dc046e1..f562f69534 100644 --- a/lily/rest.cc +++ b/lily/rest.cc @@ -35,7 +35,7 @@ MAKE_SCHEME_CALLBACK (Rest, y_offset_callback, 1); SCM Rest::y_offset_callback (SCM smob) { - Grob *me = Grob::unsmob (smob); + Grob *me = unsmob (smob); int duration_log = scm_to_int (me->get_property ("duration-log")); Real ss = Staff_symbol_referencer::staff_space (me); @@ -146,8 +146,8 @@ MAKE_SCHEME_CALLBACK (Rest, calc_cross_staff, 1); SCM Rest::calc_cross_staff (SCM smob) { - Grob *me = Grob::unsmob (smob); - Grob *stem = Grob::unsmob (me->get_object ("stem")); + Grob *me = unsmob (smob); + Grob *stem = unsmob (me->get_object ("stem")); if (!stem) return SCM_BOOL_F; @@ -199,11 +199,10 @@ Rest::glyph_name (Grob *me, int durlog, const string &style, bool try_ledgers, actual_style = ""; } - if ((style == "classical") && (durlog != 2)) + if (((style == "classical") || (style == "z")) && (durlog != 2)) { /* - classical style: revert back to default style for any rest other - than quarter rest + these styles differ from the default in quarter rests only */ actual_style = ""; } @@ -260,7 +259,7 @@ Rest::translate (Grob *me, int dy) SCM Rest::print (SCM smob) { - return brew_internal_stencil (Grob::unsmob (smob), true); + return brew_internal_stencil (unsmob (smob), true); } MAKE_SCHEME_CALLBACK (Rest, width, 1); @@ -270,14 +269,14 @@ MAKE_SCHEME_CALLBACK (Rest, width, 1); SCM Rest::width (SCM smob) { - return generic_extent_callback (Grob::unsmob (smob), X_AXIS); + return generic_extent_callback (unsmob (smob), X_AXIS); } MAKE_SCHEME_CALLBACK (Rest, height, 1); SCM Rest::height (SCM smob) { - return generic_extent_callback (Grob::unsmob (smob), Y_AXIS); + return generic_extent_callback (unsmob (smob), Y_AXIS); } /* @@ -295,7 +294,7 @@ Rest::generic_extent_callback (Grob *me, Axis a) with ledgered rests. */ SCM m = brew_internal_stencil (me, a != X_AXIS); - return ly_interval2scm (Stencil::unsmob (m)->extent (a)); + return ly_interval2scm (unsmob (m)->extent (a)); } MAKE_SCHEME_CALLBACK (Rest, pure_height, 3); @@ -304,9 +303,9 @@ Rest::pure_height (SCM smob, SCM /* start */, SCM /* end */) { - Grob *me = Grob::unsmob (smob); + Grob *me = unsmob (smob); SCM m = brew_internal_stencil (me, false); - return ly_interval2scm (Stencil::unsmob (m)->extent (Y_AXIS)); + return ly_interval2scm (unsmob (m)->extent (Y_AXIS)); } ADD_INTERFACE (Rest,