lilypond-0.0.3
[lilypond.git] / item.cc
blob72f447be94cb47eecca35b7070e568b563543781
1 #include "line.hh"
2 #include "symbol.hh"
3 #include "cols.hh"
5 String
6 Spanner::TeXstring() const
8 assert(right->line);
9 Real w = left->hpos - right->hpos;
10 return (*strets)(w);
13 Spanner *
14 Spanner::broken_at(const PCol *c1, const PCol *c2) const
16 Spanner *sp = new Spanner(*this);
17 sp->left = c1;
18 sp->right = c2;
19 return sp;
22 Spanner::Spanner()
24 pstaff_=0;
25 strets=0;
26 left = right = 0;
29 /****************************************************************/
30 String
31 Item::TeXstring() const
33 return output->TeXstring();
36 Interval
37 Item::width() const
39 return output->extent().x;
42 Interval
43 Item::height() const
45 return output->extent().y;
48 /****************************************************************/
50 Item::Item()
52 col = 0;
53 output = 0;
54 pstaff_ = 0;