]> git.donarmstrong.com Git - lilypond.git/blob - lily/include/key-item.hh
release: 1.3.34
[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
16     TODO: Schemify me.
17  */
18 class Key_item :public  Item
19 {
20   Array<int> pitch_arr_;
21   Array<int> acc_arr_;
22   Array<int> old_pitch_arr_;
23   Array<int> old_acc_arr_;
24
25 public:
26   VIRTUAL_COPY_CONS(Score_element);
27   Key_item ();
28   void add (int pitch, int acc);
29   void add_old (int pitch, int acc);
30
31   int calculate_position(int p, int a) const;
32
33 protected:
34   virtual Molecule do_brew_molecule() const;
35 };
36
37 #endif // KEYITEM_HH