]> git.donarmstrong.com Git - lilypond.git/blob - hdr/voice.hh
release: 0.0.30
[lilypond.git] / hdr / voice.hh
1 #ifndef VOICE_HH
2 #define VOICE_HH
3
4 #include "proto.hh"
5 #include "plist.hh"
6 #include "moment.hh"
7
8 /// class for  horizontal stuff.
9 /**
10
11     Voice is a ordered row of Voice_elements. It is strictly horizontal:
12     you cannot have two rhythmic elements running parallel in a Voice
13
14     */
15
16 struct Voice {
17     IPointerList<Voice_element *> elts;
18     Moment start;
19
20     /* *************** */
21     Moment when(const Voice_element*)const;
22     Moment last() const;
23     Voice();
24     Voice(Voice const&);
25     void add(Voice_element*);
26     void print() const;
27     void set_default_group(String id);
28 };
29 /// one horizontal bit. 
30 /** Apart from being a container for the requests, Voice_element is nothing
31     */
32 struct Voice_element {
33     Moment duration;
34     char const* defined_ch_c_l_m;
35     const Voice *voice_l_;
36     IPointerList<Request*> reqs;
37
38     /* *************** */
39     
40     void add(Request*);
41     Voice_element();
42     Voice_element(Voice_element const & src );
43     void print ()const;
44     void set_default_group(String id);
45 };
46 #endif