2 apply-context-iterator.cc -- implement Apply_context_iterator
4 source file of the GNU LilyPond music typesetter
6 (c) 2004 Han-Wen Nienhuys <hanwen@xs4all.nl>
10 #include "simple-music-iterator.hh"
18 class Apply_context_iterator : public Simple_music_iterator
21 DECLARE_SCHEME_CALLBACK (constructor, ());
23 virtual void process (Moment);
28 Apply_context_iterator::process (Moment m)
30 SCM proc = get_music ()->get_property ("procedure");
32 if (ly_c_procedure_p (proc))
33 scm_call_1 (proc, get_outlet ()->self_scm ());
35 get_music ()->origin ()->warning (_("\\applycontext argument is not a procedure"));
37 Simple_music_iterator::process (m);
40 IMPLEMENT_CTOR_CALLBACK (Apply_context_iterator);