]> git.donarmstrong.com Git - lilypond.git/blob - hdr/inputcommands.hh
release: 0.0.31
[lilypond.git] / hdr / inputcommands.hh
1 /*
2   inputcommands.hh -- part of LilyPond
3
4   (c) 1996,97 Han-Wen Nienhuys
5 */
6
7 #ifndef INPUTCOMMANDS_HH
8 #define INPUTCOMMANDS_HH
9
10 #include "proto.hh"
11 #include "plist.hh"
12 #include "real.hh"
13 #include "timedescription.hh"
14
15 struct Commands_at : public IPointerList<Input_command*> {
16     Time_description tdescription_;
17     
18     /* *************** */
19
20     Moment when();
21     void parse(Staff_commands_at*);
22     void print() const;
23     Moment barleft();
24     void add(Input_command*);
25     void setpartial(Moment);
26     Commands_at(const Commands_at&);
27     Commands_at(Moment, Commands_at*prev);
28 };
29
30 struct Input_cursor : public PCursor<Commands_at*>
31 {
32     /* *************** */
33     Input_cursor(PCursor<Commands_at*>);
34     Moment when()const;
35     void find_moment(Moment w);
36     void prev() { operator --(0); }
37     void next() { operator ++(0); }    
38 };
39
40 /// the list of commands in Score
41 struct Input_commands : public IPointerList<Commands_at*> {    
42     Input_cursor ptr;
43     
44     /* *************** */
45
46     void find_moment(Moment);
47     void add(Input_command c,Assoc<String,Moment> &marks_assoc_r);
48     void do_skip(int bars, Moment wholes);
49         
50     Input_commands();
51     Input_commands(Input_commands const&);
52
53     void reset();
54     void print()const;
55     void parse(Staff *) const;
56 };
57
58 #endif // INPUTCOMMANDS_HH
59