]> git.donarmstrong.com Git - lilypond.git/blob - lily/include/event.hh
f282eb941896ee89583206417bbfdce5d8f29c68
[lilypond.git] / lily / include / event.hh
1 /*
2   event.hh -- declare Event baseclasses.
3
4   source file of the GNU LilyPond music typesetter
5
6   (c) 1997--2004 Han-Wen Nienhuys <hanwen@cs.uu.nl>
7 */
8
9 #ifndef EVENT_HH
10 #define EVENT_HH
11
12
13 #include "input.hh"
14 #include "music.hh"
15 #include "duration.hh"
16 #include "pitch.hh"
17
18 /* An atom of musical information.  This is an abstract class for any
19   piece of music that does not contain other Music.  */
20 class Event : public Music
21 {
22 public:
23   Event (SCM);
24   VIRTUAL_COPY_CONSTRUCTOR (Music, Event);
25   virtual void compress (Moment);
26   DECLARE_SCHEME_CALLBACK(length_callback,(SCM));
27   virtual Pitch to_relative_octave (Pitch);
28 };
29
30
31 /**
32     Handle key changes.
33 */
34 class Key_change_ev  : public Event
35 {
36 public:
37   Key_change_ev (SCM);
38   SCM pitch_alist ();
39   
40 protected:
41   VIRTUAL_COPY_CONSTRUCTOR (Music, Key_change_ev);
42   void transpose (Pitch  d);
43 };
44
45 SCM ly_transpose_key_alist (SCM,SCM);
46
47
48
49 #endif