lilypond-0.0.5
[lilypond.git] / score.hh
blobe58f87f0581ff3db8f6103692c6564332c19df45
1 #ifndef SCORE_HH
2 #define SCORE_HH
3 #include "vray.hh"
4 #include "proto.hh"
5 #include "list.hh"
8 /// the total music def of one movement
9 struct Score {
10 /// paper_, staffs_ and commands_ form the problem definition.
11 Paperdef *paper_;
12 PointerList<Staff *> staffs_;
13 Score_commands *commands_;
15 /// "runtime" fields for setting up spacing
16 PointerList<Score_column*> cols_;
17 PScore *pscore_;
19 /****************************************************************/
21 /// construction
22 void add_staff(Staff *st);
23 void set(Paperdef*);
24 Score();
25 ~Score();
26 void add(Staff*);
27 void set(Score_commands*);
30 void OK() const;
31 Score_column *find_col(Real,bool);
32 void process();
33 void output(String fn);
34 PCursor<Score_column*> create_cols(Real);
35 void print() const;
36 Real last() const;
38 private:
39 void do_pcols();
40 void clean_cols();
41 void distribute_commands();
42 void do_connect(PCol *c1, PCol *c2, Real d);
43 void connect_nonmus(PCol* c1, PCol *c2, Real d);
44 /// add #Idealspacings# to #pscore_#
45 void calc_idealspacing();
46 /** add the score wide commands (bars, breaks) to each staff so
47 they can process (typeset) them if needed */
49 /**
52 #endif