source file of the GNU LilyPond music typesetter
- (c) 2005 Han-Wen Nienhuys <hanwen@xs4all.nl>
+ (c) 2005--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
*/
#include "engraver.hh"
DECLARE_ACKNOWLEDGER (dots);
DECLARE_ACKNOWLEDGER (text_spanner);
void process_music ();
- virtual bool try_music (Music *);
void stop_translation_timestep ();
private:
Item *trill_group_;
Item *trill_accidental_;
- Link_array<Grob> heads_;
+ vector<Grob*> heads_;
void make_trill (Music *);
};
void
Pitched_trill_engraver::acknowledge_dots (Grob_info info)
{
- heads_.push (info.grob ());
+ heads_.push_back (info.grob ());
}
void
Pitched_trill_engraver::acknowledge_note_head (Grob_info info)
{
- heads_.push (info.grob ());
+ heads_.push_back (info.grob ());
}
void
if (mus
&& mus->is_mus_type ("trill-span-event")
&& to_dir (mus->get_property ("span-direction")) == START
- && unsmob_pitch (mus->get_property ("trill-pitch")))
+ && unsmob_pitch (mus->get_property ("pitch")))
make_trill (mus);
}
void
Pitched_trill_engraver::make_trill (Music *mus)
{
- SCM scm_pitch = mus->get_property ("trill-pitch");
+ SCM scm_pitch = mus->get_property ("pitch");
Pitch *p = unsmob_pitch (scm_pitch);
SCM keysig = get_property ("localKeySignature");
Pitched_trill_engraver::stop_translation_timestep ()
{
if (trill_group_)
- for (int i = 0; i < heads_.size (); i++)
+ for (vsize i = 0; i < heads_.size (); i++)
Side_position_interface::add_support (trill_group_, heads_[i]);
heads_.clear ();
{
}
-bool
-Pitched_trill_engraver::try_music (Music *)
-{
- return false;
-}
#include "translator.icc"
+
ADD_ACKNOWLEDGER (Pitched_trill_engraver, note_head);
ADD_ACKNOWLEDGER (Pitched_trill_engraver, dots);
ADD_ACKNOWLEDGER (Pitched_trill_engraver, text_spanner);
+
ADD_TRANSLATOR (Pitched_trill_engraver,
/* doc */ "Print the bracketed notehead after a notehead with trill.",
- /* create */ "TrillPitchHead TrillPitchAccidental TrillPitchGroup",
+ /* create */
+ "TrillPitchHead "
+ "TrillPitchAccidental "
+ "TrillPitchGroup",
/* accept */ "",
/* read */ "",
/* write */ "");