From 38fa6a3720e1187ec51514ab2a209c67ce19e14c Mon Sep 17 00:00:00 2001 From: Jan Nieuwenhuizen Date: Tue, 21 Nov 2000 20:14:26 +0100 Subject: [PATCH] patch::: 1.3.109.jcn1 1.3.109.jcn1 ============ * Collapsed all ``void Foo::create_grobs () { deprecated_process_music (); }'' occurences, and reactivated some disabled code (note-name, chord-name, custos, lyrics). Reactivated Timing_translator using process_music (). --- CHANGES | 8 ++++++ VERSION | 2 +- input/test/grace.ly | 2 +- lily/a2-engraver.cc | 9 +------ lily/bar-engraver.cc | 9 +------ lily/bar-number-engraver.cc | 11 ++------- lily/beam-engraver.cc | 11 ++------- lily/breathing-sign-engraver.cc | 6 ++--- lily/chord-name-engraver.cc | 35 ++------------------------ lily/chord-tremolo-engraver.cc | 7 ------ lily/clef-engraver.cc | 17 +------------ lily/custos-engraver.cc | 16 +++--------- lily/dynamic-engraver.cc | 9 +------ lily/dynamic-performer.cc | 15 +----------- lily/extender-engraver.cc | 7 ------ lily/hyphen-engraver.cc | 7 ------ lily/include/lyric-engraver.hh | 38 ----------------------------- lily/include/timing-translator.hh | 6 ++--- lily/key-engraver.cc | 7 ------ lily/lyric-engraver.cc | 25 +++++++++++++++++-- lily/mark-engraver.cc | 7 ------ lily/multi-measure-rest-engraver.cc | 8 ------ lily/note-heads-engraver.cc | 19 ++------------- lily/note-name-engraver.cc | 5 ++-- lily/rest-engraver.cc | 5 ++-- lily/script-column-engraver.cc | 4 +-- lily/script-engraver.cc | 20 ++++++--------- lily/slur-engraver.cc | 9 +------ lily/span-dynamic-performer.cc | 21 ++++++---------- lily/staff-performer.cc | 1 - lily/text-engraver.cc | 7 ------ lily/text-spanner-engraver.cc | 7 ------ lily/tie-performer.cc | 23 ++++++++++++++++- lily/timing-translator.cc | 2 +- lily/tuplet-engraver.cc | 7 ------ 35 files changed, 101 insertions(+), 291 deletions(-) diff --git a/CHANGES b/CHANGES index 07c400599b..5f9ffa734c 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,11 @@ +1.3.109.jcn1 +============ + +* Collapsed all ``void Foo::create_grobs () { deprecated_process_music +(); }'' occurences, and reactivated some disabled code (note-name, +chord-name, custos, lyrics). Reactivated Timing_translator using +process_music (). + 1.3.108.uu1 =========== diff --git a/VERSION b/VERSION index b235fa36fa..cbd80a2211 100644 --- a/VERSION +++ b/VERSION @@ -2,7 +2,7 @@ PACKAGE_NAME=LilyPond MAJOR_VERSION=1 MINOR_VERSION=3 PATCH_LEVEL=109 -MY_PATCH_LEVEL= +MY_PATCH_LEVEL=jcn1 # use the above to send patches: MY_PATCH_LEVEL is always empty for a # released version. diff --git a/input/test/grace.ly b/input/test/grace.ly index a4c033c0ff..ee5fe5da8e 100644 --- a/input/test/grace.ly +++ b/input/test/grace.ly @@ -10,5 +10,5 @@ \grace { \property Grace.graceAlignPosition = \right c16} c4 } \paper {linewidth = -1.;} -%%\midi{ } +\midi{ } } diff --git a/lily/a2-engraver.cc b/lily/a2-engraver.cc index b59595a5aa..d2f56c2ef3 100644 --- a/lily/a2-engraver.cc +++ b/lily/a2-engraver.cc @@ -22,7 +22,6 @@ public: VIRTUAL_COPY_CONS (Translator); protected: - void deprecated_process_music (); virtual void acknowledge_grob (Grob_info); virtual void create_grobs (); @@ -43,7 +42,7 @@ A2_engraver::A2_engraver () void -A2_engraver::deprecated_process_music () +A2_engraver::create_grobs () { if (!to_boolean (get_property ("combineParts"))) return ; @@ -161,12 +160,6 @@ A2_engraver::acknowledge_grob (Grob_info i) } } -void -A2_engraver::create_grobs () -{ - deprecated_process_music (); -} - void A2_engraver::stop_translation_timestep () { diff --git a/lily/bar-engraver.cc b/lily/bar-engraver.cc index 4fad1f37c5..d81996fd61 100644 --- a/lily/bar-engraver.cc +++ b/lily/bar-engraver.cc @@ -28,7 +28,6 @@ public: protected: virtual void do_removal_processing (); - void deprecated_process_music(); virtual void stop_translation_timestep(); virtual void create_grobs (); @@ -70,7 +69,7 @@ Bar_engraver::do_removal_processing () modify whichBar in deprecated_process_music () be typeset */ void -Bar_engraver::deprecated_process_music() +Bar_engraver::create_grobs () { if (!bar_p_ && gh_string_p (get_property ("whichBar"))) { @@ -78,12 +77,6 @@ Bar_engraver::deprecated_process_music() } } -void -Bar_engraver::create_grobs () -{ - deprecated_process_music (); -} - void Bar_engraver::typeset_bar () { diff --git a/lily/bar-number-engraver.cc b/lily/bar-number-engraver.cc index 5a32db3481..1b4646f14c 100644 --- a/lily/bar-number-engraver.cc +++ b/lily/bar-number-engraver.cc @@ -29,14 +29,14 @@ protected: virtual void do_creation_processing (); virtual void create_grobs (); void create_items(); - void deprecated_process_music (); + public: VIRTUAL_COPY_CONS(Translator); Bar_number_engraver(); }; void -Bar_number_engraver::deprecated_process_music () +Bar_number_engraver::create_grobs () { // todo include (&&!time->cadenza_b_ ) SCM bn = get_property("currentBarNumber"); @@ -54,13 +54,6 @@ Bar_number_engraver::deprecated_process_music () } } -void -Bar_number_engraver::create_grobs () -{ - deprecated_process_music (); -} - - ADD_THIS_TRANSLATOR(Bar_number_engraver); Bar_number_engraver::Bar_number_engraver () diff --git a/lily/beam-engraver.cc b/lily/beam-engraver.cc index a49a2bb1f4..6724ac8b4b 100644 --- a/lily/beam-engraver.cc +++ b/lily/beam-engraver.cc @@ -48,7 +48,7 @@ protected: virtual void create_grobs (); virtual void acknowledge_grob (Grob_info); virtual bool try_music (Music*); - void deprecated_process_music (); + public: Beam_engraver (); VIRTUAL_COPY_CONS (Translator); @@ -116,7 +116,7 @@ Beam_engraver::set_melisma (bool m) void -Beam_engraver::deprecated_process_music () +Beam_engraver::create_grobs () { if (reqs_drul_[STOP]) { @@ -228,13 +228,6 @@ Beam_engraver::do_removal_processing () } } -void -Beam_engraver::create_grobs () -{ - deprecated_process_music (); -} - - void Beam_engraver::acknowledge_grob (Grob_info info) { diff --git a/lily/breathing-sign-engraver.cc b/lily/breathing-sign-engraver.cc index 5a24b9c6c9..5e1c08fa2f 100644 --- a/lily/breathing-sign-engraver.cc +++ b/lily/breathing-sign-engraver.cc @@ -29,8 +29,7 @@ public: protected: virtual bool try_music (Music *req_l); - void deprecated_process_music(); - + virtual void create_grobs (); virtual void stop_translation_timestep(); virtual void start_translation_timestep(); @@ -58,7 +57,7 @@ Breathing_sign_engraver::try_music (Music*r_l) } void -Breathing_sign_engraver::deprecated_process_music() +Breathing_sign_engraver::create_grobs () { if(breathing_sign_req_l_ && ! breathing_sign_p_) { @@ -68,6 +67,7 @@ Breathing_sign_engraver::deprecated_process_music() Breathing_sign::set_interface (breathing_sign_p_); announce_grob (breathing_sign_p_, breathing_sign_req_l_); + breathing_sign_req_l_ = 0; } } diff --git a/lily/chord-name-engraver.cc b/lily/chord-name-engraver.cc index 7b72e3bc26..a8143f1845 100644 --- a/lily/chord-name-engraver.cc +++ b/lily/chord-name-engraver.cc @@ -28,7 +28,7 @@ public: protected: virtual void stop_translation_timestep (); virtual void acknowledge_grob (Grob_info i); - void deprecated_process_music (); + virtual void create_grobs (); virtual bool try_music (Music *); private: @@ -77,24 +77,6 @@ Chord_name_engraver::try_music (Music* m) return false; } -/* Uh, if we do acknowledge_grob, shouldn't we postpone - deprecated_process_music until do_process_acknowlegded? - - Sigh, I can *never* remember how this works, can't we - possibly-please just number these functions: - - do_creation0 - - post_move1 - try_music2 - deprecated_process_music3 (or is it acknowledge_grob3 ?) - acknowledge_grob4 - - do_pre_move9 - - do_removal99 - - and what was the deal with this ``do'' prefix again? */ void Chord_name_engraver::acknowledge_grob (Grob_info i) { @@ -103,23 +85,10 @@ Chord_name_engraver::acknowledge_grob (Grob_info i) } void -Chord_name_engraver::deprecated_process_music () +Chord_name_engraver::create_grobs () { if (!chord_name_p_ && gh_car (chord_) != SCM_EOL) { -#if 0 - bool find_inversion_b = false; - SCM chord_inversion = get_property ("chordInversion"); - if (gh_boolean_p (chord_inversion)) - find_inversion_b = gh_scm2bool (chord_inversion); - - chord_ = Chord::pitches_and_requests_to_chord (pitches_, - inversion_, - bass_, - find_inversion_b); - -#endif - chord_name_p_ = new Item (get_property ("ChordName")); chord_name_p_->set_grob_property ("chord", chord_); announce_grob (chord_name_p_, 0); diff --git a/lily/chord-tremolo-engraver.cc b/lily/chord-tremolo-engraver.cc index a71c7f1041..6296b225fc 100644 --- a/lily/chord-tremolo-engraver.cc +++ b/lily/chord-tremolo-engraver.cc @@ -58,7 +58,6 @@ protected: protected: virtual void do_removal_processing(); - void deprecated_process_music(); virtual bool try_music (Music*); virtual void acknowledge_grob (Grob_info); virtual void stop_translation_timestep(); @@ -95,12 +94,6 @@ Chord_tremolo_engraver::try_music (Music * m) void Chord_tremolo_engraver::create_grobs () -{ - deprecated_process_music (); -} - -void -Chord_tremolo_engraver::deprecated_process_music () { if (repeat_ && !beam_p_) { diff --git a/lily/clef-engraver.cc b/lily/clef-engraver.cc index b0e1408229..06758d2629 100644 --- a/lily/clef-engraver.cc +++ b/lily/clef-engraver.cc @@ -33,9 +33,7 @@ public: Direction octave_dir_; protected: - void deprecated_process_music (); virtual void stop_translation_timestep (); - virtual void do_creation_processing (); virtual void start_translation_timestep (); virtual void create_grobs (); virtual void acknowledge_grob (Grob_info); @@ -114,7 +112,7 @@ Clef_engraver::set_glyph () void Clef_engraver::acknowledge_grob (Grob_info info) { - deprecated_process_music (); + create_grobs (); Item * item =dynamic_cast (info.elem_l_); if (item) { @@ -145,13 +143,6 @@ Clef_engraver::acknowledge_grob (Grob_info info) } } -void -Clef_engraver::do_creation_processing () -{ -} - - - void Clef_engraver::create_clef () { @@ -185,12 +176,6 @@ Clef_engraver::create_clef () void Clef_engraver::create_grobs () -{ - deprecated_process_music (); -} - -void -Clef_engraver::deprecated_process_music () { SCM glyph = get_property ("clefGlyph"); SCM clefpos = get_property ("clefPosition"); diff --git a/lily/custos-engraver.cc b/lily/custos-engraver.cc index 63ae946016..4f8cbcf5e3 100644 --- a/lily/custos-engraver.cc +++ b/lily/custos-engraver.cc @@ -26,7 +26,6 @@ public: Custos_engraver(); virtual void start_translation_timestep(); virtual void acknowledge_grob(Grob_info); - void deprecated_process_music (); virtual void create_grobs (); virtual void stop_translation_timestep (); virtual void do_removal_processing (); @@ -67,16 +66,6 @@ Custos_engraver::start_translation_timestep () } -/* - TODO check if this works with forced bar lines? - */ -void -Custos_engraver::deprecated_process_music () -{ - if (gh_string_p (get_property( "whichBar"))) - custos_permitted = true; -} - void Custos_engraver::acknowledge_grob (Grob_info info) { @@ -106,8 +95,9 @@ Custos_engraver::acknowledge_grob (Grob_info info) void Custos_engraver::create_grobs () { - deprecated_process_music (); - + if (gh_string_p (get_property( "whichBar"))) + custos_permitted = true; + if (custos_permitted) { for (int i = pitches_.size (); i--;) diff --git a/lily/dynamic-engraver.cc b/lily/dynamic-engraver.cc index 881eb90e57..278662636b 100644 --- a/lily/dynamic-engraver.cc +++ b/lily/dynamic-engraver.cc @@ -57,7 +57,6 @@ protected: virtual void do_removal_processing (); virtual void acknowledge_grob (Grob_info); virtual bool try_music (Music *req_l); - void deprecated_process_music (); virtual void stop_translation_timestep (); virtual void create_grobs (); virtual void start_translation_timestep (); @@ -122,7 +121,7 @@ Dynamic_engraver::try_music (Music * m) } void -Dynamic_engraver::deprecated_process_music () +Dynamic_engraver::create_grobs () { if (accepted_spanreqs_drul_[START] || accepted_spanreqs_drul_[STOP] || script_req_l_) @@ -286,12 +285,6 @@ Dynamic_engraver::stop_translation_timestep () typeset_all (); } -void -Dynamic_engraver::create_grobs () -{ - deprecated_process_music (); -} - void Dynamic_engraver::do_removal_processing () { diff --git a/lily/dynamic-performer.cc b/lily/dynamic-performer.cc index 552a769826..d69c38f0f5 100644 --- a/lily/dynamic-performer.cc +++ b/lily/dynamic-performer.cc @@ -25,11 +25,9 @@ public: VIRTUAL_COPY_CONS (Translator); Dynamic_performer (); - ~Dynamic_performer (); protected: virtual bool try_music (Music* req_l); - void deprecated_process_music (); virtual void stop_translation_timestep (); virtual void create_grobs (); @@ -46,13 +44,8 @@ Dynamic_performer::Dynamic_performer () audio_p_ = 0; } -Dynamic_performer::~Dynamic_performer () -{ -} - - void -Dynamic_performer::deprecated_process_music () +Dynamic_performer::create_grobs () { if (script_req_l_) { @@ -119,12 +112,6 @@ Dynamic_performer::deprecated_process_music () } } -void -Dynamic_performer::create_grobs () -{ - deprecated_process_music (); -} - void Dynamic_performer::stop_translation_timestep () { diff --git a/lily/extender-engraver.cc b/lily/extender-engraver.cc index 8128598f6b..c82648d9f2 100644 --- a/lily/extender-engraver.cc +++ b/lily/extender-engraver.cc @@ -39,7 +39,6 @@ public: protected: virtual void acknowledge_grob (Grob_info); virtual void do_removal_processing(); - void deprecated_process_music(); virtual bool try_music (Music*); virtual void stop_translation_timestep(); virtual void start_translation_timestep (); @@ -103,12 +102,6 @@ Extender_engraver::do_removal_processing () void Extender_engraver::create_grobs () -{ - deprecated_process_music (); -} - -void -Extender_engraver::deprecated_process_music () { if (req_l_ && ! extender_p_) { diff --git a/lily/hyphen-engraver.cc b/lily/hyphen-engraver.cc index ebb56587ba..224a517b6e 100644 --- a/lily/hyphen-engraver.cc +++ b/lily/hyphen-engraver.cc @@ -33,7 +33,6 @@ public: protected: virtual void acknowledge_grob (Grob_info); virtual void do_removal_processing(); - void deprecated_process_music(); virtual bool try_music (Music*); virtual void stop_translation_timestep(); virtual void start_translation_timestep (); @@ -95,12 +94,6 @@ Hyphen_engraver::do_removal_processing () void Hyphen_engraver::create_grobs () -{ - deprecated_process_music (); -} - -void -Hyphen_engraver::deprecated_process_music () { if (req_l_ &&! hyphen_p_) { diff --git a/lily/include/lyric-engraver.hh b/lily/include/lyric-engraver.hh index 455ed51d79..e69de29bb2 100644 --- a/lily/include/lyric-engraver.hh +++ b/lily/include/lyric-engraver.hh @@ -1,38 +0,0 @@ -/* - lyric-engraver.hh -- declare Lyric_engraver - - source file of the GNU LilyPond music typesetter - - (c) 1997--2000 Han-Wen Nienhuys -*/ - - -#ifndef LYRIC_ENGRAVER_HH -#define LYRIC_ENGRAVER_HH - -#include "lily-proto.hh" -#include "engraver.hh" -#include "array.hh" - -/** - Generate texts for lyric syllables. We only do one lyric at a time. - Multiple copies of this engraver should be used to do multiple voices. - */ -class Lyric_engraver : public Engraver -{ -protected: - virtual void stop_translation_timestep(); - virtual bool try_music (Music*); - void deprecated_process_music(); - virtual void start_translation_timestep (); -public: - Lyric_engraver (); - VIRTUAL_COPY_CONS (Translator); - -private: - Lyric_req * req_l_; - Item* text_p_; -}; - - -#endif // LYRIC_ENGRAVER_HH diff --git a/lily/include/timing-translator.hh b/lily/include/timing-translator.hh index d78dce109f..d55de124be 100644 --- a/lily/include/timing-translator.hh +++ b/lily/include/timing-translator.hh @@ -27,9 +27,9 @@ public: protected: virtual void do_creation_processing (); virtual bool try_music (Music *req_l); - void deprecated_process_music(); - virtual void stop_translation_timestep(); - virtual void start_translation_timestep(); + virtual void process_music (); + virtual void stop_translation_timestep (); + virtual void start_translation_timestep (); public: Moment measure_position () const; diff --git a/lily/key-engraver.cc b/lily/key-engraver.cc index ebe26164e4..f37ef88881 100644 --- a/lily/key-engraver.cc +++ b/lily/key-engraver.cc @@ -40,7 +40,6 @@ protected: virtual void do_creation_processing(); virtual void do_removal_processing (); virtual bool try_music (Music *req_l); - void deprecated_process_music(); virtual void stop_translation_timestep(); virtual void start_translation_timestep(); virtual void create_grobs (); @@ -130,12 +129,6 @@ Key_engraver::acknowledge_grob (Grob_info info) void Key_engraver::create_grobs () -{ - deprecated_process_music (); -} - -void -Key_engraver::deprecated_process_music () { if (keyreq_l_ || old_accs_ != get_property ("keySignature")) { diff --git a/lily/lyric-engraver.cc b/lily/lyric-engraver.cc index 5c1117637c..9fff756ede 100644 --- a/lily/lyric-engraver.cc +++ b/lily/lyric-engraver.cc @@ -7,13 +7,34 @@ Jan Nieuwenhuizen */ -#include "lyric-engraver.hh" +#include "engraver.hh" #include "musical-request.hh" #include "item.hh" #include "paper-def.hh" #include "font-metric.hh" #include "side-position-interface.hh" +/** + Generate texts for lyric syllables. We only do one lyric at a time. + Multiple copies of this engraver should be used to do multiple voices. + */ +class Lyric_engraver : public Engraver +{ +protected: + virtual void stop_translation_timestep(); + virtual bool try_music (Music *); + virtual void create_grobs (); + virtual void start_translation_timestep (); + +public: + Lyric_engraver (); + VIRTUAL_COPY_CONS (Translator); + +private: + Lyric_req * req_l_; + Item* text_p_; +}; + ADD_THIS_TRANSLATOR (Lyric_engraver); @@ -37,7 +58,7 @@ Lyric_engraver::try_music (Music*r) } void -Lyric_engraver::deprecated_process_music() +Lyric_engraver::create_grobs () { if (req_l_) { diff --git a/lily/mark-engraver.cc b/lily/mark-engraver.cc index d872f5cc53..d70766eb9c 100644 --- a/lily/mark-engraver.cc +++ b/lily/mark-engraver.cc @@ -38,7 +38,6 @@ protected: virtual void acknowledge_grob (Grob_info); void create_items(Request*); virtual bool try_music (Music *req_l); - void deprecated_process_music (); virtual void start_translation_timestep (); virtual void do_creation_processing (); virtual void create_grobs (); @@ -138,12 +137,6 @@ Mark_engraver::try_music (Music* r_l) void Mark_engraver::create_grobs () -{ - deprecated_process_music (); -} - -void -Mark_engraver::deprecated_process_music () { if (mark_req_l_) { diff --git a/lily/multi-measure-rest-engraver.cc b/lily/multi-measure-rest-engraver.cc index 581b4453e8..f31b58d34f 100644 --- a/lily/multi-measure-rest-engraver.cc +++ b/lily/multi-measure-rest-engraver.cc @@ -30,7 +30,6 @@ public: protected: virtual void acknowledge_grob (Grob_info i); - void deprecated_process_music (); virtual bool try_music (Music*); virtual void stop_translation_timestep (); virtual void start_translation_timestep (); @@ -95,13 +94,6 @@ Multi_measure_rest_engraver::try_music (Music* req_l) void Multi_measure_rest_engraver::create_grobs () -{ - deprecated_process_music (); -} - - -void -Multi_measure_rest_engraver::deprecated_process_music () { if (new_req_l_ && stop_req_l_) stop_req_l_ = 0; diff --git a/lily/note-heads-engraver.cc b/lily/note-heads-engraver.cc index 4b009d6081..b791c222ff 100644 --- a/lily/note-heads-engraver.cc +++ b/lily/note-heads-engraver.cc @@ -25,25 +25,16 @@ class Note_heads_engraver : public Engraver Moment note_end_mom_; public: VIRTUAL_COPY_CONS(Translator); - Note_heads_engraver(); protected: virtual void start_translation_timestep (); virtual bool try_music (Music *req_l) ; virtual void create_grobs (); virtual void acknowledge_grob (Grob_info) ; - void deprecated_process_music(); virtual void stop_translation_timestep(); }; - - - -Note_heads_engraver::Note_heads_engraver() -{ -} - bool Note_heads_engraver::try_music (Music *m) { @@ -62,20 +53,14 @@ Note_heads_engraver::try_music (Music *m) } -void -Note_heads_engraver::create_grobs () -{ - deprecated_process_music (); -} - void Note_heads_engraver::acknowledge_grob (Grob_info) { - //deprecated_process_music (); + //create_grobs (); } void -Note_heads_engraver::deprecated_process_music() +Note_heads_engraver::create_grobs () { if (note_p_arr_.size ()) return ; diff --git a/lily/note-name-engraver.cc b/lily/note-name-engraver.cc index 3a76ba6ae0..ed76699feb 100644 --- a/lily/note-name-engraver.cc +++ b/lily/note-name-engraver.cc @@ -18,7 +18,7 @@ public: Link_array req_l_arr_; Link_array texts_; virtual bool try_music (Music*m); - void deprecated_process_music (); + virtual void create_grobs (); virtual void stop_translation_timestep (); }; @@ -33,9 +33,8 @@ Note_name_engraver::try_music (Music *m) return false; } - void -Note_name_engraver::deprecated_process_music () +Note_name_engraver::create_grobs () { if (texts_.size ()) return; diff --git a/lily/rest-engraver.cc b/lily/rest-engraver.cc index 9487b56ee5..599df04ace 100644 --- a/lily/rest-engraver.cc +++ b/lily/rest-engraver.cc @@ -22,7 +22,8 @@ protected: virtual bool try_music (Music *); virtual void stop_translation_timestep (); virtual void start_translation_timestep (); - void deprecated_process_music (); + virtual void create_grobs (); + public: VIRTUAL_COPY_CONS(Translator); @@ -62,7 +63,7 @@ Rest_engraver::stop_translation_timestep () } void -Rest_engraver::deprecated_process_music () +Rest_engraver::create_grobs () { if (rest_req_l_ && !rest_p_) { diff --git a/lily/script-column-engraver.cc b/lily/script-column-engraver.cc index 1eaea34a15..93e25140b8 100644 --- a/lily/script-column-engraver.cc +++ b/lily/script-column-engraver.cc @@ -26,8 +26,8 @@ public: protected: virtual void acknowledge_grob (Grob_info); virtual void create_grobs (); - virtual void stop_translation_timestep (); - virtual void start_translation_timestep (); + virtual void stop_translation_timestep (); + virtual void start_translation_timestep (); }; diff --git a/lily/script-engraver.cc b/lily/script-engraver.cc index 20329c302f..6a1b4ad75e 100644 --- a/lily/script-engraver.cc +++ b/lily/script-engraver.cc @@ -17,12 +17,11 @@ class Script_engraver : public Engraver { Link_array script_req_l_arr_; public: - VIRTUAL_COPY_CONS(Translator); - - Script_engraver(); + VIRTUAL_COPY_CONS (Translator); + protected: virtual bool try_music (Music*); - void deprecated_process_music (); + virtual void do_creation_processing (); virtual void stop_translation_timestep (); virtual void start_translation_timestep (); virtual void create_grobs (); @@ -30,9 +29,10 @@ protected: }; -Script_engraver::Script_engraver() +void +Script_engraver::do_creation_processing () { - start_translation_timestep(); + script_req_l_arr_.clear(); } bool @@ -53,12 +53,6 @@ Script_engraver::try_music (Music *r_l) void Script_engraver::create_grobs () -{ - deprecated_process_music (); -} - -void -Script_engraver::deprecated_process_music() { for (int i=0; i < script_req_l_arr_.size(); i++) { @@ -181,6 +175,6 @@ Script_engraver::start_translation_timestep() script_req_l_arr_.clear(); } -ADD_THIS_TRANSLATOR(Script_engraver); +ADD_THIS_TRANSLATOR (Script_engraver); diff --git a/lily/slur-engraver.cc b/lily/slur-engraver.cc index 09cecda14e..61f2e3e4b5 100644 --- a/lily/slur-engraver.cc +++ b/lily/slur-engraver.cc @@ -25,7 +25,6 @@ class Slur_engraver : public Engraver protected: virtual bool try_music (Music*); - void deprecated_process_music (); virtual void acknowledge_grob (Grob_info); virtual void stop_translation_timestep (); virtual void start_translation_timestep (); @@ -87,12 +86,6 @@ Slur_engraver::try_music (Music *req_l) return false; } -void -Slur_engraver::create_grobs () -{ - deprecated_process_music (); -} - void Slur_engraver::set_melisma (bool m) { @@ -137,7 +130,7 @@ Slur_engraver::do_removal_processing () } void -Slur_engraver::deprecated_process_music () +Slur_engraver::create_grobs () { Link_array start_slur_l_arr; for (int i=0; i< new_slur_req_l_arr_.size (); i++) diff --git a/lily/span-dynamic-performer.cc b/lily/span-dynamic-performer.cc index 9f6d490fee..ff0ea71474 100644 --- a/lily/span-dynamic-performer.cc +++ b/lily/span-dynamic-performer.cc @@ -31,7 +31,6 @@ protected: virtual bool try_music (Music*); virtual void acknowledge_grob (Audio_element_info); virtual void create_grobs (); - void deprecated_process_music (); virtual void stop_translation_timestep (); virtual void start_translation_timestep (); @@ -67,7 +66,7 @@ Span_dynamic_performer::acknowledge_grob (Audio_element_info i) } void -Span_dynamic_performer::deprecated_process_music () +Span_dynamic_performer::create_grobs () { if (span_start_req_l_ || span_req_l_drul_[START]) { @@ -106,26 +105,22 @@ Span_dynamic_performer::deprecated_process_music () Audio_dynamic_tuple a = { audio_p_, now_mom () }; dynamic_tuple_arr_.push (a); } -} -void -Span_dynamic_performer::create_grobs () -{ - deprecated_process_music (); - if (span_req_l_drul_[STOP]) - { - finished_dynamic_tuple_arr_.top ().audio_l_->volume_ = last_volume_; - } + if (span_req_l_drul_[STOP]) + { + finished_dynamic_tuple_arr_.top ().audio_l_->volume_ = last_volume_; + } + if (span_req_l_drul_[START]) { - dynamic_tuple_arr_[0].audio_l_->volume_ = last_volume_; + dynamic_tuple_arr_[0].audio_l_->volume_ = last_volume_; } span_start_req_l_ = 0; span_req_l_drul_[START] = 0; span_req_l_drul_[STOP] = 0; } - + void Span_dynamic_performer::stop_translation_timestep () { diff --git a/lily/staff-performer.cc b/lily/staff-performer.cc index e4381f941c..72c922af9c 100644 --- a/lily/staff-performer.cc +++ b/lily/staff-performer.cc @@ -85,7 +85,6 @@ Staff_performer::create_grobs () instrument_p_ = new Audio_instrument (str); announce_element (Audio_element_info (instrument_p_, 0)); } - //Performer_group_performer::deprecated_process_music (); } void diff --git a/lily/text-engraver.cc b/lily/text-engraver.cc index 05b078285d..b58467b016 100644 --- a/lily/text-engraver.cc +++ b/lily/text-engraver.cc @@ -30,7 +30,6 @@ protected: virtual void stop_translation_timestep (); virtual void start_translation_timestep (); virtual void create_grobs (); - void deprecated_process_music (); virtual void acknowledge_grob (Grob_info); }; @@ -79,12 +78,6 @@ Text_engraver::acknowledge_grob (Grob_info inf) void Text_engraver::create_grobs () -{ - deprecated_process_music (); -} - -void -Text_engraver::deprecated_process_music () { if (texts_.size ()) return; diff --git a/lily/text-spanner-engraver.cc b/lily/text-spanner-engraver.cc index 1a8280ab81..4d9f20d2b2 100644 --- a/lily/text-spanner-engraver.cc +++ b/lily/text-spanner-engraver.cc @@ -29,7 +29,6 @@ protected: virtual void do_removal_processing (); virtual void acknowledge_grob (Grob_info); virtual bool try_music (Music *); - void deprecated_process_music (); virtual void stop_translation_timestep (); virtual void start_translation_timestep (); virtual void create_grobs (); @@ -86,12 +85,6 @@ Text_spanner_engraver::try_music (Music *m) void Text_spanner_engraver::create_grobs () -{ - deprecated_process_music (); -} - -void -Text_spanner_engraver::deprecated_process_music () { ///// if (req_drul_[STOP]) diff --git a/lily/tie-performer.cc b/lily/tie-performer.cc index 6edbf83333..685806ff95 100644 --- a/lily/tie-performer.cc +++ b/lily/tie-performer.cc @@ -39,8 +39,10 @@ inline int compare (CNote_melodic_tuple const &a, CNote_melodic_tuple const &b) class Tie_performer : public Performer { public: - VIRTUAL_COPY_CONS(Translator); + VIRTUAL_COPY_CONS (Translator); + Tie_performer (); + private: bool done_; PQueue past_notes_pq_; @@ -50,6 +52,7 @@ private: Link_array tie_p_arr_; protected: + virtual void do_creation_processing (); virtual void start_translation_timestep (); virtual void stop_translation_timestep (); virtual void acknowledge_grob (Audio_element_info); @@ -59,6 +62,24 @@ protected: ADD_THIS_TRANSLATOR (Tie_performer); + +Tie_performer::Tie_performer () +{ + // URG + // if we don't do this, lily dumps core + // which means that ``do_creation_processing'' and + // ``start_translation_timestep'' did not happen?! + do_creation_processing (); +} + +void +Tie_performer::do_creation_processing () +{ + req_l_ = 0; + done_ = false; +} + + bool Tie_performer::try_music (Music *m) { diff --git a/lily/timing-translator.cc b/lily/timing-translator.cc index 9efa2fd4b5..b66c23ac3f 100644 --- a/lily/timing-translator.cc +++ b/lily/timing-translator.cc @@ -31,7 +31,7 @@ Timing_translator::try_music (Music*r) } void -Timing_translator::deprecated_process_music() +Timing_translator::process_music() { if (check_ && measure_position ()) { diff --git a/lily/tuplet-engraver.cc b/lily/tuplet-engraver.cc index 042541746e..542b0f7ae4 100644 --- a/lily/tuplet-engraver.cc +++ b/lily/tuplet-engraver.cc @@ -35,7 +35,6 @@ protected: virtual void do_removal_processing (); virtual void acknowledge_grob (Grob_info); virtual bool try_music (Music*r); - void deprecated_process_music (); virtual void start_translation_timestep (); virtual void create_grobs (); }; @@ -65,12 +64,6 @@ Tuplet_engraver::try_music (Music *r) void Tuplet_engraver::create_grobs () -{ - deprecated_process_music (); -} - -void -Tuplet_engraver::deprecated_process_music () { SCM v = get_property ("tupletInvisible"); if (to_boolean (v)) -- 2.39.5