13 *mlog << "\nProcessing ... ";
17 /// distribute commands to disciples
18 pscore_ = new PScore(paper_);
19 for (PCursor<Staff*> i(staffs_); i.ok(); i++) {
20 i->process_commands(last());
21 i->set_output(pscore_);
25 // do this after processing, staffs first have to generate PCols.
28 clean_cols(); // can't move this farther up.
36 pscore_->preprocess();
37 *mlog << "Calculating ... ";
38 pscore_->calc_breaking();
39 *mlog << "Postprocessing ... ";
40 pscore_->postprocess();
42 // TODO: calculate vertical structs?
43 // TODO: calculate mixed structs.?
51 for (PCursor<Staff * > i(staffs_); i.ok(); i++)
54 for (PCursor<Score_column*> c(cols_); c.ok(); ) {
55 if (!c->pcol_->used()) {
63 pscore_->clean_cols();
66 this sux. We should have Score_column create the appropriate PCol.
67 Unfortunately, PCols don't know about their position.
70 PCursor<Score_column*>
71 Score::create_cols(Real w)
73 Score_column* c1 = new Score_column(w);
74 Score_column* c2 = new Score_column(w);
79 PCursor<Score_column*> i(cols_);
88 cols_.bottom().add(c1);
89 cols_.bottom().add(c2);
100 PCursor<Score_column*>
101 Score::find_col(Real w,bool mus)
103 PCursor<Score_column*> i(cols_);
104 for (; i.ok(); i++) {
105 if (i->when == w && i->musical == mus)
119 PCursor<Score_column*> i(cols_);
120 for (; i.ok(); i++) {
121 pscore_->add(i->pcol_);
128 for (PCursor<Staff*> i(staffs_); i.ok(); i++) {
129 l = MAX(l, i->last());
138 for (PCursor<Staff*> i(staffs_); i.ok(); i++) {
140 assert(i->score_ == this);
144 for (PCursor<Score_column*> cc(cols_); cc.ok() && (cc+1).ok(); cc++) {
145 assert(cc->when <= (cc+1)->when);
156 for (PCursor<Staff*> i(staffs_); i.ok(); i++) {
159 for (PCursor<Score_column*> i(cols_); i.ok(); i++) {
169 Score::Score(Paperdef*p)
181 Score::output(String s)
184 if (paper_->outfile=="")
187 *mlog << "output to " << paper_->outfile << "...\n";
188 Tex_stream the_output(paper_->outfile);
189 pscore_->output(the_output);
198 staffs_.bottom().add(s);