lilypond-1.1.23
[lilypond.git] / src / register.cc
blob126507cc6b9ecbfaea032b88060490986c934b7d
1 /*
2 register.cc -- implement Request_register
4 Sourcefile of LilyPond musictypesetter
6 (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
7 */
9 #include "voice.hh"
10 #include "musicalrequest.hh"
11 #include "register.hh"
12 #include "notehead.hh"
13 #include "complex-walker.hh"
14 #include "local-key-item.hh"
15 #include "complex-staff.hh"
16 #include "registergroup.hh"
17 #include "debug.hh"
20 bool
21 Request_register::try_request(Request*)
23 return false;
26 Request_register::Request_register()
28 daddy_reg_l_ = 0;
31 void
32 Request_register::announce_element(Staff_elem_info i)
34 i.origin_reg_l_arr_.push(this);
35 daddy_reg_l_->announce_element(i);
38 void
39 Request_register::typeset_element(Staff_elem*p)
41 daddy_reg_l_->typeset_element(p);
44 Paper_def*
45 Request_register::paper()const
47 return daddy_reg_l_->paper();
50 void
51 Request_register::typeset_breakable_item(Item * pre_p , Item * nobreak_p,
52 Item * post_p)
54 daddy_reg_l_->typeset_breakable_item(pre_p, nobreak_p, post_p);
57 bool
58 Request_register::acceptable_request_b(Request*)const
60 return false;
63 bool
64 Request_register::contains_b(Request_register *reg_l)
66 return this == reg_l;
69 Staff_info
70 Request_register::get_staff_info() return inf;
72 inf = daddy_reg_l_->get_staff_info();
75 void
76 Request_register::print() const
78 #ifndef NPRINT
79 mtor << name() << " {";
80 do_print();
81 mtor << "}\n";
82 #endif
85 void
86 Request_register::do_print()const