1 #include "staffline.hh"
2 #include "scoreline.hh"
14 String s("\\vbox to ");
15 s += print_dimen(i.length());
16 s += "{\\vskip "+print_dimen(i.right)+" ";
22 Line_of_staff::TeXstring() const
24 String s("%line_of_staff\n");
25 s+=make_vbox(height());
26 // the staff itself: eg lines, accolades
30 brew_molecule(line_of_score_->pscore_->paper_->linewidth);
32 s+=pstaff_->stafsym->TeXstring();
33 iter_top(line_of_score_->cols,cc);
34 Real lastpos=cc->hpos;
36 // all items in the current line & staff.
37 for (; cc.ok(); cc++) {
38 Real delta=cc->hpos - lastpos;
43 s +=String( "\\kern ") + print_dimen(delta);
45 // now output the items.
47 for (iter_top(cc->its,i); i.ok(); i++) {
48 if (i->pstaff_ == pstaff_)
52 for (iter_top(cc->starters,i); i.ok(); i++)
53 if (i->pstaff_ == pstaff_)
61 Line_of_staff::Line_of_staff(Line_of_score * sc, PStaff*st)
66 PCol *linestart = sc->cols.top();
67 PCol *linestop = sc->cols.bottom();
69 for (iter_top(pstaff_->spans,i); i.ok(); i++) {
71 PCol *brokenstart = &max(*linestart, *i->left);
72 PCol *brokenstop = &min(*linestop, *i->right);
73 if ( *brokenstart < *brokenstop) {
74 Spanner*span_p =i->broken_at(brokenstart,brokenstop);
75 line_of_score_->pscore_-> // higghl
83 Line_of_staff::height() const
85 Interval y = pstaff_->stafsym->extent().y;
86 iter_top(line_of_score_->cols,cc);
88 // all items in the current line & staff.
89 for (; cc.ok(); cc++) {
90 for (iter_top(cc->its,i); i.ok(); i++) {
91 if (i->pstaff_ == pstaff_)
96 for (iter_top(cc->starters,i); i.ok(); i++)
97 if (i->pstaff_ == pstaff_) {
106 Line_of_staff::process()
108 if (!pstaff_->stafsym)
109 pstaff_->brew_molecule(line_of_score_->pscore_->