]> git.donarmstrong.com Git - lilypond.git/blob - lily/include/key.hh
release: 0.0.39-1
[lilypond.git] / lily / include / key.hh
1 /*
2   key.hh -- declare Key
3
4   (c) 1996,97 Han-Wen Nienhuys
5 */
6
7 #ifndef KEY_HH
8 #define KEY_HH
9
10 #include "varray.hh"
11 #include "scalar.hh"
12
13 /// administration of current key
14 class Key {
15     Array<int> accidental_i_arr_;
16
17     /* *************** */
18
19 public:
20  
21     Key();
22     void set(int i, int acc);
23     int acc(int i)const { return accidental_i_arr_[i]; }
24 };
25
26 /// administration of accidentals
27 struct Local_key
28 {
29     void reset(Key);    
30     Key& oct(int);
31     Local_key();
32
33 private:
34     Array<Key> octaves;
35 };
36
37 #endif // KEY_HH
38
39