]> git.donarmstrong.com Git - lilypond.git/blob - lily/include/key-item.hh
release: 1.3.29
[lilypond.git] / lily / include / key-item.hh
1 /*
2   key-item.hh -- part of GNU LilyPond
3
4   (c) 1996--2000 Han-Wen Nienhuys
5 */
6
7 #ifndef KEYITEM_HH
8 #define KEYITEM_HH
9
10 #include "item.hh"
11 #include "array.hh"
12
13
14 /// An item which places accidentals at the start of the line
15 class Key_item :public  Item
16 {
17   Array<int> pitch_arr_;
18   Array<int> acc_arr_;
19   Array<int> old_pitch_arr_;
20   Array<int> old_acc_arr_;
21   int c0_position_;
22
23
24 public:
25   bool multi_octave_b_;  
26
27   int get_c_position () const;
28     
29   
30   VIRTUAL_COPY_CONS(Score_element);
31
32   Key_item ();
33   void add (int pitch, int acc);
34   void add_old (int pitch, int acc);
35   void set_c_position (int);
36   int calculate_position(int p, int a) const;
37
38 protected:
39   virtual Molecule do_brew_molecule() const;
40 };
41
42 #endif // KEYITEM_HH