2 staff-walker.cc -- implement Staff_walker
4 source file of the GNU LilyPond music typesetter
6 (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
11 #include "grouping.hh"
13 #include "musical-request.hh"
14 #include "staff-walker.hh"
15 #include "staff-column.hh"
16 #include "score-column.hh"
18 #include "time-description.hh"
19 #include "command-request.hh"
20 #include "grouping.hh"
21 #include "score-walker.hh"
23 Staff_walker::~Staff_walker()
28 Staff_walker::Staff_walker(Staff_walker
const &s
)
29 :PCursor
<Staff_column
*> (s
)
34 Staff_walker::Staff_walker(Staff
* s
, PScore
*ps
)
35 : PCursor
<Staff_column
*> (s
->cols_
)
40 // should be in tdes. TODO
41 default_grouping
= new Rhythmic_grouping(MInterval(0, 1), 4);
46 Staff_walker::when() const
52 Staff_walker::process_timing_reqs()
54 ptr()->update_time(time_
, default_grouping
);
58 Staff_walker::operator++(int i
)
63 PCursor
<Staff_column
*>::operator++(i
);
65 Moment delta_t
= when() - last
;
66 assert(delta_t
>Moment(0));
73 Staff_walker::process()
75 process_timing_reqs();
80 Staff_walker::allow_break()
82 score_walk_l_
->allow_break(this);