]> git.donarmstrong.com Git - lilypond.git/blob - hdr/sccol.hh
release: 0.0.11
[lilypond.git] / hdr / sccol.hh
1 /*
2   sccol.hh -- part of LilyPond
3
4   (c) 1996 Han-Wen Nienhuys
5 */
6
7 #ifndef SCCOL_HH
8 #define SCCOL_HH
9 #include "pcol.hh"
10 #include "vray.hh"
11
12
13 struct Score_column {
14
15     /// indirection to column
16     PCol * pcol_;
17
18     /// length of notes/rests in this column
19     svec<Real> durations;
20     
21     Real when;
22
23     /// 
24     bool musical;
25     
26     /****************/
27     
28     Score_column(Real when);       
29     static int compare(Score_column & c1, Score_column &c2) {
30         return sgn(c1.when - c2.when);
31     }
32     void set_breakable() {
33          pcol_->set_breakable();
34     }
35     bool used();
36     void print() const;
37 };
38 /**
39
40     When typesetting hasn't started on PScore yet, the columns which
41     contain data have a rhythmical position. Score_column is the type
42     with a rhythmical time attached to it. The calculation of
43     idealspacing is done with data in these columns. (notably: the
44     #durations# field)
45
46     */
47
48 instantiate_compare(Score_column&, Score_column::compare);
49
50 #endif // SCCOL_HH
51
52
53
54