From 81acef19fa4cdfc5d3f366726c541bc06d46dc3c Mon Sep 17 00:00:00 2001 From: fred Date: Sun, 24 Mar 2002 19:43:26 +0000 Subject: [PATCH] lilypond-0.0.64 --- lily/include/request-column.hh | 1 + lily/include/staff-column.hh | 1 + lily/staff-walker.cc | 40 +--------------------------------- 3 files changed, 3 insertions(+), 39 deletions(-) diff --git a/lily/include/request-column.hh b/lily/include/request-column.hh index ad198f3f04..19876c9e37 100644 --- a/lily/include/request-column.hh +++ b/lily/include/request-column.hh @@ -28,6 +28,7 @@ public: bool used_b()const; Moment when(); void add_reqs(int staff_idx, Array const&); + void update_time(int staff_idx, Time_description &); void set_score_cols(Score_column*, Score_column*); }; diff --git a/lily/include/staff-column.hh b/lily/include/staff-column.hh index b0624664be..7550ae27fa 100644 --- a/lily/include/staff-column.hh +++ b/lily/include/staff-column.hh @@ -35,6 +35,7 @@ public: void add_reqs (Array req_l_arr); void OK() const; ~Staff_column(); + void update_time(Time_description&, Rhythmic_grouping*); void typeset_breakable_items(Array &pre_p_arr, Array &nobreak_p_arr, Array &post_p_arr); diff --git a/lily/staff-walker.cc b/lily/staff-walker.cc index 97080b8949..ca6cbf500f 100644 --- a/lily/staff-walker.cc +++ b/lily/staff-walker.cc @@ -48,48 +48,10 @@ Staff_walker::when() const return ptr()->when(); } - void Staff_walker::process_timing_reqs() { - // first all meter changes - for (int i=0; i < ptr()->timing_req_l_arr_.size(); i++) { - Timing_req * tr_l = ptr()->timing_req_l_arr_[i]; - if (tr_l->meterchange()) { - int b_i=tr_l->meterchange()->beats_i_; - int o_i = tr_l->meterchange()->one_beat_i_; - if (! time_.allow_meter_change_b() ) - - tr_l->warning("Meterchange should be at start of measure"); - else - time_.set_meter(b_i, o_i); - - *default_grouping = Rhythmic_grouping( - MInterval(0,Moment(b_i, o_i)), b_i); - } - } - - // then do the rest - for (int i=0; i < ptr()->timing_req_l_arr_.size(); i++) { - Timing_req * tr_l = ptr()->timing_req_l_arr_[i]; - if (tr_l->partial()) { - Moment m = tr_l->partial()->duration_; - String error = time_.try_set_partial_str(m); - if (error != "") { - tr_l->warning(error); - } else - time_.setpartial(m); - } else if (tr_l->barcheck() && time_.whole_in_measure_) { - tr_l ->warning( "Barcheck failed"); - } else if (tr_l->cadenza()) { - time_.set_cadenza(tr_l->cadenza()->on_b_); - } else if (tr_l->measuregrouping()) { - *default_grouping = parse_grouping( - tr_l->measuregrouping()->beat_i_arr_, - tr_l->measuregrouping()->elt_length_arr_); - } - } - time_.OK(); + ptr()->update_time(time_, default_grouping); } void -- 2.39.5