]> git.donarmstrong.com Git - lilypond.git/blob - src/complexstaff.cc
3ecf9fdb89d26324bba5d38a3de531932fd17add
[lilypond.git] / src / complexstaff.cc
1 #include "debug.hh"
2 #include "complexstaff.hh"
3 #include "complexwalker.hh"
4 #include "complexcolumn.hh"
5 #include "score.hh"
6 #include "pscore.hh"
7 #include "staffsym.hh"
8 #include "pscore.hh"
9 #include "bar.hh"
10 #include "meter.hh"
11 #include "sccol.hh"
12 #include "commandrequest.hh"
13
14 const NO_LINES = 5;
15
16 /** Aside from putting fields right, this generates the staff symbol.
17  */
18 void
19 Complex_staff::set_output(PScore* pscore_l )
20 {
21     pstaff_l_ = new PStaff(pscore_l);
22     pscore_l_ = pscore_l;
23     pscore_l_->add(pstaff_l_);
24
25
26    
27     Staff_symbol *span_p = new Staff_symbol(5);
28
29     
30     Score_column* col_last
31         =score_l_->find_col(score_l_->last(), false);
32     Score_column* col_first=
33         score_l_->find_col(0, false);
34         
35     span_p->set_extent(col_first->pcol_l_->postbreak_p_,
36                        col_last->pcol_l_->prebreak_p_);
37
38     pscore_l_->typeset_spanner(span_p, pstaff_l_);
39 }
40
41 Complex_staff::Complex_staff()
42 {
43     pstaff_l_ = 0;
44 }
45
46 Staff_column*
47 Complex_staff::create_col()
48 {
49     return new Complex_column(this);
50 }
51
52 Staff_walker * 
53 Complex_staff::get_walker_p()
54 {
55     return new Complex_walker(this);
56 }