2 musical-request.hh -- declare Musical requests
4 source file of the GNU LilyPond music typesetter
6 (c) 1997--2000 Han-Wen Nienhuys <hanwen@cs.uu.nl>
10 #ifndef MUSICALREQUESTS_HH
11 #define MUSICALREQUESTS_HH
13 #include "lily-proto.hh"
15 #include "duration.hh"
16 #include "musical-pitch.hh"
19 /** a request with a duration.
20 This request is used only used as a base class.
22 class Rhythmic_req : public virtual Request {
27 bool do_equal_b (Request const*) const;
28 void compress (Moment);
29 virtual Moment length_mom () const;
30 static int compare (Rhythmic_req const&,Rhythmic_req const&);
31 VIRTUAL_COPY_CONS(Music);
34 class Skip_req : public Rhythmic_req {
36 VIRTUAL_COPY_CONS(Music);
40 struct Tremolo_req : public Request {
41 VIRTUAL_COPY_CONS (Music);
49 a syllable or lyric is a string with rhythm.
51 class Lyric_req : public Rhythmic_req
54 VIRTUAL_COPY_CONS (Music);
58 class Articulation_req : public Script_req
61 String articulation_str_;
63 virtual bool do_equal_b (Request const*) const;
65 VIRTUAL_COPY_CONS(Music);
68 class Text_script_req : public Script_req
71 VIRTUAL_COPY_CONS (Music);
72 virtual bool do_equal_b (Request const*) const;
75 class Dynamic_script_req : public Script_req
78 VIRTUAL_COPY_CONS (Music);
81 /// request which has some kind of pitch
82 struct Melodic_req :virtual Request
86 static int compare (Melodic_req const&,Melodic_req const&);
89 /// transpose. #delta# is relative to central c.
90 virtual void transpose (Musical_pitch delta);
91 virtual bool do_equal_b (Request const*) const;
93 VIRTUAL_COPY_CONS(Music);
96 /// specify tonic of a chord
97 struct Tonic_req : public Melodic_req
99 VIRTUAL_COPY_CONS (Music);
102 /// specify inversion of a chord
103 struct Inversion_req : public Melodic_req
105 VIRTUAL_COPY_CONS (Music);
108 /// specify bass of a chord
109 struct Bass_req : public Melodic_req
111 VIRTUAL_COPY_CONS (Music);
114 /// Put a note of specified type, height, and with accidental on the staff.
115 class Note_req : public Rhythmic_req, virtual public Melodic_req {
118 /// force/supress printing of accidental.
120 /// Cautionary, i.e. parenthesized accidental.
125 bool do_equal_b (Request const*) const;
126 VIRTUAL_COPY_CONS(Music);
130 Put a rest on the staff. Why a request? It might be a good idea to not typeset the rest, if the paper is too crowded.
132 class Rest_req : public Rhythmic_req {
134 VIRTUAL_COPY_CONS(Music);
139 class Extender_req : public Request {
141 VIRTUAL_COPY_CONS(Music);
145 class Hyphen_req : public Request {
147 VIRTUAL_COPY_CONS(Music);
150 /** is anyone playing a note?
151 Used for communication between Music & Lyrics
153 class Busy_playing_req : public Request
156 VIRTUAL_COPY_CONS (Music);
162 instruct lyric context to alter typesetting (unimplemented). */
163 class Melisma_req : public Span_req
166 VIRTUAL_COPY_CONS(Music);
171 Helping req to signal start of a melisma from within a context, and
173 class Melisma_playing_req : public Request
176 VIRTUAL_COPY_CONS (Music);
179 class Arpeggio_req : public Request
182 VIRTUAL_COPY_CONS (Music);
185 #endif // MUSICALREQUESTS_HH