2 p-score.hh -- declare PScore
4 source file of the LilyPond music typesetter
6 (c) 1996,1997 Han-Wen Nienhuys <hanwen@stack.nl>
19 /** all stuff which goes onto paper. notes, signs, symbols in a score can be grouped in two ways:
20 horizontally (staffwise), and vertically (columns). #PScore#
21 contains the items, the columns and the staffs.
27 /// the columns, ordered left to right
28 IPointer_list<PCol *> cols;
30 /// the idealspacings, no particular order
31 IPointer_list<Idealspacing*> suz;
33 /// the staffs ordered top to bottom
34 IPointer_list<PStaff*> staffs;
36 /// all symbols in score. No particular order.
37 IPointer_list<Item*> its;
39 /// if broken, the different lines
40 IPointer_list<Line_of_score*> lines;
42 /// crescs etc; no particular order
43 IPointer_list<Spanner *> spanners;
46 IPointer_list<Spanner*> broken_spans;
52 /// add a line to the broken stuff. Positions given in #config#
53 void set_breaking(Array<Col_hpositions> const &);
59 add the item in specified containers. If breakstatus is set
60 properly, add it to the {pre,post}break of the pcol.
62 void typeset_item(Item *item_p, PCol *pcol_l,PStaff*pstaf_l,int breakstatus=1);
65 void typeset_spanner(Spanner*, PStaff*);
67 /// add to bottom of pcols
69 void add_broken(Spanner*);
72 Array<Item*> select_items(PStaff*, PCol*);
75 @return argument as a cursor of the list
77 PCursor<PCol *> find_col(PCol const *)const;
82 /// last deed of this struct
83 void output(Tex_stream &ts);
85 /* UTILITY ROUTINES */
87 /// get the spacing between c1 and c2, create one if necessary.
88 Idealspacing* get_spacing(PCol *c1, PCol *c2);
91 void do_connect(PCol *c1, PCol *c2, Real distance_f, Real strength_f);
93 /// connect c1 and c2 and any children of c1 and c2
94 void connect(PCol* c1, PCol *c2, Real distance_f,Real strength_f= 1.0);
96 /* STANDARD ROUTINES */
100 /// before calc_breaking
103 /// calculate where the lines are to be broken, and use results
104 void calc_breaking();
106 /// after calc_breaking
109 /// delete unused columns