diff options
author | David Kastrup <dak@gnu.org> | 2016-05-29 09:28:51 +0200 |
---|---|---|
committer | David Kastrup <dak@gnu.org> | 2016-05-31 11:14:18 +0200 |
commit | dbaf1e56e37be0e204231c5bf1adcb14bd8ac3b8 (patch) | |
tree | 72ef0ea2bdc704ce797c7437c1c110b1ceb56a3b | |
parent | 4b4a2cae9953cff69159f10763e990f5e4265ddd (diff) |
Issue 4865/2: Rewrite of new translator initializations
This was done by running the following Bash script:
git grep '^ADD_TRANSLATOR (' lily|sed 's/^\([^:]*\):ADD_TRANSLATOR ( *\([a-zA-Z_]\+\),.*$/\1 \2/' |
while read file translator
do
lines="$(git grep -h '^\(ADD_ACKNOWLEDGER\|ADD_END_ACKNOWLEDGER\|IMPLEMENT_TRANSLATOR_LISTENER\) ('$translator, $file)"
sed -i "$(echo "$lines"|sed 's+^..*$+/&/d+')" $file
sed -i "/^ADD_TRANSLATOR ($translator,/i\\
void\\
$translator::boot ()\\
{\\
$(echo "$lines"|sed 's/IMPLEMENT_TRANSLATOR_LISTENER/ADD_LISTENER/;s/^./ &/;s/$/\\/')
}\\
" $file
done
131 files changed, 966 insertions, 287 deletions
diff --git a/lily/accidental-engraver.cc b/lily/accidental-engraver.cc index f9d2e15cd4..1be735b0ed 100644 --- a/lily/accidental-engraver.cc +++ b/lily/accidental-engraver.cc @@ -511,11 +511,16 @@ Accidental_engraver::process_music () update_local_key_signature (sig); } -ADD_ACKNOWLEDGER (Accidental_engraver, arpeggio); -ADD_ACKNOWLEDGER (Accidental_engraver, finger); -ADD_ACKNOWLEDGER (Accidental_engraver, rhythmic_head); -ADD_END_ACKNOWLEDGER (Accidental_engraver, tie); -ADD_ACKNOWLEDGER (Accidental_engraver, note_column); + +void +Accidental_engraver::boot () +{ + ADD_ACKNOWLEDGER (Accidental_engraver, arpeggio); + ADD_ACKNOWLEDGER (Accidental_engraver, finger); + ADD_ACKNOWLEDGER (Accidental_engraver, rhythmic_head); + ADD_END_ACKNOWLEDGER (Accidental_engraver, tie); + ADD_ACKNOWLEDGER (Accidental_engraver, note_column); +} ADD_TRANSLATOR (Accidental_engraver, /* doc */ diff --git a/lily/ambitus-engraver.cc b/lily/ambitus-engraver.cc index 9ceea9387c..c2761c11a9 100644 --- a/lily/ambitus-engraver.cc +++ b/lily/ambitus-engraver.cc @@ -218,7 +218,12 @@ Ambitus_engraver::finalize () } } -ADD_ACKNOWLEDGER (Ambitus_engraver, note_head); +void +Ambitus_engraver::boot () +{ + ADD_ACKNOWLEDGER (Ambitus_engraver, note_head); +} + ADD_TRANSLATOR (Ambitus_engraver, /* doc */ "Create an ambitus.", diff --git a/lily/arpeggio-engraver.cc b/lily/arpeggio-engraver.cc index e191470161..44eb2580a3 100644 --- a/lily/arpeggio-engraver.cc +++ b/lily/arpeggio-engraver.cc @@ -55,7 +55,6 @@ Arpeggio_engraver::Arpeggio_engraver () arpeggio_event_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Arpeggio_engraver, arpeggio); void Arpeggio_engraver::listen_arpeggio (Stream_event *ev) { ASSIGN_EVENT_ONCE (arpeggio_event_, ev); @@ -109,9 +108,15 @@ Arpeggio_engraver::stop_translation_timestep () arpeggio_event_ = 0; } -ADD_ACKNOWLEDGER (Arpeggio_engraver, stem); -ADD_ACKNOWLEDGER (Arpeggio_engraver, rhythmic_head); -ADD_ACKNOWLEDGER (Arpeggio_engraver, note_column); + +void +Arpeggio_engraver::boot () +{ + ADD_LISTENER (Arpeggio_engraver, arpeggio); + ADD_ACKNOWLEDGER (Arpeggio_engraver, stem); + ADD_ACKNOWLEDGER (Arpeggio_engraver, rhythmic_head); + ADD_ACKNOWLEDGER (Arpeggio_engraver, note_column); +} ADD_TRANSLATOR (Arpeggio_engraver, /* doc */ diff --git a/lily/auto-beam-engraver.cc b/lily/auto-beam-engraver.cc index 68c61d97a8..a68e1b9f06 100644 --- a/lily/auto-beam-engraver.cc +++ b/lily/auto-beam-engraver.cc @@ -160,7 +160,6 @@ Auto_beam_engraver::Auto_beam_engraver () beam_settings_ = SCM_EOL; } -IMPLEMENT_TRANSLATOR_LISTENER (Auto_beam_engraver, beam_forbid); void Auto_beam_engraver::listen_beam_forbid (Stream_event *ev) { @@ -541,11 +540,17 @@ Auto_beam_engraver::process_acknowledged () process_acknowledged_count_++; } -ADD_ACKNOWLEDGER (Auto_beam_engraver, stem); -ADD_ACKNOWLEDGER (Auto_beam_engraver, bar_line); -ADD_ACKNOWLEDGER (Auto_beam_engraver, beam); -ADD_ACKNOWLEDGER (Auto_beam_engraver, breathing_sign); -ADD_ACKNOWLEDGER (Auto_beam_engraver, rest); +void +Auto_beam_engraver::boot () +{ + ADD_LISTENER (Auto_beam_engraver, beam_forbid); + ADD_ACKNOWLEDGER (Auto_beam_engraver, stem); + ADD_ACKNOWLEDGER (Auto_beam_engraver, bar_line); + ADD_ACKNOWLEDGER (Auto_beam_engraver, beam); + ADD_ACKNOWLEDGER (Auto_beam_engraver, breathing_sign); + ADD_ACKNOWLEDGER (Auto_beam_engraver, rest); +} + ADD_TRANSLATOR (Auto_beam_engraver, /* doc */ "Generate beams based on measure characteristics and observed" @@ -592,7 +597,6 @@ Grace_auto_beam_engraver::Grace_auto_beam_engraver () // not considered. } -IMPLEMENT_TRANSLATOR_LISTENER (Grace_auto_beam_engraver, beam_forbid); void Grace_auto_beam_engraver::listen_beam_forbid (Stream_event *ev) { @@ -638,11 +642,17 @@ Grace_auto_beam_engraver::test_moment (Direction dir, Moment test_mom, Moment) return !test_mom.grace_part_; } -ADD_ACKNOWLEDGER (Grace_auto_beam_engraver, stem); -ADD_ACKNOWLEDGER (Grace_auto_beam_engraver, bar_line); -ADD_ACKNOWLEDGER (Grace_auto_beam_engraver, beam); -ADD_ACKNOWLEDGER (Grace_auto_beam_engraver, breathing_sign); -ADD_ACKNOWLEDGER (Grace_auto_beam_engraver, rest); +void +Grace_auto_beam_engraver::boot () +{ + ADD_LISTENER (Grace_auto_beam_engraver, beam_forbid); + ADD_ACKNOWLEDGER (Grace_auto_beam_engraver, stem); + ADD_ACKNOWLEDGER (Grace_auto_beam_engraver, bar_line); + ADD_ACKNOWLEDGER (Grace_auto_beam_engraver, beam); + ADD_ACKNOWLEDGER (Grace_auto_beam_engraver, breathing_sign); + ADD_ACKNOWLEDGER (Grace_auto_beam_engraver, rest); +} + ADD_TRANSLATOR (Grace_auto_beam_engraver, /* doc */ "Generates one autobeam group across an entire grace phrase. " diff --git a/lily/axis-group-engraver.cc b/lily/axis-group-engraver.cc index 3a9b0d6775..49350d01cf 100644 --- a/lily/axis-group-engraver.cc +++ b/lily/axis-group-engraver.cc @@ -165,7 +165,12 @@ Axis_group_engraver::add_element (Grob *e) Axis_group_interface::add_element (staffline_, e); } -ADD_ACKNOWLEDGER (Axis_group_engraver, grob); + +void +Axis_group_engraver::boot () +{ + ADD_ACKNOWLEDGER (Axis_group_engraver, grob); +} ADD_TRANSLATOR (Axis_group_engraver, /* doc */ diff --git a/lily/balloon-engraver.cc b/lily/balloon-engraver.cc index 980aa92231..5155d98518 100644 --- a/lily/balloon-engraver.cc +++ b/lily/balloon-engraver.cc @@ -37,7 +37,6 @@ class Balloon_engraver : public Engraver void balloonify (Grob *, Stream_event *); }; -IMPLEMENT_TRANSLATOR_LISTENER (Balloon_engraver, annotate_output); void Balloon_engraver::listen_annotate_output (Stream_event *ev) { @@ -85,7 +84,13 @@ Balloon_engraver::acknowledge_grob (Grob_info info) } } -ADD_ACKNOWLEDGER (Balloon_engraver, grob); + +void +Balloon_engraver::boot () +{ + ADD_LISTENER (Balloon_engraver, annotate_output); + ADD_ACKNOWLEDGER (Balloon_engraver, grob); +} ADD_TRANSLATOR (Balloon_engraver, /* doc */ diff --git a/lily/bar-engraver.cc b/lily/bar-engraver.cc index 397743b4b0..97972d046c 100644 --- a/lily/bar-engraver.cc +++ b/lily/bar-engraver.cc @@ -108,7 +108,12 @@ Bar_engraver::acknowledge_end_spanner (Grob_info gi) spanners_.push_back (dynamic_cast<Spanner *> (g)); } -ADD_END_ACKNOWLEDGER (Bar_engraver, spanner); + +void +Bar_engraver::boot () +{ + ADD_END_ACKNOWLEDGER (Bar_engraver, spanner); +} ADD_TRANSLATOR (Bar_engraver, /* doc */ diff --git a/lily/bar-number-engraver.cc b/lily/bar-number-engraver.cc index 144076439c..75c192f284 100644 --- a/lily/bar-number-engraver.cc +++ b/lily/bar-number-engraver.cc @@ -52,7 +52,6 @@ protected: TRANSLATOR_DECLARATIONS (Bar_number_engraver); }; -IMPLEMENT_TRANSLATOR_LISTENER (Bar_number_engraver, alternative); void Bar_number_engraver::listen_alternative (Stream_event *ev) { @@ -177,7 +176,13 @@ Bar_number_engraver::create_items () text_ = make_item ("BarNumber", SCM_EOL); } -ADD_ACKNOWLEDGER (Bar_number_engraver, break_alignment); + +void +Bar_number_engraver::boot () +{ + ADD_LISTENER (Bar_number_engraver, alternative); + ADD_ACKNOWLEDGER (Bar_number_engraver, break_alignment); +} ADD_TRANSLATOR (Bar_number_engraver, /* doc */ diff --git a/lily/beam-collision-engraver.cc b/lily/beam-collision-engraver.cc index 151ffacf16..0ca0e0cf65 100644 --- a/lily/beam-collision-engraver.cc +++ b/lily/beam-collision-engraver.cc @@ -193,15 +193,20 @@ Beam_collision_engraver::acknowledge_beam (Grob_info i) #include "translator.icc" -ADD_ACKNOWLEDGER (Beam_collision_engraver, note_head); -ADD_ACKNOWLEDGER (Beam_collision_engraver, stem); -ADD_ACKNOWLEDGER (Beam_collision_engraver, accidental); -ADD_ACKNOWLEDGER (Beam_collision_engraver, clef); -ADD_ACKNOWLEDGER (Beam_collision_engraver, key_signature); -ADD_ACKNOWLEDGER (Beam_collision_engraver, time_signature); -ADD_ACKNOWLEDGER (Beam_collision_engraver, clef_modifier); -ADD_ACKNOWLEDGER (Beam_collision_engraver, flag); -ADD_ACKNOWLEDGER (Beam_collision_engraver, beam); + +void +Beam_collision_engraver::boot () +{ + ADD_ACKNOWLEDGER (Beam_collision_engraver, note_head); + ADD_ACKNOWLEDGER (Beam_collision_engraver, stem); + ADD_ACKNOWLEDGER (Beam_collision_engraver, accidental); + ADD_ACKNOWLEDGER (Beam_collision_engraver, clef); + ADD_ACKNOWLEDGER (Beam_collision_engraver, key_signature); + ADD_ACKNOWLEDGER (Beam_collision_engraver, time_signature); + ADD_ACKNOWLEDGER (Beam_collision_engraver, clef_modifier); + ADD_ACKNOWLEDGER (Beam_collision_engraver, flag); + ADD_ACKNOWLEDGER (Beam_collision_engraver, beam); +} ADD_TRANSLATOR (Beam_collision_engraver, /* doc */ diff --git a/lily/beam-engraver.cc b/lily/beam-engraver.cc index 554aeda7a1..019d68db48 100644 --- a/lily/beam-engraver.cc +++ b/lily/beam-engraver.cc @@ -112,7 +112,6 @@ Beam_engraver::Beam_engraver () prev_start_ev_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Beam_engraver, beam); void Beam_engraver::listen_beam (Stream_event *ev) { @@ -312,8 +311,14 @@ Beam_engraver::acknowledge_stem (Grob_info info) Beam::add_stem (beam_, stem); } -ADD_ACKNOWLEDGER (Beam_engraver, stem); -ADD_ACKNOWLEDGER (Beam_engraver, rest); + +void +Beam_engraver::boot () +{ + ADD_LISTENER (Beam_engraver, beam); + ADD_ACKNOWLEDGER (Beam_engraver, stem); + ADD_ACKNOWLEDGER (Beam_engraver, rest); +} ADD_TRANSLATOR (Beam_engraver, /* doc */ @@ -366,7 +371,6 @@ Grace_beam_engraver::valid_end_point () /* Ugh, C&P code. */ -IMPLEMENT_TRANSLATOR_LISTENER (Grace_beam_engraver, beam); void Grace_beam_engraver::listen_beam (Stream_event *ev) { @@ -378,8 +382,14 @@ Grace_beam_engraver::listen_beam (Stream_event *ev) stop_ev_ = ev; } -ADD_ACKNOWLEDGER (Grace_beam_engraver, stem); -ADD_ACKNOWLEDGER (Grace_beam_engraver, rest); + +void +Grace_beam_engraver::boot () +{ + ADD_LISTENER (Grace_beam_engraver, beam); + ADD_ACKNOWLEDGER (Grace_beam_engraver, stem); + ADD_ACKNOWLEDGER (Grace_beam_engraver, rest); +} ADD_TRANSLATOR (Grace_beam_engraver, /* doc */ diff --git a/lily/beam-performer.cc b/lily/beam-performer.cc index a6e78d67c7..0d658dd6b8 100644 --- a/lily/beam-performer.cc +++ b/lily/beam-performer.cc @@ -80,7 +80,6 @@ Beam_performer::start_translation_timestep () now_stop_ev_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Beam_performer, beam); void Beam_performer::listen_beam (Stream_event *ev) { @@ -92,6 +91,12 @@ Beam_performer::listen_beam (Stream_event *ev) now_stop_ev_ = ev; } +void +Beam_performer::boot () +{ + ADD_LISTENER (Beam_performer, beam); +} + ADD_TRANSLATOR (Beam_performer, /* doc */ "", diff --git a/lily/bend-engraver.cc b/lily/bend-engraver.cc index 44b0f21eaa..87d13c68ec 100644 --- a/lily/bend-engraver.cc +++ b/lily/bend-engraver.cc @@ -115,7 +115,6 @@ Bend_engraver::Bend_engraver () fall_event_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Bend_engraver, bend_after); void Bend_engraver::listen_bend_after (Stream_event *ev) { @@ -133,7 +132,13 @@ Bend_engraver::process_music () } } -ADD_ACKNOWLEDGER (Bend_engraver, note_head); + +void +Bend_engraver::boot () +{ + ADD_LISTENER (Bend_engraver, bend_after); + ADD_ACKNOWLEDGER (Bend_engraver, note_head); +} ADD_TRANSLATOR (Bend_engraver, /* doc */ diff --git a/lily/break-align-engraver.cc b/lily/break-align-engraver.cc index f9090c8e08..52e4eda0c5 100644 --- a/lily/break-align-engraver.cc +++ b/lily/break-align-engraver.cc @@ -155,8 +155,13 @@ Break_align_engraver::add_to_group (SCM align_name, Item *item) Axis_group_interface::add_element (group, item); } -ADD_ACKNOWLEDGER (Break_align_engraver, break_aligned); -ADD_ACKNOWLEDGER (Break_align_engraver, break_alignable); +void +Break_align_engraver::boot () +{ + ADD_ACKNOWLEDGER (Break_align_engraver, break_aligned); + ADD_ACKNOWLEDGER (Break_align_engraver, break_alignable); +} + ADD_TRANSLATOR (Break_align_engraver, /* doc */ "Align grobs with corresponding @code{break-align-symbols}" diff --git a/lily/breathing-sign-engraver.cc b/lily/breathing-sign-engraver.cc index 34b296d10b..0ee8cabe77 100644 --- a/lily/breathing-sign-engraver.cc +++ b/lily/breathing-sign-engraver.cc @@ -51,7 +51,6 @@ Breathing_sign_engraver::Breathing_sign_engraver () breathing_sign_event_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Breathing_sign_engraver, breathing); void Breathing_sign_engraver::listen_breathing (Stream_event *ev) { @@ -74,6 +73,12 @@ Breathing_sign_engraver::stop_translation_timestep () breathing_sign_event_ = 0; } +void +Breathing_sign_engraver::boot () +{ + ADD_LISTENER (Breathing_sign_engraver, breathing); +} + ADD_TRANSLATOR (Breathing_sign_engraver, /* doc */ "Create a breathing sign.", diff --git a/lily/chord-name-engraver.cc b/lily/chord-name-engraver.cc index db8493e2a5..2f4def8116 100644 --- a/lily/chord-name-engraver.cc +++ b/lily/chord-name-engraver.cc @@ -143,14 +143,12 @@ Chord_name_engraver::process_music () context ()->set_property ("lastChord", markup); } -IMPLEMENT_TRANSLATOR_LISTENER (Chord_name_engraver, note); void Chord_name_engraver::listen_note (Stream_event *ev) { notes_.push_back (ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Chord_name_engraver, rest); void Chord_name_engraver::listen_rest (Stream_event *ev) { @@ -168,6 +166,13 @@ Chord_name_engraver::stop_translation_timestep () The READs description is not strictly accurate: which properties are read depend on the chord naming function active. */ +void +Chord_name_engraver::boot () +{ + ADD_LISTENER (Chord_name_engraver, note); + ADD_LISTENER (Chord_name_engraver, rest); +} + ADD_TRANSLATOR (Chord_name_engraver, /* doc */ "Catch note and rest events and generate the appropriate chordname.", diff --git a/lily/chord-tremolo-engraver.cc b/lily/chord-tremolo-engraver.cc index 3855c350d7..9e704a222a 100644 --- a/lily/chord-tremolo-engraver.cc +++ b/lily/chord-tremolo-engraver.cc @@ -73,7 +73,6 @@ Chord_tremolo_engraver::Chord_tremolo_engraver () previous_stem_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Chord_tremolo_engraver, tremolo_span); void Chord_tremolo_engraver::listen_tremolo_span (Stream_event *ev) { @@ -158,7 +157,13 @@ Chord_tremolo_engraver::acknowledge_stem (Grob_info info) } } -ADD_ACKNOWLEDGER (Chord_tremolo_engraver, stem); +void +Chord_tremolo_engraver::boot () +{ + ADD_LISTENER (Chord_tremolo_engraver, tremolo_span); + ADD_ACKNOWLEDGER (Chord_tremolo_engraver, stem); +} + ADD_TRANSLATOR (Chord_tremolo_engraver, /* doc */ "Generate beams for tremolo repeats.", diff --git a/lily/clef-engraver.cc b/lily/clef-engraver.cc index 940a18d201..75adb6e3ee 100644 --- a/lily/clef-engraver.cc +++ b/lily/clef-engraver.cc @@ -203,7 +203,12 @@ Clef_engraver::stop_translation_timestep () } } -ADD_ACKNOWLEDGER (Clef_engraver, bar_line); +void +Clef_engraver::boot () +{ + ADD_ACKNOWLEDGER (Clef_engraver, bar_line); +} + ADD_TRANSLATOR (Clef_engraver, /* doc */ "Determine and set reference point for pitches.", diff --git a/lily/cluster-engraver.cc b/lily/cluster-engraver.cc index bb5ed0dc54..eac15a7690 100644 --- a/lily/cluster-engraver.cc +++ b/lily/cluster-engraver.cc @@ -81,7 +81,6 @@ Cluster_spanner_engraver::typeset_grobs () beacon_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Cluster_spanner_engraver, cluster_note); void Cluster_spanner_engraver::listen_cluster_note (Stream_event *ev) { @@ -142,7 +141,13 @@ Cluster_spanner_engraver::acknowledge_note_column (Grob_info info) } } -ADD_ACKNOWLEDGER (Cluster_spanner_engraver, note_column); +void +Cluster_spanner_engraver::boot () +{ + ADD_LISTENER (Cluster_spanner_engraver, cluster_note); + ADD_ACKNOWLEDGER (Cluster_spanner_engraver, note_column); +} + ADD_TRANSLATOR (Cluster_spanner_engraver, /* doc */ "Engrave a cluster using @code{Spanner} notation.", diff --git a/lily/collision-engraver.cc b/lily/collision-engraver.cc index d1eb2dd3c0..034726def9 100644 --- a/lily/collision-engraver.cc +++ b/lily/collision-engraver.cc @@ -78,7 +78,12 @@ Collision_engraver::Collision_engraver () col_ = 0; } -ADD_ACKNOWLEDGER (Collision_engraver, note_column); + +void +Collision_engraver::boot () +{ + ADD_ACKNOWLEDGER (Collision_engraver, note_column); +} ADD_TRANSLATOR (Collision_engraver, /* doc */ diff --git a/lily/completion-note-heads-engraver.cc b/lily/completion-note-heads-engraver.cc index 34a985d32d..e7a5dbc560 100644 --- a/lily/completion-note-heads-engraver.cc +++ b/lily/completion-note-heads-engraver.cc @@ -89,7 +89,6 @@ Completion_heads_engraver::initialize () is_first_ = false; } -IMPLEMENT_TRANSLATOR_LISTENER (Completion_heads_engraver, note); void Completion_heads_engraver::listen_note (Stream_event *ev) { @@ -307,6 +306,12 @@ Completion_heads_engraver::Completion_heads_engraver () tie_column_ = 0; } +void +Completion_heads_engraver::boot () +{ + ADD_LISTENER (Completion_heads_engraver, note); +} + ADD_TRANSLATOR (Completion_heads_engraver, /* doc */ "This engraver replaces @code{Note_heads_engraver}. It plays" diff --git a/lily/completion-rest-engraver.cc b/lily/completion-rest-engraver.cc index 8f809fde70..2f9dc56030 100644 --- a/lily/completion-rest-engraver.cc +++ b/lily/completion-rest-engraver.cc @@ -85,7 +85,6 @@ Completion_rest_engraver::initialize () is_first_ = false; } -IMPLEMENT_TRANSLATOR_LISTENER (Completion_rest_engraver, rest); void Completion_rest_engraver::listen_rest (Stream_event *ev) { @@ -258,6 +257,12 @@ Completion_rest_engraver::Completion_rest_engraver () { } +void +Completion_rest_engraver::boot () +{ + ADD_LISTENER (Completion_rest_engraver, rest); +} + ADD_TRANSLATOR (Completion_rest_engraver, /* doc */ "This engraver replaces @code{Rest_engraver}. It plays" diff --git a/lily/concurrent-hairpin-engraver.cc b/lily/concurrent-hairpin-engraver.cc index aa167b7de4..0fb9a13d0f 100644 --- a/lily/concurrent-hairpin-engraver.cc +++ b/lily/concurrent-hairpin-engraver.cc @@ -100,8 +100,13 @@ Concurrent_hairpin_engraver::finalize () hairpins_hanging_out_.resize (0); } -ADD_ACKNOWLEDGER (Concurrent_hairpin_engraver, hairpin); -ADD_END_ACKNOWLEDGER (Concurrent_hairpin_engraver, hairpin); + +void +Concurrent_hairpin_engraver::boot () +{ + ADD_ACKNOWLEDGER (Concurrent_hairpin_engraver, hairpin); + ADD_END_ACKNOWLEDGER (Concurrent_hairpin_engraver, hairpin); +} ADD_TRANSLATOR (Concurrent_hairpin_engraver, /* doc */ diff --git a/lily/control-track-performer.cc b/lily/control-track-performer.cc index 82beebe122..db6efe649e 100644 --- a/lily/control-track-performer.cc +++ b/lily/control-track-performer.cc @@ -66,6 +66,12 @@ Control_track_performer::initialize () add_text (Audio_text::TEXT, id_string); } +void +Control_track_performer::boot () +{ + +} + ADD_TRANSLATOR (Control_track_performer, /* doc */ "", diff --git a/lily/cue-clef-engraver.cc b/lily/cue-clef-engraver.cc index 383c9a1b1f..771eea4b79 100644 --- a/lily/cue-clef-engraver.cc +++ b/lily/cue-clef-engraver.cc @@ -209,7 +209,12 @@ Cue_clef_engraver::stop_translation_timestep () } } -ADD_ACKNOWLEDGER (Cue_clef_engraver, bar_line); +void +Cue_clef_engraver::boot () +{ + ADD_ACKNOWLEDGER (Cue_clef_engraver, bar_line); +} + ADD_TRANSLATOR (Cue_clef_engraver, /* doc */ "Determine and set reference point for pitches in cued voices.", diff --git a/lily/custos-engraver.cc b/lily/custos-engraver.cc index 5893dc205b..517e53aece 100644 --- a/lily/custos-engraver.cc +++ b/lily/custos-engraver.cc @@ -142,8 +142,13 @@ Custos_engraver::finalize () custodes_.clear (); } -ADD_ACKNOWLEDGER (Custos_engraver, bar); -ADD_ACKNOWLEDGER (Custos_engraver, note_head); + +void +Custos_engraver::boot () +{ + ADD_ACKNOWLEDGER (Custos_engraver, bar); + ADD_ACKNOWLEDGER (Custos_engraver, note_head); +} ADD_TRANSLATOR (Custos_engraver, /* doc */ diff --git a/lily/default-bar-line-engraver.cc b/lily/default-bar-line-engraver.cc index 4eeb230367..a8b9898276 100644 --- a/lily/default-bar-line-engraver.cc +++ b/lily/default-bar-line-engraver.cc @@ -37,6 +37,12 @@ public: #include "translator.icc" +void +Default_bar_line_engraver::boot () +{ + +} + ADD_TRANSLATOR (Default_bar_line_engraver, /* doc */ "This engraver determines what kind of automatic bar lines" diff --git a/lily/dot-column-engraver.cc b/lily/dot-column-engraver.cc index c646ed038c..a300b6f3a1 100644 --- a/lily/dot-column-engraver.cc +++ b/lily/dot-column-engraver.cc @@ -61,7 +61,12 @@ Dot_column_engraver::acknowledge_rhythmic_head (Grob_info info) } } -ADD_ACKNOWLEDGER (Dot_column_engraver, rhythmic_head); +void +Dot_column_engraver::boot () +{ + ADD_ACKNOWLEDGER (Dot_column_engraver, rhythmic_head); +} + ADD_TRANSLATOR (Dot_column_engraver, /* doc */ "Engrave dots on dotted notes shifted to the right of the" diff --git a/lily/dots-engraver.cc b/lily/dots-engraver.cc index 5465f460f6..4bf379124d 100644 --- a/lily/dots-engraver.cc +++ b/lily/dots-engraver.cc @@ -56,7 +56,12 @@ Dots_engraver::acknowledge_rhythmic_head (Grob_info gi) } } -ADD_ACKNOWLEDGER (Dots_engraver, rhythmic_head); + +void +Dots_engraver::boot () +{ + ADD_ACKNOWLEDGER (Dots_engraver, rhythmic_head); +} ADD_TRANSLATOR (Dots_engraver, "Create @ref{Dots} objects for" diff --git a/lily/double-percent-repeat-engraver.cc b/lily/double-percent-repeat-engraver.cc index d85648293e..f50f8f8108 100644 --- a/lily/double-percent-repeat-engraver.cc +++ b/lily/double-percent-repeat-engraver.cc @@ -48,7 +48,6 @@ Double_percent_repeat_engraver::Double_percent_repeat_engraver () percent_event_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Double_percent_repeat_engraver, double_percent); void Double_percent_repeat_engraver::listen_double_percent (Stream_event *ev) { @@ -95,6 +94,12 @@ Double_percent_repeat_engraver::process_music () } } +void +Double_percent_repeat_engraver::boot () +{ + ADD_LISTENER (Double_percent_repeat_engraver, double_percent); +} + ADD_TRANSLATOR (Double_percent_repeat_engraver, /* doc */ "Make double measure repeats.", diff --git a/lily/drum-note-engraver.cc b/lily/drum-note-engraver.cc index 09a58fa24b..d78e2ba3d1 100644 --- a/lily/drum-note-engraver.cc +++ b/lily/drum-note-engraver.cc @@ -53,7 +53,6 @@ Drum_notes_engraver::Drum_notes_engraver () { } -IMPLEMENT_TRANSLATOR_LISTENER (Drum_notes_engraver, note); void Drum_notes_engraver::listen_note (Stream_event *ev) { @@ -140,8 +139,14 @@ Drum_notes_engraver::stop_translation_timestep () events_.clear (); } -ADD_ACKNOWLEDGER (Drum_notes_engraver, stem); -ADD_ACKNOWLEDGER (Drum_notes_engraver, note_column); + +void +Drum_notes_engraver::boot () +{ + ADD_LISTENER (Drum_notes_engraver, note); + ADD_ACKNOWLEDGER (Drum_notes_engraver, stem); + ADD_ACKNOWLEDGER (Drum_notes_engraver, note_column); +} ADD_TRANSLATOR (Drum_notes_engraver, /* doc */ diff --git a/lily/drum-note-performer.cc b/lily/drum-note-performer.cc index 0285de6504..88c1a61d05 100644 --- a/lily/drum-note-performer.cc +++ b/lily/drum-note-performer.cc @@ -96,13 +96,18 @@ Drum_note_performer::stop_translation_timestep () note_evs_.clear (); } -IMPLEMENT_TRANSLATOR_LISTENER (Drum_note_performer, note); void Drum_note_performer::listen_note (Stream_event *ev) { note_evs_.push_back (ev); } +void +Drum_note_performer::boot () +{ + ADD_LISTENER (Drum_note_performer, note); +} + ADD_TRANSLATOR (Drum_note_performer, /* doc */ "Play drum notes.", diff --git a/lily/dynamic-align-engraver.cc b/lily/dynamic-align-engraver.cc index 0abb39a7f2..29f35b4f61 100644 --- a/lily/dynamic-align-engraver.cc +++ b/lily/dynamic-align-engraver.cc @@ -64,11 +64,6 @@ Dynamic_align_engraver::Dynamic_align_engraver () current_dynamic_spanner_ = 0; } -ADD_ACKNOWLEDGER (Dynamic_align_engraver, dynamic); -ADD_ACKNOWLEDGER (Dynamic_align_engraver, rhythmic_head); -ADD_ACKNOWLEDGER (Dynamic_align_engraver, stem); -ADD_ACKNOWLEDGER (Dynamic_align_engraver, footnote_spanner); -ADD_END_ACKNOWLEDGER (Dynamic_align_engraver, dynamic); void Dynamic_align_engraver::create_line_spanner (Grob *cause) @@ -232,6 +227,16 @@ Dynamic_align_engraver::stop_translation_timestep () support_.clear (); } +void +Dynamic_align_engraver::boot () +{ + ADD_ACKNOWLEDGER (Dynamic_align_engraver, dynamic); + ADD_ACKNOWLEDGER (Dynamic_align_engraver, rhythmic_head); + ADD_ACKNOWLEDGER (Dynamic_align_engraver, stem); + ADD_ACKNOWLEDGER (Dynamic_align_engraver, footnote_spanner); + ADD_END_ACKNOWLEDGER (Dynamic_align_engraver, dynamic); +} + ADD_TRANSLATOR (Dynamic_align_engraver, /* doc */ "Align hairpins and dynamic texts on a horizontal line.", diff --git a/lily/dynamic-engraver.cc b/lily/dynamic-engraver.cc index edfd35fcb5..6df34baf67 100644 --- a/lily/dynamic-engraver.cc +++ b/lily/dynamic-engraver.cc @@ -69,14 +69,12 @@ Dynamic_engraver::Dynamic_engraver () end_new_spanner_ = false; } -IMPLEMENT_TRANSLATOR_LISTENER (Dynamic_engraver, absolute_dynamic); void Dynamic_engraver::listen_absolute_dynamic (Stream_event *ev) { ASSIGN_EVENT_ONCE (script_event_, ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Dynamic_engraver, span_dynamic); void Dynamic_engraver::listen_span_dynamic (Stream_event *ev) { @@ -85,7 +83,6 @@ Dynamic_engraver::listen_span_dynamic (Stream_event *ev) ASSIGN_EVENT_ONCE (accepted_spanevents_drul_[d], ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Dynamic_engraver, break_span); void Dynamic_engraver::listen_break_span (Stream_event *event) { @@ -278,7 +275,15 @@ Dynamic_engraver::acknowledge_note_column (Grob_info info) finished_spanner_->set_bound (RIGHT, info.grob ()); } -ADD_ACKNOWLEDGER (Dynamic_engraver, note_column); +void +Dynamic_engraver::boot () +{ + ADD_LISTENER (Dynamic_engraver, absolute_dynamic); + ADD_LISTENER (Dynamic_engraver, span_dynamic); + ADD_LISTENER (Dynamic_engraver, break_span); + ADD_ACKNOWLEDGER (Dynamic_engraver, note_column); +} + ADD_TRANSLATOR (Dynamic_engraver, /* doc */ "Create hairpins, dynamic texts and dynamic text spanners.", diff --git a/lily/dynamic-performer.cc b/lily/dynamic-performer.cc index 6a6f8b8cf9..567184412e 100644 --- a/lily/dynamic-performer.cc +++ b/lily/dynamic-performer.cc @@ -206,7 +206,6 @@ Dynamic_performer::stop_translation_timestep () = span_events_[RIGHT] = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Dynamic_performer, decrescendo); void Dynamic_performer::listen_decrescendo (Stream_event *r) { @@ -215,7 +214,6 @@ Dynamic_performer::listen_decrescendo (Stream_event *r) grow_dir_[d] = SMALLER; } -IMPLEMENT_TRANSLATOR_LISTENER (Dynamic_performer, crescendo); void Dynamic_performer::listen_crescendo (Stream_event *r) { @@ -224,7 +222,6 @@ Dynamic_performer::listen_crescendo (Stream_event *r) grow_dir_[d] = BIGGER; } -IMPLEMENT_TRANSLATOR_LISTENER (Dynamic_performer, absolute_dynamic); void Dynamic_performer::listen_absolute_dynamic (Stream_event *r) { @@ -232,6 +229,14 @@ Dynamic_performer::listen_absolute_dynamic (Stream_event *r) script_event_ = r; } +void +Dynamic_performer::boot () +{ + ADD_LISTENER (Dynamic_performer, decrescendo); + ADD_LISTENER (Dynamic_performer, crescendo); + ADD_LISTENER (Dynamic_performer, absolute_dynamic); +} + ADD_TRANSLATOR (Dynamic_performer, /* doc */ "", diff --git a/lily/episema-engraver.cc b/lily/episema-engraver.cc index a62ed3726f..dbbda29130 100644 --- a/lily/episema-engraver.cc +++ b/lily/episema-engraver.cc @@ -56,7 +56,6 @@ Episema_engraver::Episema_engraver () event_drul_.set (0, 0); } -IMPLEMENT_TRANSLATOR_LISTENER (Episema_engraver, episema); void Episema_engraver::listen_episema (Stream_event *ev) { @@ -161,8 +160,14 @@ Episema_engraver::acknowledge_note_head (Grob_info info) } } -ADD_ACKNOWLEDGER (Episema_engraver, note_column); -ADD_ACKNOWLEDGER (Episema_engraver, note_head); + +void +Episema_engraver::boot () +{ + ADD_LISTENER (Episema_engraver, episema); + ADD_ACKNOWLEDGER (Episema_engraver, note_column); + ADD_ACKNOWLEDGER (Episema_engraver, note_head); +} ADD_TRANSLATOR (Episema_engraver, /* doc */ diff --git a/lily/extender-engraver.cc b/lily/extender-engraver.cc index 3f3ef3b3ff..2d96c400b6 100644 --- a/lily/extender-engraver.cc +++ b/lily/extender-engraver.cc @@ -60,7 +60,6 @@ Extender_engraver::Extender_engraver () ev_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Extender_engraver, extender); void Extender_engraver::listen_extender (Stream_event *ev) { @@ -73,7 +72,6 @@ Extender_engraver::listen_extender (Stream_event *ev) end before the associated voice (this prevents the right bound being extended to the next note-column if no lyric follows the extender) */ -IMPLEMENT_TRANSLATOR_LISTENER (Extender_engraver, completize_extender); void Extender_engraver::listen_completize_extender (Stream_event * /* ev */) { @@ -180,7 +178,14 @@ Extender_engraver::finalize () } } -ADD_ACKNOWLEDGER (Extender_engraver, lyric_syllable); +void +Extender_engraver::boot () +{ + ADD_LISTENER (Extender_engraver, extender); + ADD_LISTENER (Extender_engraver, completize_extender); + ADD_ACKNOWLEDGER (Extender_engraver, lyric_syllable); +} + ADD_TRANSLATOR (Extender_engraver, /* doc */ "Create lyric extenders.", diff --git a/lily/figured-bass-engraver.cc b/lily/figured-bass-engraver.cc index 2ed07e3e83..e9bd19291c 100644 --- a/lily/figured-bass-engraver.cc +++ b/lily/figured-bass-engraver.cc @@ -180,14 +180,12 @@ Figured_bass_engraver::stop_translation_timestep () clear_spanners (); } -IMPLEMENT_TRANSLATOR_LISTENER (Figured_bass_engraver, rest); void Figured_bass_engraver::listen_rest (Stream_event *) { have_rest_ = true; } -IMPLEMENT_TRANSLATOR_LISTENER (Figured_bass_engraver, bass_figure); void Figured_bass_engraver::listen_bass_figure (Stream_event *ev) { @@ -504,6 +502,13 @@ Figured_bass_engraver::add_brackets () } } +void +Figured_bass_engraver::boot () +{ + ADD_LISTENER (Figured_bass_engraver, rest); + ADD_LISTENER (Figured_bass_engraver, bass_figure); +} + ADD_TRANSLATOR (Figured_bass_engraver, /* doc */ "Make figured bass numbers.", diff --git a/lily/figured-bass-position-engraver.cc b/lily/figured-bass-position-engraver.cc index c1df4623e6..9dadfc58ce 100644 --- a/lily/figured-bass-position-engraver.cc +++ b/lily/figured-bass-position-engraver.cc @@ -138,13 +138,18 @@ Figured_bass_position_engraver::acknowledge_bass_figure_alignment (Grob_info inf start_spanner (); } -ADD_ACKNOWLEDGER (Figured_bass_position_engraver, note_column); -ADD_ACKNOWLEDGER (Figured_bass_position_engraver, slur); -ADD_END_ACKNOWLEDGER (Figured_bass_position_engraver, slur); -ADD_END_ACKNOWLEDGER (Figured_bass_position_engraver, tie); -ADD_ACKNOWLEDGER (Figured_bass_position_engraver, bass_figure_alignment); -ADD_END_ACKNOWLEDGER (Figured_bass_position_engraver, bass_figure_alignment); + +void +Figured_bass_position_engraver::boot () +{ + ADD_ACKNOWLEDGER (Figured_bass_position_engraver, note_column); + ADD_ACKNOWLEDGER (Figured_bass_position_engraver, slur); + ADD_END_ACKNOWLEDGER (Figured_bass_position_engraver, slur); + ADD_END_ACKNOWLEDGER (Figured_bass_position_engraver, tie); + ADD_ACKNOWLEDGER (Figured_bass_position_engraver, bass_figure_alignment); + ADD_END_ACKNOWLEDGER (Figured_bass_position_engraver, bass_figure_alignment); +} ADD_TRANSLATOR (Figured_bass_position_engraver, /* doc */ diff --git a/lily/fingering-column-engraver.cc b/lily/fingering-column-engraver.cc index 1c5b904809..466d8e281c 100644 --- a/lily/fingering-column-engraver.cc +++ b/lily/fingering-column-engraver.cc @@ -101,7 +101,12 @@ Fingering_column_engraver::process_acknowledged () } } -ADD_ACKNOWLEDGER (Fingering_column_engraver, finger); +void +Fingering_column_engraver::boot () +{ + ADD_ACKNOWLEDGER (Fingering_column_engraver, finger); +} + ADD_TRANSLATOR (Fingering_column_engraver, /* doc */ "Find potentially colliding scripts and put them into a" diff --git a/lily/fingering-engraver.cc b/lily/fingering-engraver.cc index d5b4102d8b..4e5a6577fa 100644 --- a/lily/fingering-engraver.cc +++ b/lily/fingering-engraver.cc @@ -47,7 +47,6 @@ private: void make_script (Direction, Stream_event *, int); }; -IMPLEMENT_TRANSLATOR_LISTENER (Fingering_engraver, fingering); void Fingering_engraver::listen_fingering (Stream_event *ev) { @@ -141,9 +140,15 @@ Fingering_engraver::Fingering_engraver () { } -ADD_ACKNOWLEDGER (Fingering_engraver, rhythmic_head); -ADD_ACKNOWLEDGER (Fingering_engraver, stem); -ADD_ACKNOWLEDGER (Fingering_engraver, flag); + +void +Fingering_engraver::boot () +{ + ADD_LISTENER (Fingering_engraver, fingering); + ADD_ACKNOWLEDGER (Fingering_engraver, rhythmic_head); + ADD_ACKNOWLEDGER (Fingering_engraver, stem); + ADD_ACKNOWLEDGER (Fingering_engraver, flag); +} ADD_TRANSLATOR (Fingering_engraver, /* doc */ diff --git a/lily/font-size-engraver.cc b/lily/font-size-engraver.cc index b9250358dd..6618c6d482 100644 --- a/lily/font-size-engraver.cc +++ b/lily/font-size-engraver.cc @@ -61,7 +61,12 @@ Font_size_engraver::acknowledge_font (Grob_info gi) #include "translator.icc" -ADD_ACKNOWLEDGER (Font_size_engraver, font); +void +Font_size_engraver::boot () +{ + ADD_ACKNOWLEDGER (Font_size_engraver, font); +} + ADD_TRANSLATOR (Font_size_engraver, /* doc */ "Put @code{fontSize} into @code{font-size} grob property.", diff --git a/lily/footnote-engraver.cc b/lily/footnote-engraver.cc index 636379125f..857d08fcef 100644 --- a/lily/footnote-engraver.cc +++ b/lily/footnote-engraver.cc @@ -114,8 +114,13 @@ Footnote_engraver::acknowledge_end_grob (Grob_info info) } } -ADD_ACKNOWLEDGER (Footnote_engraver, grob); -ADD_END_ACKNOWLEDGER (Footnote_engraver, grob); + +void +Footnote_engraver::boot () +{ + ADD_ACKNOWLEDGER (Footnote_engraver, grob); + ADD_END_ACKNOWLEDGER (Footnote_engraver, grob); +} ADD_TRANSLATOR (Footnote_engraver, /* doc */ diff --git a/lily/forbid-break-engraver.cc b/lily/forbid-break-engraver.cc index db0e254739..9cfdef24c8 100644 --- a/lily/forbid-break-engraver.cc +++ b/lily/forbid-break-engraver.cc @@ -58,6 +58,12 @@ Forbid_line_break_engraver::start_translation_timestep () } } +void +Forbid_line_break_engraver::boot () +{ + +} + ADD_TRANSLATOR (Forbid_line_break_engraver, /* doc */ "Forbid line breaks when note heads are still playing at some" diff --git a/lily/fretboard-engraver.cc b/lily/fretboard-engraver.cc index 2ce799bf0f..239ee54eb6 100644 --- a/lily/fretboard-engraver.cc +++ b/lily/fretboard-engraver.cc @@ -68,21 +68,18 @@ Fretboard_engraver::Fretboard_engraver () last_placements_ = SCM_BOOL_F; } -IMPLEMENT_TRANSLATOR_LISTENER (Fretboard_engraver, note); void Fretboard_engraver::listen_note (Stream_event *ev) { note_events_.push_back (ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Fretboard_engraver, string_number); void Fretboard_engraver::listen_string_number (Stream_event *ev) { tabstring_events_.push_back (ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Fretboard_engraver, fingering); void Fretboard_engraver::listen_fingering (Stream_event *ev) { @@ -128,6 +125,14 @@ Fretboard_engraver::stop_translation_timestep () fingering_events_.clear (); } +void +Fretboard_engraver::boot () +{ + ADD_LISTENER (Fretboard_engraver, note); + ADD_LISTENER (Fretboard_engraver, string_number); + ADD_LISTENER (Fretboard_engraver, fingering); +} + ADD_TRANSLATOR (Fretboard_engraver, /* doc */ "Generate fret diagram from one or more events of type" diff --git a/lily/glissando-engraver.cc b/lily/glissando-engraver.cc index c7744d1f4b..853ba8f279 100644 --- a/lily/glissando-engraver.cc +++ b/lily/glissando-engraver.cc @@ -60,7 +60,6 @@ Glissando_engraver::Glissando_engraver () stop_glissandi_ = false; } -IMPLEMENT_TRANSLATOR_LISTENER (Glissando_engraver, glissando); void Glissando_engraver::listen_glissando (Stream_event *ev) { @@ -170,7 +169,13 @@ Glissando_engraver::finalize () kill_me_[i]->suicide (); } -ADD_ACKNOWLEDGER (Glissando_engraver, note_column); +void +Glissando_engraver::boot () +{ + ADD_LISTENER (Glissando_engraver, glissando); + ADD_ACKNOWLEDGER (Glissando_engraver, note_column); +} + ADD_TRANSLATOR (Glissando_engraver, /* doc */ "Engrave glissandi.", diff --git a/lily/grace-engraver.cc b/lily/grace-engraver.cc index 5279cab4c0..57ccb1e0fa 100644 --- a/lily/grace-engraver.cc +++ b/lily/grace-engraver.cc @@ -157,6 +157,12 @@ Grace_engraver::derived_mark () const Engraver::derived_mark (); } +void +Grace_engraver::boot () +{ + +} + ADD_TRANSLATOR (Grace_engraver, /* doc */ "Set font size and other properties for grace notes.", diff --git a/lily/grace-spacing-engraver.cc b/lily/grace-spacing-engraver.cc index 5da9c90b5c..445d2b0f81 100644 --- a/lily/grace-spacing-engraver.cc +++ b/lily/grace-spacing-engraver.cc @@ -77,6 +77,12 @@ Grace_spacing_engraver::stop_translation_timestep () grace_spacing_ = 0; } +void +Grace_spacing_engraver::boot () +{ + +} + ADD_TRANSLATOR (Grace_spacing_engraver, "Bookkeeping of shortest starting and playing notes in grace" " note runs.", diff --git a/lily/grid-line-span-engraver.cc b/lily/grid-line-span-engraver.cc index a61f61df78..e27e502c07 100644 --- a/lily/grid-line-span-engraver.cc +++ b/lily/grid-line-span-engraver.cc @@ -70,7 +70,12 @@ Grid_line_span_engraver::stop_translation_timestep () lines_.resize (0); } -ADD_ACKNOWLEDGER (Grid_line_span_engraver, grid_point); +void +Grid_line_span_engraver::boot () +{ + ADD_ACKNOWLEDGER (Grid_line_span_engraver, grid_point); +} + ADD_TRANSLATOR (Grid_line_span_engraver, /* doc */ "This engraver makes cross-staff lines: It catches all normal" diff --git a/lily/grid-point-engraver.cc b/lily/grid-point-engraver.cc index f436195787..d67fb191b6 100644 --- a/lily/grid-point-engraver.cc +++ b/lily/grid-point-engraver.cc @@ -48,6 +48,12 @@ Grid_point_engraver::Grid_point_engraver () { } +void +Grid_point_engraver::boot () +{ + +} + ADD_TRANSLATOR (Grid_point_engraver, /* doc */ "Generate grid points.", diff --git a/lily/grob-pq-engraver.cc b/lily/grob-pq-engraver.cc index 45b4ff2b35..4c388c5145 100644 --- a/lily/grob-pq-engraver.cc +++ b/lily/grob-pq-engraver.cc @@ -148,7 +148,12 @@ Grob_pq_engraver::start_translation_timestep () context ()->set_property ("busyGrobs", busy); } -ADD_ACKNOWLEDGER (Grob_pq_engraver, grob); +void +Grob_pq_engraver::boot () +{ + ADD_ACKNOWLEDGER (Grob_pq_engraver, grob); +} + ADD_TRANSLATOR (Grob_pq_engraver, /* doc */ "Administrate when certain grobs (e.g., note heads) stop" diff --git a/lily/horizontal-bracket-engraver.cc b/lily/horizontal-bracket-engraver.cc index cd46817904..2e7f2b6294 100644 --- a/lily/horizontal-bracket-engraver.cc +++ b/lily/horizontal-bracket-engraver.cc @@ -49,7 +49,6 @@ Horizontal_bracket_engraver::Horizontal_bracket_engraver () push_count_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Horizontal_bracket_engraver, note_grouping); void Horizontal_bracket_engraver::listen_note_grouping (Stream_event *ev) { @@ -109,7 +108,13 @@ Horizontal_bracket_engraver::stop_translation_timestep () events_.clear (); } -ADD_ACKNOWLEDGER (Horizontal_bracket_engraver, note_column); +void +Horizontal_bracket_engraver::boot () +{ + ADD_LISTENER (Horizontal_bracket_engraver, note_grouping); + ADD_ACKNOWLEDGER (Horizontal_bracket_engraver, note_column); +} + ADD_TRANSLATOR (Horizontal_bracket_engraver, /* doc */ "Create horizontal brackets over notes for musical analysis" diff --git a/lily/hyphen-engraver.cc b/lily/hyphen-engraver.cc index be43665556..ef1013b979 100644 --- a/lily/hyphen-engraver.cc +++ b/lily/hyphen-engraver.cc @@ -74,7 +74,6 @@ Hyphen_engraver::acknowledge_lyric_syllable (Grob_info i) finished_hyphen_->set_bound (RIGHT, item); } -IMPLEMENT_TRANSLATOR_LISTENER (Hyphen_engraver, hyphen); void Hyphen_engraver::listen_hyphen (Stream_event *ev) { @@ -155,7 +154,13 @@ Hyphen_engraver::stop_translation_timestep () ev_ = 0; } -ADD_ACKNOWLEDGER (Hyphen_engraver, lyric_syllable); + +void +Hyphen_engraver::boot () +{ + ADD_LISTENER (Hyphen_engraver, hyphen); + ADD_ACKNOWLEDGER (Hyphen_engraver, lyric_syllable); +} ADD_TRANSLATOR (Hyphen_engraver, /* doc */ diff --git a/lily/instrument-name-engraver.cc b/lily/instrument-name-engraver.cc index d339fbce61..a0263d930f 100644 --- a/lily/instrument-name-engraver.cc +++ b/lily/instrument-name-engraver.cc @@ -173,7 +173,12 @@ Instrument_name_engraver::stop_spanner () text_spanner_ = 0; } -ADD_ACKNOWLEDGER (Instrument_name_engraver, axis_group); + +void +Instrument_name_engraver::boot () +{ + ADD_ACKNOWLEDGER (Instrument_name_engraver, axis_group); +} ADD_TRANSLATOR (Instrument_name_engraver, /* doc */ diff --git a/lily/instrument-switch-engraver.cc b/lily/instrument-switch-engraver.cc index 67a58c7e6f..59cbb4f13c 100644 --- a/lily/instrument-switch-engraver.cc +++ b/lily/instrument-switch-engraver.cc @@ -75,6 +75,12 @@ Instrument_switch_engraver::stop_translation_time_step () text_ = 0; } +void +Instrument_switch_engraver::boot () +{ + +} + ADD_TRANSLATOR (Instrument_switch_engraver, /* doc */ "Create a cue text for taking instrument.", diff --git a/lily/keep-alive-together-engraver.cc b/lily/keep-alive-together-engraver.cc index 79fedc96df..83699da593 100644 --- a/lily/keep-alive-together-engraver.cc +++ b/lily/keep-alive-together-engraver.cc @@ -88,7 +88,12 @@ Keep_alive_together_engraver::finalize () } } -ADD_ACKNOWLEDGER (Keep_alive_together_engraver, hara_kiri_group_spanner); + +void +Keep_alive_together_engraver::boot () +{ + ADD_ACKNOWLEDGER (Keep_alive_together_engraver, hara_kiri_group_spanner); +} ADD_TRANSLATOR (Keep_alive_together_engraver, /* doc */ diff --git a/lily/key-engraver.cc b/lily/key-engraver.cc index 971f553172..635f293120 100644 --- a/lily/key-engraver.cc +++ b/lily/key-engraver.cc @@ -120,7 +120,6 @@ Key_engraver::create_key (bool is_default) } } -IMPLEMENT_TRANSLATOR_LISTENER (Key_engraver, key_change); void Key_engraver::listen_key_change (Stream_event *ev) { @@ -212,8 +211,14 @@ Key_engraver::initialize () context ()->set_property ("tonic", p.smobbed_copy ()); } -ADD_ACKNOWLEDGER (Key_engraver, clef); -ADD_ACKNOWLEDGER (Key_engraver, bar_line); + +void +Key_engraver::boot () +{ + ADD_LISTENER (Key_engraver, key_change); + ADD_ACKNOWLEDGER (Key_engraver, clef); + ADD_ACKNOWLEDGER (Key_engraver, bar_line); +} ADD_TRANSLATOR (Key_engraver, /* doc */ diff --git a/lily/key-performer.cc b/lily/key-performer.cc index 06666ac532..568357573d 100644 --- a/lily/key-performer.cc +++ b/lily/key-performer.cc @@ -98,7 +98,6 @@ Key_performer::stop_translation_timestep () } } -IMPLEMENT_TRANSLATOR_LISTENER (Key_performer, key_change); void Key_performer::listen_key_change (Stream_event *ev) { @@ -106,6 +105,12 @@ Key_performer::listen_key_change (Stream_event *ev) key_ev_ = ev; } +void +Key_performer::boot () +{ + ADD_LISTENER (Key_performer, key_change); +} + ADD_TRANSLATOR (Key_performer, /* doc */ "", diff --git a/lily/kievan-ligature-engraver.cc b/lily/kievan-ligature-engraver.cc index 791f0b1f1c..42c48a551e 100644 --- a/lily/kievan-ligature-engraver.cc +++ b/lily/kievan-ligature-engraver.cc @@ -46,7 +46,6 @@ private: void fold_up_primitives (vector<Grob_info> const &primitives, Real padding, Real &min_length); }; -IMPLEMENT_TRANSLATOR_LISTENER (Kievan_ligature_engraver, ligature); void Kievan_ligature_engraver::listen_ligature (Stream_event *ev) { @@ -136,8 +135,14 @@ Kievan_ligature_engraver::build_ligature (Spanner *ligature, } -ADD_ACKNOWLEDGER (Kievan_ligature_engraver, rest); -ADD_ACKNOWLEDGER (Kievan_ligature_engraver, ligature_head); + +void +Kievan_ligature_engraver::boot () +{ + ADD_LISTENER (Kievan_ligature_engraver, ligature); + ADD_ACKNOWLEDGER (Kievan_ligature_engraver, rest); + ADD_ACKNOWLEDGER (Kievan_ligature_engraver, ligature_head); +} ADD_TRANSLATOR (Kievan_ligature_engraver, /* doc */ diff --git a/lily/laissez-vibrer-engraver.cc b/lily/laissez-vibrer-engraver.cc index 6e57a7e9df..11e379aeed 100644 --- a/lily/laissez-vibrer-engraver.cc +++ b/lily/laissez-vibrer-engraver.cc @@ -53,7 +53,6 @@ Laissez_vibrer_engraver::stop_translation_timestep () lv_ties_.clear (); } -IMPLEMENT_TRANSLATOR_LISTENER (Laissez_vibrer_engraver, laissez_vibrer); void Laissez_vibrer_engraver::listen_laissez_vibrer (Stream_event *ev) { @@ -104,7 +103,13 @@ Laissez_vibrer_engraver::acknowledge_note_head (Grob_info inf) lv_ties_.push_back (lv_tie); } -ADD_ACKNOWLEDGER (Laissez_vibrer_engraver, note_head); +void +Laissez_vibrer_engraver::boot () +{ + ADD_LISTENER (Laissez_vibrer_engraver, laissez_vibrer); + ADD_ACKNOWLEDGER (Laissez_vibrer_engraver, note_head); +} + ADD_TRANSLATOR (Laissez_vibrer_engraver, /* doc */ "Create laissez vibrer items.", diff --git a/lily/ledger-line-engraver.cc b/lily/ledger-line-engraver.cc index 8e871c1abf..ba52d62f67 100644 --- a/lily/ledger-line-engraver.cc +++ b/lily/ledger-line-engraver.cc @@ -120,8 +120,13 @@ Ledger_line_engraver::acknowledge_ledgered (Grob_info s) ledgered_grobs_.push_back (s.grob ()); } -ADD_ACKNOWLEDGER (Ledger_line_engraver, ledgered); -ADD_ACKNOWLEDGER (Ledger_line_engraver, staff_symbol); +void +Ledger_line_engraver::boot () +{ + ADD_ACKNOWLEDGER (Ledger_line_engraver, ledgered); + ADD_ACKNOWLEDGER (Ledger_line_engraver, staff_symbol); +} + ADD_TRANSLATOR (Ledger_line_engraver, /* doc */ "Create the spanner to draw ledger lines, and notices" diff --git a/lily/ligature-bracket-engraver.cc b/lily/ligature-bracket-engraver.cc index bc3d379c22..7c0a8d6e2f 100644 --- a/lily/ligature-bracket-engraver.cc +++ b/lily/ligature-bracket-engraver.cc @@ -46,7 +46,6 @@ private: Stream_event *previous_start_event_; }; -IMPLEMENT_TRANSLATOR_LISTENER (Ligature_bracket_engraver, ligature); void Ligature_bracket_engraver::listen_ligature (Stream_event *ev) { @@ -116,8 +115,14 @@ Ligature_bracket_engraver::stop_translation_timestep () finished_ligature_ = 0; } -ADD_ACKNOWLEDGER (Ligature_bracket_engraver, rest); -ADD_ACKNOWLEDGER (Ligature_bracket_engraver, note_column); + +void +Ligature_bracket_engraver::boot () +{ + ADD_LISTENER (Ligature_bracket_engraver, ligature); + ADD_ACKNOWLEDGER (Ligature_bracket_engraver, rest); + ADD_ACKNOWLEDGER (Ligature_bracket_engraver, note_column); +} ADD_TRANSLATOR (Ligature_bracket_engraver, /* doc */ diff --git a/lily/lyric-engraver.cc b/lily/lyric-engraver.cc index cdee61517e..f051cfcb0a 100644 --- a/lily/lyric-engraver.cc +++ b/lily/lyric-engraver.cc @@ -56,7 +56,6 @@ Lyric_engraver::Lyric_engraver () event_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Lyric_engraver, lyric); void Lyric_engraver::listen_lyric (Stream_event *ev) { @@ -194,6 +193,12 @@ Lyric_engraver::stop_translation_timestep () event_ = 0; } +void +Lyric_engraver::boot () +{ + ADD_LISTENER (Lyric_engraver, lyric); +} + ADD_TRANSLATOR (Lyric_engraver, /* doc */ "Engrave text for lyrics.", diff --git a/lily/lyric-performer.cc b/lily/lyric-performer.cc index 0ad69ae053..1215cc7d55 100644 --- a/lily/lyric-performer.cc +++ b/lily/lyric-performer.cc @@ -67,13 +67,18 @@ Lyric_performer::stop_translation_timestep () events_.clear (); } -IMPLEMENT_TRANSLATOR_LISTENER (Lyric_performer, lyric); void Lyric_performer::listen_lyric (Stream_event *event) { events_.push_back (event); } +void +Lyric_performer::boot () +{ + ADD_LISTENER (Lyric_performer, lyric); +} + ADD_TRANSLATOR (Lyric_performer, /* doc */ "", diff --git a/lily/mark-engraver.cc b/lily/mark-engraver.cc index 7db0a781cc..76105f14dc 100644 --- a/lily/mark-engraver.cc +++ b/lily/mark-engraver.cc @@ -111,7 +111,6 @@ Mark_engraver::create_items (Stream_event *ev) text_ = make_item ("RehearsalMark", ev->self_scm ()); } -IMPLEMENT_TRANSLATOR_LISTENER (Mark_engraver, mark); void Mark_engraver::listen_mark (Stream_event *ev) { @@ -157,7 +156,13 @@ Mark_engraver::process_music () } } -ADD_ACKNOWLEDGER (Mark_engraver, break_alignment); + +void +Mark_engraver::boot () +{ + ADD_LISTENER (Mark_engraver, mark); + ADD_ACKNOWLEDGER (Mark_engraver, break_alignment); +} ADD_TRANSLATOR (Mark_engraver, /* doc */ diff --git a/lily/measure-grouping-engraver.cc b/lily/measure-grouping-engraver.cc index e7fc3c6726..71e06d1747 100644 --- a/lily/measure-grouping-engraver.cc +++ b/lily/measure-grouping-engraver.cc @@ -119,7 +119,12 @@ Measure_grouping_engraver::Measure_grouping_engraver () grouping_ = 0; } -ADD_ACKNOWLEDGER (Measure_grouping_engraver, note_column); +void +Measure_grouping_engraver::boot () +{ + ADD_ACKNOWLEDGER (Measure_grouping_engraver, note_column); +} + ADD_TRANSLATOR (Measure_grouping_engraver, /* doc */ "Create @code{MeasureGrouping} to indicate beat subdivision.", diff --git a/lily/melody-engraver.cc b/lily/melody-engraver.cc index 2d982056d3..e7cf07292a 100644 --- a/lily/melody-engraver.cc +++ b/lily/melody-engraver.cc @@ -93,8 +93,13 @@ Melody_engraver::acknowledge_stem (Grob_info info) #include "translator.icc" -ADD_ACKNOWLEDGER (Melody_engraver, stem); -ADD_ACKNOWLEDGER (Melody_engraver, slur); + +void +Melody_engraver::boot () +{ + ADD_ACKNOWLEDGER (Melody_engraver, stem); + ADD_ACKNOWLEDGER (Melody_engraver, slur); +} ADD_TRANSLATOR (Melody_engraver, /* doc */ diff --git a/lily/mensural-ligature-engraver.cc b/lily/mensural-ligature-engraver.cc index bfa30550e5..b6a83f7d3e 100644 --- a/lily/mensural-ligature-engraver.cc +++ b/lily/mensural-ligature-engraver.cc @@ -74,7 +74,6 @@ private: Real &min_length); }; -IMPLEMENT_TRANSLATOR_LISTENER (Mensural_ligature_engraver, ligature); void Mensural_ligature_engraver::listen_ligature (Stream_event *ev) { @@ -496,8 +495,14 @@ Mensural_ligature_engraver::build_ligature (Spanner *ligature, ligature->set_property ("minimum-length", scm_from_double (min_length)); } -ADD_ACKNOWLEDGER (Mensural_ligature_engraver, rest); -ADD_ACKNOWLEDGER (Mensural_ligature_engraver, ligature_head); + +void +Mensural_ligature_engraver::boot () +{ + ADD_LISTENER (Mensural_ligature_engraver, ligature); + ADD_ACKNOWLEDGER (Mensural_ligature_engraver, rest); + ADD_ACKNOWLEDGER (Mensural_ligature_engraver, ligature_head); +} ADD_TRANSLATOR (Mensural_ligature_engraver, /* doc */ diff --git a/lily/metronome-engraver.cc b/lily/metronome-engraver.cc index e1de3e23e0..21aab95ee2 100644 --- a/lily/metronome-engraver.cc +++ b/lily/metronome-engraver.cc @@ -61,7 +61,6 @@ Metronome_mark_engraver::Metronome_mark_engraver () tempo_ev_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Metronome_mark_engraver, tempo_change); void Metronome_mark_engraver::listen_tempo_change (Stream_event *ev) { @@ -168,9 +167,15 @@ Metronome_mark_engraver::process_music () } } -ADD_ACKNOWLEDGER (Metronome_mark_engraver, break_aligned); -ADD_ACKNOWLEDGER (Metronome_mark_engraver, break_alignment); -ADD_ACKNOWLEDGER (Metronome_mark_engraver, grob); + +void +Metronome_mark_engraver::boot () +{ + ADD_LISTENER (Metronome_mark_engraver, tempo_change); + ADD_ACKNOWLEDGER (Metronome_mark_engraver, break_aligned); + ADD_ACKNOWLEDGER (Metronome_mark_engraver, break_alignment); + ADD_ACKNOWLEDGER (Metronome_mark_engraver, grob); +} ADD_TRANSLATOR (Metronome_mark_engraver, /* doc */ diff --git a/lily/midi-control-function-performer.cc b/lily/midi-control-function-performer.cc index 90ea063f73..a112e6bcef 100644 --- a/lily/midi-control-function-performer.cc +++ b/lily/midi-control-function-performer.cc @@ -113,6 +113,12 @@ Midi_control_function_performer::announce_function_value_change (SCM sev) } } +void +Midi_control_function_performer::boot () +{ + +} + ADD_TRANSLATOR (Midi_control_function_performer, /* doc */ "", diff --git a/lily/multi-measure-rest-engraver.cc b/lily/multi-measure-rest-engraver.cc index 274746b845..aa4a54b9e7 100644 --- a/lily/multi-measure-rest-engraver.cc +++ b/lily/multi-measure-rest-engraver.cc @@ -74,7 +74,6 @@ Multi_measure_rest_engraver::Multi_measure_rest_engraver () { } -IMPLEMENT_TRANSLATOR_LISTENER (Multi_measure_rest_engraver, multi_measure_rest); void Multi_measure_rest_engraver::listen_multi_measure_rest (Stream_event *ev) { @@ -91,7 +90,6 @@ Multi_measure_rest_engraver::listen_multi_measure_rest (Stream_event *ev) clear_lapsed_events (now); } -IMPLEMENT_TRANSLATOR_LISTENER (Multi_measure_rest_engraver, multi_measure_text); void Multi_measure_rest_engraver::listen_multi_measure_text (Stream_event *ev) { @@ -245,6 +243,13 @@ Multi_measure_rest_engraver::start_translation_timestep () clear_lapsed_events (now_mom ()); } +void +Multi_measure_rest_engraver::boot () +{ + ADD_LISTENER (Multi_measure_rest_engraver, multi_measure_rest); + ADD_LISTENER (Multi_measure_rest_engraver, multi_measure_text); +} + ADD_TRANSLATOR (Multi_measure_rest_engraver, /* doc */ "Engrave multi-measure rests that are produced with" diff --git a/lily/new-fingering-engraver.cc b/lily/new-fingering-engraver.cc index 3ecad3a89e..abf9ce5a6b 100644 --- a/lily/new-fingering-engraver.cc +++ b/lily/new-fingering-engraver.cc @@ -371,9 +371,14 @@ New_fingering_engraver::New_fingering_engraver () stem_ = 0; } -ADD_ACKNOWLEDGER (New_fingering_engraver, rhythmic_head); -ADD_ACKNOWLEDGER (New_fingering_engraver, inline_accidental); -ADD_ACKNOWLEDGER (New_fingering_engraver, stem); + +void +New_fingering_engraver::boot () +{ + ADD_ACKNOWLEDGER (New_fingering_engraver, rhythmic_head); + ADD_ACKNOWLEDGER (New_fingering_engraver, inline_accidental); + ADD_ACKNOWLEDGER (New_fingering_engraver, stem); +} ADD_TRANSLATOR (New_fingering_engraver, /* doc */ diff --git a/lily/note-head-line-engraver.cc b/lily/note-head-line-engraver.cc index 4b21bb2767..f71c8bdbe1 100644 --- a/lily/note-head-line-engraver.cc +++ b/lily/note-head-line-engraver.cc @@ -106,7 +106,12 @@ Note_head_line_engraver::stop_translation_timestep () #include "translator.icc" -ADD_ACKNOWLEDGER (Note_head_line_engraver, rhythmic_head); +void +Note_head_line_engraver::boot () +{ + ADD_ACKNOWLEDGER (Note_head_line_engraver, rhythmic_head); +} + ADD_TRANSLATOR (Note_head_line_engraver, /* doc */ "Engrave a line between two note heads in a staff" diff --git a/lily/note-heads-engraver.cc b/lily/note-heads-engraver.cc index 6322dfa2b9..244e25cedc 100644 --- a/lily/note-heads-engraver.cc +++ b/lily/note-heads-engraver.cc @@ -50,7 +50,6 @@ Note_heads_engraver::Note_heads_engraver () { } -IMPLEMENT_TRANSLATOR_LISTENER (Note_heads_engraver, note); void Note_heads_engraver::listen_note (Stream_event *ev) { @@ -121,6 +120,12 @@ Note_heads_engraver::stop_translation_timestep () note_evs_.clear (); } +void +Note_heads_engraver::boot () +{ + ADD_LISTENER (Note_heads_engraver, note); +} + ADD_TRANSLATOR (Note_heads_engraver, /* doc */ "Generate note heads.", diff --git a/lily/note-name-engraver.cc b/lily/note-name-engraver.cc index 3ae9840e0d..d4494a7cb7 100644 --- a/lily/note-name-engraver.cc +++ b/lily/note-name-engraver.cc @@ -35,7 +35,6 @@ public: void stop_translation_timestep (); }; -IMPLEMENT_TRANSLATOR_LISTENER (Note_name_engraver, note); void Note_name_engraver::listen_note (Stream_event *ev) { @@ -74,6 +73,12 @@ Note_name_engraver::Note_name_engraver () { } +void +Note_name_engraver::boot () +{ + ADD_LISTENER (Note_name_engraver, note); +} + ADD_TRANSLATOR (Note_name_engraver, /* doc */ "Print pitches as words.", diff --git a/lily/note-performer.cc b/lily/note-performer.cc index aa46440006..6e1295fd08 100644 --- a/lily/note-performer.cc +++ b/lily/note-performer.cc @@ -126,14 +126,12 @@ Note_performer::stop_translation_timestep () note_evs_.clear (); } -IMPLEMENT_TRANSLATOR_LISTENER (Note_performer, note) void Note_performer::listen_note (Stream_event *ev) { note_evs_.push_back (ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Note_performer, breathing) void Note_performer::listen_breathing (Stream_event *ev) { @@ -157,6 +155,13 @@ Note_performer::listen_breathing (Stream_event *ev) } } +void +Note_performer::boot () +{ + ADD_LISTENER (Note_performer, note) + ADD_LISTENER (Note_performer, breathing) +} + ADD_TRANSLATOR (Note_performer, /* doc */ "", diff --git a/lily/note-spacing-engraver.cc b/lily/note-spacing-engraver.cc index f0bca862d9..29293ea7fe 100644 --- a/lily/note-spacing-engraver.cc +++ b/lily/note-spacing-engraver.cc @@ -135,8 +135,13 @@ Note_spacing_engraver::stop_translation_timestep () } -ADD_ACKNOWLEDGER (Note_spacing_engraver, note_column); -ADD_ACKNOWLEDGER (Note_spacing_engraver, rhythmic_grob); + +void +Note_spacing_engraver::boot () +{ + ADD_ACKNOWLEDGER (Note_spacing_engraver, note_column); + ADD_ACKNOWLEDGER (Note_spacing_engraver, rhythmic_grob); +} ADD_TRANSLATOR (Note_spacing_engraver, /* doc */ diff --git a/lily/ottava-engraver.cc b/lily/ottava-engraver.cc index d236ed779d..79d054a7cc 100644 --- a/lily/ottava-engraver.cc +++ b/lily/ottava-engraver.cc @@ -136,7 +136,12 @@ Ottava_spanner_engraver::finalize () #include "translator.icc" -ADD_ACKNOWLEDGER (Ottava_spanner_engraver, note_column); + +void +Ottava_spanner_engraver::boot () +{ + ADD_ACKNOWLEDGER (Ottava_spanner_engraver, note_column); +} ADD_TRANSLATOR (Ottava_spanner_engraver, /* doc */ diff --git a/lily/output-property-engraver.cc b/lily/output-property-engraver.cc index c14a6ee563..b1956910b6 100644 --- a/lily/output-property-engraver.cc +++ b/lily/output-property-engraver.cc @@ -37,7 +37,6 @@ protected: void stop_translation_timestep (); }; -IMPLEMENT_TRANSLATOR_LISTENER (Output_property_engraver, apply_output); void Output_property_engraver::listen_apply_output (Stream_event *ev) { @@ -78,7 +77,13 @@ Output_property_engraver::Output_property_engraver () { } -ADD_ACKNOWLEDGER (Output_property_engraver, grob); +void +Output_property_engraver::boot () +{ + ADD_LISTENER (Output_property_engraver, apply_output); + ADD_ACKNOWLEDGER (Output_property_engraver, grob); +} + ADD_TRANSLATOR (Output_property_engraver, /* doc */ "Apply a procedure to any grob acknowledged.", diff --git a/lily/page-turn-engraver.cc b/lily/page-turn-engraver.cc index dd90ba71cf..fd5b34a088 100644 --- a/lily/page-turn-engraver.cc +++ b/lily/page-turn-engraver.cc @@ -168,7 +168,6 @@ Page_turn_engraver::acknowledge_note_head (Grob_info gi) note_end_ = now_mom () + dur_ptr->get_length (); } -IMPLEMENT_TRANSLATOR_LISTENER (Page_turn_engraver, break); void Page_turn_engraver::listen_break (Stream_event *ev) { @@ -342,7 +341,13 @@ Page_turn_engraver::finalize () } } -ADD_ACKNOWLEDGER (Page_turn_engraver, note_head); + +void +Page_turn_engraver::boot () +{ + ADD_LISTENER (Page_turn_engraver, break); + ADD_ACKNOWLEDGER (Page_turn_engraver, note_head); +} ADD_TRANSLATOR (Page_turn_engraver, /* doc */ diff --git a/lily/paper-column-engraver.cc b/lily/paper-column-engraver.cc index 7c44f173d7..8cb99ecbb6 100644 --- a/lily/paper-column-engraver.cc +++ b/lily/paper-column-engraver.cc @@ -142,14 +142,12 @@ Paper_column_engraver::set_columns (Paper_column *new_command, system_->add_column (musical_column_); } -IMPLEMENT_TRANSLATOR_LISTENER (Paper_column_engraver, break); void Paper_column_engraver::listen_break (Stream_event *ev) { break_events_.push_back (ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Paper_column_engraver, label); void Paper_column_engraver::listen_label (Stream_event *ev) { @@ -301,9 +299,16 @@ Paper_column_engraver::start_translation_timestep () } } -ADD_ACKNOWLEDGER (Paper_column_engraver, item); -ADD_ACKNOWLEDGER (Paper_column_engraver, note_spacing); -ADD_ACKNOWLEDGER (Paper_column_engraver, staff_spacing); + +void +Paper_column_engraver::boot () +{ + ADD_LISTENER (Paper_column_engraver, break); + ADD_LISTENER (Paper_column_engraver, label); + ADD_ACKNOWLEDGER (Paper_column_engraver, item); + ADD_ACKNOWLEDGER (Paper_column_engraver, note_spacing); + ADD_ACKNOWLEDGER (Paper_column_engraver, staff_spacing); +} ADD_TRANSLATOR (Paper_column_engraver, /* doc */ diff --git a/lily/parenthesis-engraver.cc b/lily/parenthesis-engraver.cc index 1479aa4c0b..d9dfac1825 100644 --- a/lily/parenthesis-engraver.cc +++ b/lily/parenthesis-engraver.cc @@ -72,7 +72,12 @@ Parenthesis_engraver::acknowledge_grob (Grob_info info) } } -ADD_ACKNOWLEDGER (Parenthesis_engraver, grob); +void +Parenthesis_engraver::boot () +{ + ADD_ACKNOWLEDGER (Parenthesis_engraver, grob); +} + ADD_TRANSLATOR (Parenthesis_engraver, /* doc */ "Parenthesize objects whose music cause has the" diff --git a/lily/part-combine-engraver.cc b/lily/part-combine-engraver.cc index eaae218c1b..cb788f02ce 100644 --- a/lily/part-combine-engraver.cc +++ b/lily/part-combine-engraver.cc @@ -51,7 +51,6 @@ private: Stream_event *waiting_event_; }; -IMPLEMENT_TRANSLATOR_LISTENER (Part_combine_engraver, part_combine); void Part_combine_engraver::listen_part_combine (Stream_event *ev) { @@ -61,7 +60,6 @@ Part_combine_engraver::listen_part_combine (Stream_event *ev) waiting_event_ = new_event_; } -IMPLEMENT_TRANSLATOR_LISTENER (Part_combine_engraver, note); void Part_combine_engraver::listen_note (Stream_event *) { @@ -137,8 +135,15 @@ Part_combine_engraver::stop_translation_timestep () note_found_ = false; } -ADD_ACKNOWLEDGER (Part_combine_engraver, note_head); -ADD_ACKNOWLEDGER (Part_combine_engraver, stem); +void +Part_combine_engraver::boot () +{ + ADD_LISTENER (Part_combine_engraver, part_combine); + ADD_LISTENER (Part_combine_engraver, note); + ADD_ACKNOWLEDGER (Part_combine_engraver, note_head); + ADD_ACKNOWLEDGER (Part_combine_engraver, stem); +} + ADD_TRANSLATOR (Part_combine_engraver, /* doc */ "Part combine engraver for orchestral scores: Print markings" diff --git a/lily/percent-repeat-engraver.cc b/lily/percent-repeat-engraver.cc index 895e06981e..59655a110a 100644 --- a/lily/percent-repeat-engraver.cc +++ b/lily/percent-repeat-engraver.cc @@ -85,7 +85,6 @@ Percent_repeat_engraver::start_translation_timestep () } } -IMPLEMENT_TRANSLATOR_LISTENER (Percent_repeat_engraver, percent); void Percent_repeat_engraver::listen_percent (Stream_event *ev) { @@ -169,6 +168,12 @@ Percent_repeat_engraver::stop_translation_timestep () { } +void +Percent_repeat_engraver::boot () +{ + ADD_LISTENER (Percent_repeat_engraver, percent); +} + ADD_TRANSLATOR (Percent_repeat_engraver, /* doc */ "Make whole measure repeats.", diff --git a/lily/phrasing-slur-engraver.cc b/lily/phrasing-slur-engraver.cc index b1a2f23ea0..7d4f16bcea 100644 --- a/lily/phrasing-slur-engraver.cc +++ b/lily/phrasing-slur-engraver.cc @@ -56,14 +56,12 @@ Phrasing_slur_engraver::event_symbol () return ly_symbol2scm ("phrasing-slur-event"); } -IMPLEMENT_TRANSLATOR_LISTENER (Phrasing_slur_engraver, phrasing_slur); void Phrasing_slur_engraver::listen_phrasing_slur (Stream_event *ev) { Slur_proto_engraver::listen_slur (ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Phrasing_slur_engraver, note); void Phrasing_slur_engraver::listen_note (Stream_event *ev) { @@ -76,15 +74,22 @@ Phrasing_slur_engraver::acknowledge_slur (Grob_info info) acknowledge_extra_object (info); } -ADD_ACKNOWLEDGER (Phrasing_slur_engraver, inline_accidental); -ADD_ACKNOWLEDGER (Phrasing_slur_engraver, fingering) -ADD_ACKNOWLEDGER (Phrasing_slur_engraver, note_column); -ADD_ACKNOWLEDGER (Phrasing_slur_engraver, slur); -ADD_ACKNOWLEDGER (Phrasing_slur_engraver, script); -ADD_ACKNOWLEDGER (Phrasing_slur_engraver, dots); -ADD_ACKNOWLEDGER (Phrasing_slur_engraver, text_script); -ADD_END_ACKNOWLEDGER (Phrasing_slur_engraver, tie); -ADD_ACKNOWLEDGER (Phrasing_slur_engraver, tuplet_number); + +void +Phrasing_slur_engraver::boot () +{ + ADD_LISTENER (Phrasing_slur_engraver, phrasing_slur); + ADD_LISTENER (Phrasing_slur_engraver, note); + ADD_ACKNOWLEDGER (Phrasing_slur_engraver, inline_accidental); + ADD_ACKNOWLEDGER (Phrasing_slur_engraver, fingering) + ADD_ACKNOWLEDGER (Phrasing_slur_engraver, note_column); + ADD_ACKNOWLEDGER (Phrasing_slur_engraver, slur); + ADD_ACKNOWLEDGER (Phrasing_slur_engraver, script); + ADD_ACKNOWLEDGER (Phrasing_slur_engraver, dots); + ADD_ACKNOWLEDGER (Phrasing_slur_engraver, text_script); + ADD_END_ACKNOWLEDGER (Phrasing_slur_engraver, tie); + ADD_ACKNOWLEDGER (Phrasing_slur_engraver, tuplet_number); +} ADD_TRANSLATOR (Phrasing_slur_engraver, /* doc */ diff --git a/lily/piano-pedal-align-engraver.cc b/lily/piano-pedal-align-engraver.cc index 7134a6cfc7..3fa7c5e479 100644 --- a/lily/piano-pedal-align-engraver.cc +++ b/lily/piano-pedal-align-engraver.cc @@ -248,11 +248,16 @@ Piano_pedal_align_engraver::finalize () } } -ADD_ACKNOWLEDGER (Piano_pedal_align_engraver, note_column); -ADD_ACKNOWLEDGER (Piano_pedal_align_engraver, piano_pedal_bracket); -ADD_ACKNOWLEDGER (Piano_pedal_align_engraver, piano_pedal_script); -ADD_END_ACKNOWLEDGER (Piano_pedal_align_engraver, piano_pedal_bracket); + +void +Piano_pedal_align_engraver::boot () +{ + ADD_ACKNOWLEDGER (Piano_pedal_align_engraver, note_column); + ADD_ACKNOWLEDGER (Piano_pedal_align_engraver, piano_pedal_bracket); + ADD_ACKNOWLEDGER (Piano_pedal_align_engraver, piano_pedal_script); + ADD_END_ACKNOWLEDGER (Piano_pedal_align_engraver, piano_pedal_bracket); +} ADD_TRANSLATOR (Piano_pedal_align_engraver, /* doc */ diff --git a/lily/piano-pedal-engraver.cc b/lily/piano-pedal-engraver.cc index 2fb99407d5..d0e35713d9 100644 --- a/lily/piano-pedal-engraver.cc +++ b/lily/piano-pedal-engraver.cc @@ -205,7 +205,6 @@ Piano_pedal_engraver::initialize () info_list_[NUM_PEDAL_TYPES].type_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Piano_pedal_engraver, sostenuto); void Piano_pedal_engraver::listen_sostenuto (Stream_event *ev) { @@ -213,7 +212,6 @@ Piano_pedal_engraver::listen_sostenuto (Stream_event *ev) ASSIGN_EVENT_ONCE (info_list_[SOSTENUTO].event_drul_[d], ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Piano_pedal_engraver, sustain); void Piano_pedal_engraver::listen_sustain (Stream_event *ev) { @@ -221,7 +219,6 @@ Piano_pedal_engraver::listen_sustain (Stream_event *ev) ASSIGN_EVENT_ONCE (info_list_[SUSTAIN].event_drul_[d], ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Piano_pedal_engraver, una_corda); void Piano_pedal_engraver::listen_una_corda (Stream_event *ev) { @@ -479,6 +476,14 @@ Piano_pedal_engraver::typeset_all (Pedal_info *p) } } +void +Piano_pedal_engraver::boot () +{ + ADD_LISTENER (Piano_pedal_engraver, sostenuto); + ADD_LISTENER (Piano_pedal_engraver, sustain); + ADD_LISTENER (Piano_pedal_engraver, una_corda); +} + ADD_TRANSLATOR (Piano_pedal_engraver, /* doc */ "Engrave piano pedal symbols and brackets.", diff --git a/lily/piano-pedal-performer.cc b/lily/piano-pedal-performer.cc index 49ec0dd7fe..ba2d2b5042 100644 --- a/lily/piano-pedal-performer.cc +++ b/lily/piano-pedal-performer.cc @@ -146,7 +146,6 @@ Piano_pedal_performer::start_translation_timestep () } } -IMPLEMENT_TRANSLATOR_LISTENER (Piano_pedal_performer, sostenuto); void Piano_pedal_performer::listen_sostenuto (Stream_event *r) { @@ -154,7 +153,6 @@ Piano_pedal_performer::listen_sostenuto (Stream_event *r) info_alist_[SOSTENUTO].event_drul_[d] = r; } -IMPLEMENT_TRANSLATOR_LISTENER (Piano_pedal_performer, sustain); void Piano_pedal_performer::listen_sustain (Stream_event *r) { @@ -162,7 +160,6 @@ Piano_pedal_performer::listen_sustain (Stream_event *r) info_alist_[SUSTAIN].event_drul_[d] = r; } -IMPLEMENT_TRANSLATOR_LISTENER (Piano_pedal_performer, una_corda); void Piano_pedal_performer::listen_una_corda (Stream_event *r) { @@ -170,6 +167,14 @@ Piano_pedal_performer::listen_una_corda (Stream_event *r) info_alist_[UNA_CORDA].event_drul_[d] = r; } +void +Piano_pedal_performer::boot () +{ + ADD_LISTENER (Piano_pedal_performer, sostenuto); + ADD_LISTENER (Piano_pedal_performer, sustain); + ADD_LISTENER (Piano_pedal_performer, una_corda); +} + ADD_TRANSLATOR (Piano_pedal_performer, /* doc */ "", diff --git a/lily/pitch-squash-engraver.cc b/lily/pitch-squash-engraver.cc index d9796ff0e0..5d403c79e4 100644 --- a/lily/pitch-squash-engraver.cc +++ b/lily/pitch-squash-engraver.cc @@ -44,7 +44,12 @@ Pitch_squash_engraver::Pitch_squash_engraver () } #include "translator.icc" -ADD_ACKNOWLEDGER (Pitch_squash_engraver, note_head); +void +Pitch_squash_engraver::boot () +{ + ADD_ACKNOWLEDGER (Pitch_squash_engraver, note_head); +} + ADD_TRANSLATOR (Pitch_squash_engraver, /* doc */ "Set the vertical position of note heads to" diff --git a/lily/pitched-trill-engraver.cc b/lily/pitched-trill-engraver.cc index 30d734346e..54ef0827a7 100644 --- a/lily/pitched-trill-engraver.cc +++ b/lily/pitched-trill-engraver.cc @@ -169,11 +169,16 @@ Pitched_trill_engraver::stop_translation_timestep () trill_accidental_ = 0; } -ADD_ACKNOWLEDGER (Pitched_trill_engraver, note_head); -ADD_ACKNOWLEDGER (Pitched_trill_engraver, dots); -ADD_ACKNOWLEDGER (Pitched_trill_engraver, stem); -ADD_ACKNOWLEDGER (Pitched_trill_engraver, flag); -ADD_ACKNOWLEDGER (Pitched_trill_engraver, trill_spanner); + +void +Pitched_trill_engraver::boot () +{ + ADD_ACKNOWLEDGER (Pitched_trill_engraver, note_head); + ADD_ACKNOWLEDGER (Pitched_trill_engraver, dots); + ADD_ACKNOWLEDGER (Pitched_trill_engraver, stem); + ADD_ACKNOWLEDGER (Pitched_trill_engraver, flag); + ADD_ACKNOWLEDGER (Pitched_trill_engraver, trill_spanner); +} ADD_TRANSLATOR (Pitched_trill_engraver, /* doc */ diff --git a/lily/pure-from-neighbor-engraver.cc b/lily/pure-from-neighbor-engraver.cc index e147f53cca..d5439726bb 100644 --- a/lily/pure-from-neighbor-engraver.cc +++ b/lily/pure-from-neighbor-engraver.cc @@ -136,8 +136,13 @@ Pure_from_neighbor_engraver::finalize () pure_relevants_.clear (); } -ADD_ACKNOWLEDGER (Pure_from_neighbor_engraver, item); -ADD_ACKNOWLEDGER (Pure_from_neighbor_engraver, pure_from_neighbor); +void +Pure_from_neighbor_engraver::boot () +{ + ADD_ACKNOWLEDGER (Pure_from_neighbor_engraver, item); + ADD_ACKNOWLEDGER (Pure_from_neighbor_engraver, pure_from_neighbor); +} + ADD_TRANSLATOR (Pure_from_neighbor_engraver, /* doc */ "Coordinates items that get their pure heights from their neighbors.", diff --git a/lily/repeat-acknowledge-engraver.cc b/lily/repeat-acknowledge-engraver.cc index 67477b1f01..d11b633fd5 100644 --- a/lily/repeat-acknowledge-engraver.cc +++ b/lily/repeat-acknowledge-engraver.cc @@ -135,6 +135,12 @@ Repeat_acknowledge_engraver::process_music () } } +void +Repeat_acknowledge_engraver::boot () +{ + +} + ADD_TRANSLATOR (Repeat_acknowledge_engraver, /* doc */ "Acknowledge repeated music, and convert the contents of" diff --git a/lily/repeat-tie-engraver.cc b/lily/repeat-tie-engraver.cc index 4eea8e5800..6eead57309 100644 --- a/lily/repeat-tie-engraver.cc +++ b/lily/repeat-tie-engraver.cc @@ -53,7 +53,6 @@ Repeat_tie_engraver::stop_translation_timestep () semi_ties_.clear (); } -IMPLEMENT_TRANSLATOR_LISTENER (Repeat_tie_engraver, repeat_tie); void Repeat_tie_engraver::listen_repeat_tie (Stream_event *ev) { @@ -88,7 +87,13 @@ Repeat_tie_engraver::acknowledge_note_head (Grob_info inf) } -ADD_ACKNOWLEDGER (Repeat_tie_engraver, note_head); +void +Repeat_tie_engraver::boot () +{ + ADD_LISTENER (Repeat_tie_engraver, repeat_tie); + ADD_ACKNOWLEDGER (Repeat_tie_engraver, note_head); +} + ADD_TRANSLATOR (Repeat_tie_engraver, /* doc */ "Create repeat ties.", diff --git a/lily/rest-collision-engraver.cc b/lily/rest-collision-engraver.cc index a70641cfd0..56a6783fbf 100644 --- a/lily/rest-collision-engraver.cc +++ b/lily/rest-collision-engraver.cc @@ -94,6 +94,12 @@ Rest_collision_engraver::stop_translation_timestep () rest_collision_ = 0; } +void +Rest_collision_engraver::boot () +{ + +} + ADD_TRANSLATOR (Rest_collision_engraver, /* doc */ "Handle collisions of rests.", diff --git a/lily/rest-engraver.cc b/lily/rest-engraver.cc index b40aeee8a3..64ff97a35f 100644 --- a/lily/rest-engraver.cc +++ b/lily/rest-engraver.cc @@ -80,13 +80,18 @@ Rest_engraver::process_music () } } -IMPLEMENT_TRANSLATOR_LISTENER (Rest_engraver, rest); void Rest_engraver::listen_rest (Stream_event *ev) { ASSIGN_EVENT_ONCE (rest_event_, ev); } +void +Rest_engraver::boot () +{ + ADD_LISTENER (Rest_engraver, rest); +} + ADD_TRANSLATOR (Rest_engraver, /* doc */ "Engrave rests.", diff --git a/lily/rhythmic-column-engraver.cc b/lily/rhythmic-column-engraver.cc index 28a06f79b0..d6e461060b 100644 --- a/lily/rhythmic-column-engraver.cc +++ b/lily/rhythmic-column-engraver.cc @@ -134,9 +134,14 @@ Rhythmic_column_engraver::stop_translation_timestep () flag_ = 0; } -ADD_ACKNOWLEDGER (Rhythmic_column_engraver, stem); -ADD_ACKNOWLEDGER (Rhythmic_column_engraver, flag); -ADD_ACKNOWLEDGER (Rhythmic_column_engraver, rhythmic_head); + +void +Rhythmic_column_engraver::boot () +{ + ADD_ACKNOWLEDGER (Rhythmic_column_engraver, stem); + ADD_ACKNOWLEDGER (Rhythmic_column_engraver, flag); + ADD_ACKNOWLEDGER (Rhythmic_column_engraver, rhythmic_head); +} ADD_TRANSLATOR (Rhythmic_column_engraver, /* doc */ diff --git a/lily/script-column-engraver.cc b/lily/script-column-engraver.cc index dc34098664..8caf8b903c 100644 --- a/lily/script-column-engraver.cc +++ b/lily/script-column-engraver.cc @@ -77,7 +77,12 @@ Script_column_engraver::process_acknowledged () script_column_ = make_item ("ScriptColumn", SCM_EOL); } -ADD_ACKNOWLEDGER (Script_column_engraver, side_position); +void +Script_column_engraver::boot () +{ + ADD_ACKNOWLEDGER (Script_column_engraver, side_position); +} + ADD_TRANSLATOR (Script_column_engraver, /* doc */ "Find potentially colliding scripts and put them into a" diff --git a/lily/script-engraver.cc b/lily/script-engraver.cc index 62c3de482c..578ed84ad4 100644 --- a/lily/script-engraver.cc +++ b/lily/script-engraver.cc @@ -71,7 +71,6 @@ Script_engraver::Script_engraver () { } -IMPLEMENT_TRANSLATOR_LISTENER (Script_engraver, articulation); void Script_engraver::listen_articulation (Stream_event *ev) { @@ -275,13 +274,19 @@ Script_engraver::stop_translation_timestep () scripts_.clear (); } -ADD_ACKNOWLEDGER (Script_engraver, rhythmic_head); -ADD_ACKNOWLEDGER (Script_engraver, stem); -ADD_ACKNOWLEDGER (Script_engraver, tie); -ADD_END_ACKNOWLEDGER (Script_engraver, tie); -ADD_ACKNOWLEDGER (Script_engraver, note_column); -ADD_ACKNOWLEDGER (Script_engraver, stem_tremolo); -ADD_ACKNOWLEDGER (Script_engraver, inline_accidental); + +void +Script_engraver::boot () +{ + ADD_LISTENER (Script_engraver, articulation); + ADD_ACKNOWLEDGER (Script_engraver, rhythmic_head); + ADD_ACKNOWLEDGER (Script_engraver, stem); + ADD_ACKNOWLEDGER (Script_engraver, tie); + ADD_END_ACKNOWLEDGER (Script_engraver, tie); + ADD_ACKNOWLEDGER (Script_engraver, note_column); + ADD_ACKNOWLEDGER (Script_engraver, stem_tremolo); + ADD_ACKNOWLEDGER (Script_engraver, inline_accidental); +} ADD_TRANSLATOR (Script_engraver, /* doc */ diff --git a/lily/script-row-engraver.cc b/lily/script-row-engraver.cc index 35b5038020..390cba5f96 100644 --- a/lily/script-row-engraver.cc +++ b/lily/script-row-engraver.cc @@ -89,8 +89,13 @@ Script_row_engraver::process_acknowledged () script_row_ = make_item ("ScriptRow", SCM_EOL); } -ADD_ACKNOWLEDGER (Script_row_engraver, accidental_placement); -ADD_ACKNOWLEDGER (Script_row_engraver, side_position); +void +Script_row_engraver::boot () +{ + ADD_ACKNOWLEDGER (Script_row_engraver, accidental_placement); + ADD_ACKNOWLEDGER (Script_row_engraver, side_position); +} + ADD_TRANSLATOR (Script_row_engraver, /* doc */ "Determine order in horizontal side position elements.", diff --git a/lily/separating-line-group-engraver.cc b/lily/separating-line-group-engraver.cc index 08069afda8..c2f76349df 100644 --- a/lily/separating-line-group-engraver.cc +++ b/lily/separating-line-group-engraver.cc @@ -153,8 +153,13 @@ Separating_line_group_engraver::stop_translation_timestep () break_aligned_.clear (); } -ADD_ACKNOWLEDGER (Separating_line_group_engraver, item); -ADD_ACKNOWLEDGER (Separating_line_group_engraver, break_aligned); + +void +Separating_line_group_engraver::boot () +{ + ADD_ACKNOWLEDGER (Separating_line_group_engraver, item); + ADD_ACKNOWLEDGER (Separating_line_group_engraver, break_aligned); +} ADD_TRANSLATOR (Separating_line_group_engraver, /* doc */ diff --git a/lily/slash-repeat-engraver.cc b/lily/slash-repeat-engraver.cc index f9f0bfb76a..2134503e88 100644 --- a/lily/slash-repeat-engraver.cc +++ b/lily/slash-repeat-engraver.cc @@ -44,7 +44,6 @@ Slash_repeat_engraver::Slash_repeat_engraver () slash_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Slash_repeat_engraver, repeat_slash); void Slash_repeat_engraver::listen_repeat_slash (Stream_event *ev) { @@ -65,6 +64,12 @@ Slash_repeat_engraver::process_music () } } +void +Slash_repeat_engraver::boot () +{ + ADD_LISTENER (Slash_repeat_engraver, repeat_slash); +} + ADD_TRANSLATOR (Slash_repeat_engraver, /* doc */ "Make beat repeats.", diff --git a/lily/slur-engraver.cc b/lily/slur-engraver.cc index 31621844a9..aa09f4db1f 100644 --- a/lily/slur-engraver.cc +++ b/lily/slur-engraver.cc @@ -57,14 +57,12 @@ Slur_engraver::event_symbol () return ly_symbol2scm ("slur-event"); } -IMPLEMENT_TRANSLATOR_LISTENER (Slur_engraver, slur); void Slur_engraver::listen_slur (Stream_event *ev) { Slur_proto_engraver::listen_slur (ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Slur_engraver, note); void Slur_engraver::listen_note (Stream_event *ev) { @@ -77,14 +75,21 @@ Slur_engraver::set_melisma (bool m) context ()->set_property ("slurMelismaBusy", ly_bool2scm (m)); } -ADD_ACKNOWLEDGER (Slur_engraver, inline_accidental); -ADD_ACKNOWLEDGER (Slur_engraver, fingering); -ADD_ACKNOWLEDGER (Slur_engraver, note_column); -ADD_ACKNOWLEDGER (Slur_engraver, script); -ADD_ACKNOWLEDGER (Slur_engraver, text_script); -ADD_ACKNOWLEDGER (Slur_engraver, dots); -ADD_END_ACKNOWLEDGER (Slur_engraver, tie); -ADD_ACKNOWLEDGER (Slur_engraver, tuplet_number); +void +Slur_engraver::boot () +{ + ADD_LISTENER (Slur_engraver, slur); + ADD_LISTENER (Slur_engraver, note); + ADD_ACKNOWLEDGER (Slur_engraver, inline_accidental); + ADD_ACKNOWLEDGER (Slur_engraver, fingering); + ADD_ACKNOWLEDGER (Slur_engraver, note_column); + ADD_ACKNOWLEDGER (Slur_engraver, script); + ADD_ACKNOWLEDGER (Slur_engraver, text_script); + ADD_ACKNOWLEDGER (Slur_engraver, dots); + ADD_END_ACKNOWLEDGER (Slur_engraver, tie); + ADD_ACKNOWLEDGER (Slur_engraver, tuplet_number); +} + ADD_TRANSLATOR (Slur_engraver, /* doc */ "Build slur grobs from slur events.", diff --git a/lily/slur-performer.cc b/lily/slur-performer.cc index 222a9d75fa..c1d8de3bb4 100644 --- a/lily/slur-performer.cc +++ b/lily/slur-performer.cc @@ -83,7 +83,6 @@ Slur_performer::start_translation_timestep () now_stop_ev_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Slur_performer, slur); void Slur_performer::listen_slur (Stream_event *ev) { @@ -95,6 +94,12 @@ Slur_performer::listen_slur (Stream_event *ev) now_stop_ev_ = ev; } +void +Slur_performer::boot () +{ + ADD_LISTENER (Slur_performer, slur); +} + ADD_TRANSLATOR (Slur_performer, /* doc */ "", diff --git a/lily/spacing-engraver.cc b/lily/spacing-engraver.cc index cc5b1e31d1..6628fe36b4 100644 --- a/lily/spacing-engraver.cc +++ b/lily/spacing-engraver.cc @@ -99,7 +99,6 @@ Spacing_engraver::Spacing_engraver () start_section_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Spacing_engraver, spacing_section); void Spacing_engraver::listen_spacing_section (Stream_event *ev) { @@ -261,10 +260,16 @@ Spacing_engraver::start_translation_timestep () stopped_durations_.push_back (playing_durations_.get ()); } -ADD_ACKNOWLEDGER (Spacing_engraver, staff_spacing); -ADD_ACKNOWLEDGER (Spacing_engraver, note_spacing); -ADD_ACKNOWLEDGER (Spacing_engraver, rhythmic_head); -ADD_ACKNOWLEDGER (Spacing_engraver, rhythmic_grob); + +void +Spacing_engraver::boot () +{ + ADD_LISTENER (Spacing_engraver, spacing_section); + ADD_ACKNOWLEDGER (Spacing_engraver, staff_spacing); + ADD_ACKNOWLEDGER (Spacing_engraver, note_spacing); + ADD_ACKNOWLEDGER (Spacing_engraver, rhythmic_head); + ADD_ACKNOWLEDGER (Spacing_engraver, rhythmic_grob); +} ADD_TRANSLATOR (Spacing_engraver, /* doc */ diff --git a/lily/span-arpeggio-engraver.cc b/lily/span-arpeggio-engraver.cc index f66c8770b5..231e484409 100644 --- a/lily/span-arpeggio-engraver.cc +++ b/lily/span-arpeggio-engraver.cc @@ -125,8 +125,13 @@ Span_arpeggio_engraver::stop_translation_timestep () note_columns_.clear (); } -ADD_ACKNOWLEDGER (Span_arpeggio_engraver, arpeggio); -ADD_ACKNOWLEDGER (Span_arpeggio_engraver, note_column); +void +Span_arpeggio_engraver::boot () +{ + ADD_ACKNOWLEDGER (Span_arpeggio_engraver, arpeggio); + ADD_ACKNOWLEDGER (Span_arpeggio_engraver, note_column); +} + ADD_TRANSLATOR (Span_arpeggio_engraver, /* doc */ "Make arpeggios that span multiple staves.", diff --git a/lily/span-bar-engraver.cc b/lily/span-bar-engraver.cc index 63c245e70c..fa1608b72e 100644 --- a/lily/span-bar-engraver.cc +++ b/lily/span-bar-engraver.cc @@ -94,7 +94,12 @@ Span_bar_engraver::stop_translation_timestep () bars_.resize (0); } -ADD_ACKNOWLEDGER (Span_bar_engraver, bar_line); +void +Span_bar_engraver::boot () +{ + ADD_ACKNOWLEDGER (Span_bar_engraver, bar_line); +} + ADD_TRANSLATOR (Span_bar_engraver, /* doc */ "Make cross-staff bar lines: It catches all normal bar lines" diff --git a/lily/span-bar-stub-engraver.cc b/lily/span-bar-stub-engraver.cc index 304564398f..07fc722814 100644 --- a/lily/span-bar-stub-engraver.cc +++ b/lily/span-bar-stub-engraver.cc @@ -175,8 +175,13 @@ Span_bar_stub_engraver::stop_translation_timestep () axis_groups_ = axis_groups; } -ADD_ACKNOWLEDGER (Span_bar_stub_engraver, span_bar); -ADD_ACKNOWLEDGER (Span_bar_stub_engraver, hara_kiri_group_spanner); +void +Span_bar_stub_engraver::boot () +{ + ADD_ACKNOWLEDGER (Span_bar_stub_engraver, span_bar); + ADD_ACKNOWLEDGER (Span_bar_stub_engraver, hara_kiri_group_spanner); +} + ADD_TRANSLATOR (Span_bar_stub_engraver, /* doc */ "Make stubs for span bars in all contexts that the span bars cross.", diff --git a/lily/spanner-break-forbid-engraver.cc b/lily/spanner-break-forbid-engraver.cc index 4a47aade98..adebe934ef 100644 --- a/lily/spanner-break-forbid-engraver.cc +++ b/lily/spanner-break-forbid-engraver.cc @@ -66,8 +66,13 @@ Spanner_break_forbid_engraver::Spanner_break_forbid_engraver () { } -ADD_END_ACKNOWLEDGER (Spanner_break_forbid_engraver, unbreakable_spanner); -ADD_ACKNOWLEDGER (Spanner_break_forbid_engraver, unbreakable_spanner); +void +Spanner_break_forbid_engraver::boot () +{ + ADD_END_ACKNOWLEDGER (Spanner_break_forbid_engraver, unbreakable_spanner); + ADD_ACKNOWLEDGER (Spanner_break_forbid_engraver, unbreakable_spanner); +} + ADD_TRANSLATOR (Spanner_break_forbid_engraver, /* doc */ "Forbid breaks in certain spanners.", diff --git a/lily/staff-collecting-engraver.cc b/lily/staff-collecting-engraver.cc index 2ff2b79caf..259055b5f4 100644 --- a/lily/staff-collecting-engraver.cc +++ b/lily/staff-collecting-engraver.cc @@ -54,8 +54,13 @@ Staff_collecting_engraver::acknowledge_end_staff_symbol (Grob_info gi) #include "translator.icc" -ADD_ACKNOWLEDGER (Staff_collecting_engraver, staff_symbol); -ADD_END_ACKNOWLEDGER (Staff_collecting_engraver, staff_symbol); + +void +Staff_collecting_engraver::boot () +{ + ADD_ACKNOWLEDGER (Staff_collecting_engraver, staff_symbol); + ADD_END_ACKNOWLEDGER (Staff_collecting_engraver, staff_symbol); +} ADD_TRANSLATOR (Staff_collecting_engraver, /* doc */ diff --git a/lily/staff-performer.cc b/lily/staff-performer.cc index 26781f0dcd..3a05cbd0e2 100644 --- a/lily/staff-performer.cc +++ b/lily/staff-performer.cc @@ -79,6 +79,12 @@ map<string, int> Staff_performer::static_channel_map_; int Staff_performer::channel_count_ = 0; int Staff_performer::staff_performer_count_ = 0; +void +Staff_performer::boot () +{ + +} + ADD_TRANSLATOR (Staff_performer, /* doc */ "", diff --git a/lily/staff-symbol-engraver.cc b/lily/staff-symbol-engraver.cc index cad91e76c3..2d836fbee9 100644 --- a/lily/staff-symbol-engraver.cc +++ b/lily/staff-symbol-engraver.cc @@ -76,7 +76,6 @@ Staff_symbol_engraver::Staff_symbol_engraver () span_events_.set (0, 0); } -IMPLEMENT_TRANSLATOR_LISTENER (Staff_symbol_engraver, staff_span); void Staff_symbol_engraver::listen_staff_span (Stream_event *ev) { @@ -163,7 +162,13 @@ Staff_symbol_engraver::acknowledge_grob (Grob_info s) } } -ADD_ACKNOWLEDGER (Staff_symbol_engraver, grob); + +void +Staff_symbol_engraver::boot () +{ + ADD_LISTENER (Staff_symbol_engraver, staff_span); + ADD_ACKNOWLEDGER (Staff_symbol_engraver, grob); +} ADD_TRANSLATOR (Staff_symbol_engraver, /* doc */ diff --git a/lily/stanza-number-align-engraver.cc b/lily/stanza-number-align-engraver.cc index c32653abe0..ac13277149 100644 --- a/lily/stanza-number-align-engraver.cc +++ b/lily/stanza-number-align-engraver.cc @@ -69,8 +69,13 @@ Stanza_number_align_engraver::stop_translation_timestep () lyrics_.clear (); } -ADD_ACKNOWLEDGER (Stanza_number_align_engraver, lyric_syllable); -ADD_ACKNOWLEDGER (Stanza_number_align_engraver, stanza_number); + +void +Stanza_number_align_engraver::boot () +{ + ADD_ACKNOWLEDGER (Stanza_number_align_engraver, lyric_syllable); + ADD_ACKNOWLEDGER (Stanza_number_align_engraver, stanza_number); +} ADD_TRANSLATOR (Stanza_number_align_engraver, /* doc */ diff --git a/lily/stanza-number-engraver.cc b/lily/stanza-number-engraver.cc index 892bae633c..54432ff1bc 100644 --- a/lily/stanza-number-engraver.cc +++ b/lily/stanza-number-engraver.cc @@ -83,7 +83,12 @@ Stanza_number_engraver::stop_translation_timestep () #include "translator.icc" -ADD_ACKNOWLEDGER (Stanza_number_engraver, lyric_syllable); +void +Stanza_number_engraver::boot () +{ + ADD_ACKNOWLEDGER (Stanza_number_engraver, lyric_syllable); +} + ADD_TRANSLATOR (Stanza_number_engraver, /* doc */ "Engrave stanza numbers.", diff --git a/lily/stem-engraver.cc b/lily/stem-engraver.cc index 2f2eaf82da..81e31dcc36 100644 --- a/lily/stem-engraver.cc +++ b/lily/stem-engraver.cc @@ -212,7 +212,6 @@ Stem_engraver::stop_translation_timestep () tremolo_ev_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Stem_engraver, tuplet_span); void Stem_engraver::listen_tuplet_span (Stream_event *ev) { @@ -226,14 +225,20 @@ Stem_engraver::listen_tuplet_span (Stream_event *ev) } } -IMPLEMENT_TRANSLATOR_LISTENER (Stem_engraver, tremolo); void Stem_engraver::listen_tremolo (Stream_event *ev) { ASSIGN_EVENT_ONCE (tremolo_ev_, ev); } -ADD_ACKNOWLEDGER (Stem_engraver, rhythmic_head); + +void +Stem_engraver::boot () +{ + ADD_LISTENER (Stem_engraver, tuplet_span); + ADD_LISTENER (Stem_engraver, tremolo); + ADD_ACKNOWLEDGER (Stem_engraver, rhythmic_head); +} ADD_TRANSLATOR (Stem_engraver, /* doc */ diff --git a/lily/system-start-delimiter-engraver.cc b/lily/system-start-delimiter-engraver.cc index 7eadbb0eec..ade977859a 100644 --- a/lily/system-start-delimiter-engraver.cc +++ b/lily/system-start-delimiter-engraver.cc @@ -229,8 +229,13 @@ System_start_delimiter_engraver::acknowledge_system_start_delimiter (Grob_info i nesting_->add_support (inf.grob ()); } -ADD_ACKNOWLEDGER (System_start_delimiter_engraver, staff_symbol); -ADD_ACKNOWLEDGER (System_start_delimiter_engraver, system_start_delimiter); + +void +System_start_delimiter_engraver::boot () +{ + ADD_ACKNOWLEDGER (System_start_delimiter_engraver, staff_symbol); + ADD_ACKNOWLEDGER (System_start_delimiter_engraver, system_start_delimiter); +} ADD_TRANSLATOR (System_start_delimiter_engraver, /* doc */ diff --git a/lily/tab-note-heads-engraver.cc b/lily/tab-note-heads-engraver.cc index 4d47d77982..e452e8f717 100644 --- a/lily/tab-note-heads-engraver.cc +++ b/lily/tab-note-heads-engraver.cc @@ -61,21 +61,18 @@ Tab_note_heads_engraver::Tab_note_heads_engraver () { } -IMPLEMENT_TRANSLATOR_LISTENER (Tab_note_heads_engraver, note); void Tab_note_heads_engraver::listen_note (Stream_event *ev) { note_events_.push_back (ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Tab_note_heads_engraver, string_number); void Tab_note_heads_engraver::listen_string_number (Stream_event *ev) { tabstring_events_.push_back (ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Tab_note_heads_engraver, fingering); void Tab_note_heads_engraver::listen_fingering (Stream_event *ev) { @@ -142,6 +139,14 @@ Tab_note_heads_engraver::stop_translation_timestep () fingering_events_.clear (); } +void +Tab_note_heads_engraver::boot () +{ + ADD_LISTENER (Tab_note_heads_engraver, note); + ADD_LISTENER (Tab_note_heads_engraver, string_number); + ADD_LISTENER (Tab_note_heads_engraver, fingering); +} + ADD_TRANSLATOR (Tab_note_heads_engraver, /* doc */ "Generate one or more tablature note heads from event of type" diff --git a/lily/tab-staff-symbol-engraver.cc b/lily/tab-staff-symbol-engraver.cc index be0b343de3..f1f95df49c 100644 --- a/lily/tab-staff-symbol-engraver.cc +++ b/lily/tab-staff-symbol-engraver.cc @@ -42,7 +42,12 @@ Tab_staff_symbol_engraver::Tab_staff_symbol_engraver () #include "translator.icc" -ADD_ACKNOWLEDGER (Tab_staff_symbol_engraver, staff_symbol); +void +Tab_staff_symbol_engraver::boot () +{ + ADD_ACKNOWLEDGER (Tab_staff_symbol_engraver, staff_symbol); +} + ADD_TRANSLATOR (Tab_staff_symbol_engraver, /* doc */ "Create a tablature staff symbol, but look at" diff --git a/lily/tab-tie-follow-engraver.cc b/lily/tab-tie-follow-engraver.cc index b26bf0f6f6..b8e9966862 100644 --- a/lily/tab-tie-follow-engraver.cc +++ b/lily/tab-tie-follow-engraver.cc @@ -110,9 +110,14 @@ Tab_tie_follow_engraver::stop_translation_timestep () note_heads_.clear (); } -ADD_ACKNOWLEDGER (Tab_tie_follow_engraver, slur); -ADD_ACKNOWLEDGER (Tab_tie_follow_engraver, glissando); -ADD_ACKNOWLEDGER (Tab_tie_follow_engraver, tab_note_head); + +void +Tab_tie_follow_engraver::boot () +{ + ADD_ACKNOWLEDGER (Tab_tie_follow_engraver, slur); + ADD_ACKNOWLEDGER (Tab_tie_follow_engraver, glissando); + ADD_ACKNOWLEDGER (Tab_tie_follow_engraver, tab_note_head); +} ADD_TRANSLATOR (Tab_tie_follow_engraver, /* doc */ diff --git a/lily/tempo-performer.cc b/lily/tempo-performer.cc index b17e9202cb..683f133d64 100644 --- a/lily/tempo-performer.cc +++ b/lily/tempo-performer.cc @@ -85,6 +85,12 @@ Tempo_performer::stop_translation_timestep () } } +void +Tempo_performer::boot () +{ + +} + ADD_TRANSLATOR (Tempo_performer, /* doc */ "", diff --git a/lily/text-engraver.cc b/lily/text-engraver.cc index 2a12e75a7a..7dd1e36e75 100644 --- a/lily/text-engraver.cc +++ b/lily/text-engraver.cc @@ -46,7 +46,6 @@ protected: DECLARE_TRANSLATOR_LISTENER (text_script); }; -IMPLEMENT_TRANSLATOR_LISTENER (Text_engraver, text_script); void Text_engraver::listen_text_script (Stream_event *ev) { @@ -110,7 +109,13 @@ Text_engraver::Text_engraver () { } -ADD_ACKNOWLEDGER (Text_engraver, note_column); + +void +Text_engraver::boot () +{ + ADD_LISTENER (Text_engraver, text_script); + ADD_ACKNOWLEDGER (Text_engraver, note_column); +} ADD_TRANSLATOR (Text_engraver, /* doc */ diff --git a/lily/text-spanner-engraver.cc b/lily/text-spanner-engraver.cc index 249fdce04a..7ede49e54d 100644 --- a/lily/text-spanner-engraver.cc +++ b/lily/text-spanner-engraver.cc @@ -55,7 +55,6 @@ Text_spanner_engraver::Text_spanner_engraver () event_drul_.set (0, 0); } -IMPLEMENT_TRANSLATOR_LISTENER (Text_spanner_engraver, text_span); void Text_spanner_engraver::listen_text_span (Stream_event *ev) { @@ -156,7 +155,13 @@ Text_spanner_engraver::acknowledge_note_column (Grob_info info) } } -ADD_ACKNOWLEDGER (Text_spanner_engraver, note_column); + +void +Text_spanner_engraver::boot () +{ + ADD_LISTENER (Text_spanner_engraver, text_span); + ADD_ACKNOWLEDGER (Text_spanner_engraver, note_column); +} ADD_TRANSLATOR (Text_spanner_engraver, /* doc */ diff --git a/lily/tie-engraver.cc b/lily/tie-engraver.cc index 56fb4a337d..1e48db7e9a 100644 --- a/lily/tie-engraver.cc +++ b/lily/tie-engraver.cc @@ -101,7 +101,6 @@ Tie_engraver::Tie_engraver () event_processed_ = false; } -IMPLEMENT_TRANSLATOR_LISTENER (Tie_engraver, tie); void Tie_engraver::listen_tie (Stream_event *ev) { @@ -385,7 +384,13 @@ Tie_engraver::typeset_tie (Spanner *her) her->set_bound (RIGHT, right_head); } -ADD_ACKNOWLEDGER (Tie_engraver, note_head); +void +Tie_engraver::boot () +{ + ADD_LISTENER (Tie_engraver, tie); + ADD_ACKNOWLEDGER (Tie_engraver, note_head); +} + ADD_TRANSLATOR (Tie_engraver, /* doc */ "Generate ties between note heads of equal pitch.", diff --git a/lily/tie-performer.cc b/lily/tie-performer.cc index b1aa15ffeb..51fcf07193 100644 --- a/lily/tie-performer.cc +++ b/lily/tie-performer.cc @@ -61,7 +61,6 @@ Tie_performer::Tie_performer () event_ = 0; } -IMPLEMENT_TRANSLATOR_LISTENER (Tie_performer, tie); void Tie_performer::listen_tie (Stream_event *ev) { @@ -184,6 +183,12 @@ Tie_performer::stop_translation_timestep () now_tied_heads_.clear (); } +void +Tie_performer::boot () +{ + ADD_LISTENER (Tie_performer, tie); +} + ADD_TRANSLATOR (Tie_performer, /* doc */ "Generate ties between note heads of equal pitch.", diff --git a/lily/time-signature-engraver.cc b/lily/time-signature-engraver.cc index df6ae6dd1b..186d9e20e0 100644 --- a/lily/time-signature-engraver.cc +++ b/lily/time-signature-engraver.cc @@ -60,7 +60,6 @@ Time_signature_engraver::Time_signature_engraver () last_time_fraction_ = SCM_BOOL_F; } -IMPLEMENT_TRANSLATOR_LISTENER (Time_signature_engraver, time_signature); void Time_signature_engraver::listen_time_signature (Stream_event *ev) { @@ -116,6 +115,12 @@ Time_signature_engraver::stop_translation_timestep () time_cause_ = SCM_EOL; } +void +Time_signature_engraver::boot () +{ + ADD_LISTENER (Time_signature_engraver, time_signature); +} + ADD_TRANSLATOR (Time_signature_engraver, /* doc */ "Create a @ref{TimeSignature} whenever" diff --git a/lily/time-signature-performer.cc b/lily/time-signature-performer.cc index d9c25554fd..3a3bbd2ca3 100644 --- a/lily/time-signature-performer.cc +++ b/lily/time-signature-performer.cc @@ -81,6 +81,12 @@ Time_signature_performer::stop_translation_timestep () #include "translator.icc" +void +Time_signature_performer::boot () +{ + +} + ADD_TRANSLATOR (Time_signature_performer, /* doc */ "", diff --git a/lily/timing-translator.cc b/lily/timing-translator.cc index 9bd7e758d8..4716eceb24 100644 --- a/lily/timing-translator.cc +++ b/lily/timing-translator.cc @@ -223,6 +223,12 @@ Timing_translator::start_translation_timestep () #include "translator.icc" +void +Timing_translator::boot () +{ + +} + ADD_TRANSLATOR (Timing_translator, /* doc */ "This engraver adds the alias @code{Timing} to its containing" diff --git a/lily/trill-spanner-engraver.cc b/lily/trill-spanner-engraver.cc index eb36aff7e6..421a333a86 100644 --- a/lily/trill-spanner-engraver.cc +++ b/lily/trill-spanner-engraver.cc @@ -63,7 +63,6 @@ Trill_spanner_engraver::Trill_spanner_engraver () event_drul_.set (0, 0); } -IMPLEMENT_TRANSLATOR_LISTENER (Trill_spanner_engraver, trill_span); void Trill_spanner_engraver::listen_trill_span (Stream_event *ev) { @@ -152,7 +151,13 @@ Trill_spanner_engraver::finalize () } } -ADD_ACKNOWLEDGER (Trill_spanner_engraver, note_column); + +void +Trill_spanner_engraver::boot () +{ + ADD_LISTENER (Trill_spanner_engraver, trill_span); + ADD_ACKNOWLEDGER (Trill_spanner_engraver, note_column); +} ADD_TRANSLATOR (Trill_spanner_engraver, /* doc */ diff --git a/lily/tuplet-engraver.cc b/lily/tuplet-engraver.cc index 369389200f..d8be4c2097 100644 --- a/lily/tuplet-engraver.cc +++ b/lily/tuplet-engraver.cc @@ -73,7 +73,6 @@ protected: void process_music (); }; -IMPLEMENT_TRANSLATOR_LISTENER (Tuplet_engraver, tuplet_span); void Tuplet_engraver::listen_tuplet_span (Stream_event *ev) { @@ -272,10 +271,16 @@ Tuplet_engraver::Tuplet_engraver () { } -ADD_ACKNOWLEDGER (Tuplet_engraver, note_column); -ADD_ACKNOWLEDGER (Tuplet_engraver, script); -ADD_ACKNOWLEDGER (Tuplet_engraver, finger); -ADD_ACKNOWLEDGER (Tuplet_engraver, string_number); +void +Tuplet_engraver::boot () +{ + ADD_LISTENER (Tuplet_engraver, tuplet_span); + ADD_ACKNOWLEDGER (Tuplet_engraver, note_column); + ADD_ACKNOWLEDGER (Tuplet_engraver, script); + ADD_ACKNOWLEDGER (Tuplet_engraver, finger); + ADD_ACKNOWLEDGER (Tuplet_engraver, string_number); +} + ADD_TRANSLATOR (Tuplet_engraver, /* doc */ "Catch tuplet events and generate appropriate bracket.", diff --git a/lily/tweak-engraver.cc b/lily/tweak-engraver.cc index 81138b3670..d709765e5c 100644 --- a/lily/tweak-engraver.cc +++ b/lily/tweak-engraver.cc @@ -81,7 +81,12 @@ Tweak_engraver::acknowledge_grob (Grob_info info) } } -ADD_ACKNOWLEDGER (Tweak_engraver, grob); +void +Tweak_engraver::boot () +{ + ADD_ACKNOWLEDGER (Tweak_engraver, grob); +} + ADD_TRANSLATOR (Tweak_engraver, /* doc */ "Read the @code{tweaks} property from the originating event," diff --git a/lily/vaticana-ligature-engraver.cc b/lily/vaticana-ligature-engraver.cc index a98471369c..35c645a5f6 100644 --- a/lily/vaticana-ligature-engraver.cc +++ b/lily/vaticana-ligature-engraver.cc @@ -86,14 +86,12 @@ protected: DECLARE_TRANSLATOR_LISTENER (ligature); }; -IMPLEMENT_TRANSLATOR_LISTENER (Vaticana_ligature_engraver, pes_or_flexa); void Vaticana_ligature_engraver::listen_pes_or_flexa (Stream_event *ev) { Gregorian_ligature_engraver::listen_pes_or_flexa (ev); } -IMPLEMENT_TRANSLATOR_LISTENER (Vaticana_ligature_engraver, ligature); void Vaticana_ligature_engraver::listen_ligature (Stream_event *ev) { @@ -741,8 +739,15 @@ Vaticana_ligature_engraver::transform_heads (Spanner *ligature, #endif } -ADD_ACKNOWLEDGER (Vaticana_ligature_engraver, rest); -ADD_ACKNOWLEDGER (Vaticana_ligature_engraver, ligature_head); +void +Vaticana_ligature_engraver::boot () +{ + ADD_LISTENER (Vaticana_ligature_engraver, pes_or_flexa); + ADD_LISTENER (Vaticana_ligature_engraver, ligature); + ADD_ACKNOWLEDGER (Vaticana_ligature_engraver, rest); + ADD_ACKNOWLEDGER (Vaticana_ligature_engraver, ligature_head); +} + ADD_TRANSLATOR (Vaticana_ligature_engraver, /* doc */ "Handle ligatures by glueing special ligature heads" diff --git a/lily/vertical-align-engraver.cc b/lily/vertical-align-engraver.cc index 6a47809fd7..40d4146828 100644 --- a/lily/vertical-align-engraver.cc +++ b/lily/vertical-align-engraver.cc @@ -48,7 +48,12 @@ protected: bool top_level_; }; -ADD_ACKNOWLEDGER (Vertical_align_engraver, axis_group); +void +Vertical_align_engraver::boot () +{ + ADD_ACKNOWLEDGER (Vertical_align_engraver, axis_group); +} + ADD_TRANSLATOR (Vertical_align_engraver, /* doc */ "Catch groups (staves, lyrics lines, etc.) and stack them" diff --git a/lily/volta-engraver.cc b/lily/volta-engraver.cc index bd198cbb67..837c3b7b57 100644 --- a/lily/volta-engraver.cc +++ b/lily/volta-engraver.cc @@ -189,7 +189,12 @@ Volta_engraver::stop_translation_timestep () /* TODO: should attach volta to paper-column if no bar is found. */ -ADD_ACKNOWLEDGER (Volta_engraver, bar_line); +void +Volta_engraver::boot () +{ + ADD_ACKNOWLEDGER (Volta_engraver, bar_line); +} + ADD_TRANSLATOR (Volta_engraver, /* doc */ "Make volta brackets.", |