2 event-chord-iterator.cc -- implement Event_chord_iterator
4 source file of the GNU LilyPond music typesetter
6 (c) 1997--2004 Han-Wen Nienhuys <hanwen@cs.uu.nl>
9 #include "event-chord-iterator.hh"
13 #include "music-list.hh"
16 Event_chord_iterator::Event_chord_iterator ()
21 Event_chord_iterator::get_req_translator ()
23 assert (get_outlet ());
24 if (get_outlet ()->is_bottom_context ())
27 set_context (get_outlet ()->get_default_interpreter ());
32 Event_chord_iterator::construct_children ()
34 Simple_music_iterator::construct_children ();
35 get_req_translator ();
39 Event_chord_iterator::get_elt () const
41 return (Event_chord*) get_music ();
46 Event_chord_iterator::process (Moment m)
48 if (last_processed_mom_ < Moment (0))
50 for (SCM s = dynamic_cast<Music_sequence *> (get_music ())->music_list ();
51 scm_is_pair (s); s = scm_cdr (s))
53 Music *mus = unsmob_music (scm_car (s));
55 bool gotcha = try_music (mus);
57 mus->origin ()->warning (_f ("Junking event: `%s'", mus->name ()));
60 Simple_music_iterator::process (m);
63 IMPLEMENT_CTOR_CALLBACK (Event_chord_iterator);