]> git.donarmstrong.com Git - lilypond.git/blob - lily/include/score-column.hh
release: 1.0.15
[lilypond.git] / lily / include / score-column.hh
1 /*
2   score-column.hh -- declare Score_column
3
4   source file of the GNU LilyPond music typesetter
5
6   (c)  1997--1998 Han-Wen Nienhuys <hanwen@cs.uu.nl>
7 */
8
9
10 #ifndef SCORE_COLUMN_HH
11 #define SCORE_COLUMN_HH
12
13 #include "lily-proto.hh"
14 #include "array.hh"
15 #include "moment.hh"
16 #include "p-col.hh"
17
18 /**
19   Column with durational info.
20   
21   The columns which contain data have a rhythmical
22   position. Score_column is the type with a rhythmical time attached
23   to it. The calculation of idealspacing is done with data in these
24   columns. (notably: the #durations# field)
25
26   */
27
28 class Score_column : public Paper_column {
29   friend class Score;
30   friend class Score_engraver;
31
32   bool musical_b_;
33   int break_penalty_i_;
34   Moment when_;
35
36 public:
37   int break_penalty_i () { return break_penalty_i_; }
38   DECLARE_MY_RUNTIME_TYPEINFO;
39   SCORE_ELEMENT_CLONE(Score_column);
40   /// length of notes/rests in this column
41   Array<Moment> durations;
42     
43
44   Moment when() {  return when_; }
45   Score_column (Moment when);       
46   void add_duration (Moment);
47   void preprocess();
48   bool musical_b() { return musical_b_; }
49   void do_print() const;
50 };
51
52 #endif // SCORE_COLUMN_HH
53
54
55
56
57
58