X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Fitem.cc;h=abae1689a6ad828a82430caa84b59435ad395cff;hb=22d7891f2b9ddbe39118ff24f26b3a6eb302178e;hp=e92ac8ac90afbffcb934c820e656808513545b60;hpb=d9b43b93f2c885409bafdb157138158f65cc49aa;p=lilypond.git diff --git a/lily/item.cc b/lily/item.cc index e92ac8ac90..abae1689a6 100644 --- a/lily/item.cc +++ b/lily/item.cc @@ -13,12 +13,15 @@ #include "paper-column.hh" #include "spanner.hh" #include "lily-guile.hh" -#include "line-of-score.hh" +#include "system.hh" +#include "group-interface.hh" Item::Item (SCM s) : Grob (s) { broken_to_drul_[LEFT] = broken_to_drul_[RIGHT]=0; + Group_interface::add_thing (this, ly_symbol2scm ("interfaces"), ly_symbol2scm ("item-interface")); + } /** @@ -51,7 +54,7 @@ Item::column_l () const return parent ? parent->column_l () : 0; } -Line_of_score * +System * Item::line_l () const { Grob *g = get_parent (X_AXIS); @@ -97,7 +100,7 @@ Item::discretionary_processing () } Grob* -Item::find_broken_piece (Line_of_score*l) const +Item::find_broken_piece (System*l) const { if (line_l () == l) return (Item*) (this); @@ -169,11 +172,11 @@ Item::handle_prebroken_dependencies () suicide (); else if (empty) { - set_extent_callback (SCM_EOL, X_AXIS); - set_extent_callback (SCM_EOL, Y_AXIS); + set_extent (SCM_EOL, X_AXIS); + set_extent (SCM_EOL, Y_AXIS); } else if (trans) - set_grob_property ("molecule-callback", SCM_BOOL_T); + set_grob_property ("molecule-callback", SCM_EOL); } } @@ -192,3 +195,10 @@ unsmob_item (SCM s ) { return dynamic_cast (unsmob_grob (s)); } + + + +ADD_INTERFACE(Item, + "item-interface", + "", + "no-spacing-rods visibility-lambda breakable")