2 staff-collecting-engraver.cc -- implement Staff_collecting_engraver
4 source file of the GNU LilyPond music typesetter
6 (c) 2001--2003 Han-Wen Nienhuys <hanwen@cs.uu.nl>
9 #include "staff-symbol.hh"
10 #include "engraver.hh"
12 #include "translator-group.hh"
14 class Staff_collecting_engraver
: public Engraver
17 TRANSLATOR_DECLARATIONS(Staff_collecting_engraver
);
18 virtual void acknowledge_grob (Grob_info
);
21 Staff_collecting_engraver::Staff_collecting_engraver ()
27 Staff_collecting_engraver::acknowledge_grob (Grob_info gi
)
29 if (Staff_symbol::has_interface (gi
.grob_
))
31 SCM staffs
= get_property ("stavesFound");
32 staffs
= gh_cons (gi
.grob_
->self_scm (), staffs
);
34 daddy_trans_
->set_property ("stavesFound", staffs
);
39 ENTER_DESCRIPTION(Staff_collecting_engraver
,
40 /* descr */ "Maintain the stavesFound variable",
44 /* acks */ "staff-symbol-interface",
45 /* reads */ "stavesFound",
46 /* write */ "stavesFound");