lilypond-0.0.77.jcn1
[lilypond.git] / src / staffsym.cc
blob631a5f3673e5c004733b6de54541ddde8c23b927
1 /*
2 staffsym.cc -- implement Staff_symbol
4 source file of the LilyPond music typesetter
6 (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
7 */
8 #include "staffsym.hh"
9 #include "lookup.hh"
10 #include "paper-def.hh"
11 #include "debug.hh"
15 Staff_symbol::Staff_symbol(int l)
17 no_lines_i_ = l;
20 void
21 Staff_symbol::do_print()const
23 mtor << "lines: " << no_lines_i_;
26 Molecule*
27 Staff_symbol::brew_molecule_p() const
29 Atom a = paper()->lookup_p_->linestaff(no_lines_i_, width().length());
30 return new Molecule(a);
33 Spanner*
34 Staff_symbol::do_break_at(PCol*p1, PCol*p2)const
36 Staff_symbol *span_p=new Staff_symbol(*this);
37 return span_p;
40 void
41 Staff_symbol::set_extent(PCol*p1, PCol*p2)
43 assert(p1&&p2);
44 left = p1;
45 right = p2;