Canorus 0.0
rest.h
Go to the documentation of this file.
1
8#ifndef REST_H_
9#define REST_H_
10
11#include "score/playable.h"
12
13class CAStaff;
14
15class CARest : public CAPlayable {
16public:
20 Hidden
21 };
22
24 ~CARest();
25
27
29 void setRestType( CARestType type ) { _restType = type; }
30
31 int compare(CAMusElement *elt);
32
33 static const QString restTypeToString(CARestType);
34 static CARestType restTypeFromString(const QString);
35 static QList<CARest*> composeRests( int timeLength, int timeStart, CAVoice* voice=0, CARestType=Hidden );
36
37private:
39};
40#endif /* REST_H_ */
An abstract class which represents every music element in the score.
Definition: muselement.h:21
virtual int timeStart() const
Definition: muselement.h:51
virtual int timeLength() const
Definition: muselement.h:53
Musical length of notes and rests.
Definition: playablelength.h:16
Playable instances of music elements.
Definition: playable.h:18
CAVoice * voice()
Definition: playable.h:31
Represents a rest in the score.
Definition: rest.h:15
CARestType restType()
Definition: rest.h:28
CARestType
Definition: rest.h:17
@ Normal
Definition: rest.h:19
@ Undefined
Definition: rest.h:18
@ Hidden
Definition: rest.h:20
void setRestType(CARestType type)
Definition: rest.h:29
static CARestType restTypeFromString(const QString)
Definition: rest.cpp:78
static QList< CARest * > composeRests(int timeLength, int timeStart, CAVoice *voice=0, CARestType=Hidden)
Definition: rest.cpp:96
CARest(CARestType type, CAPlayableLength length, CAVoice *voice, int timeStart, int timeLength=-1)
Definition: rest.cpp:25
int compare(CAMusElement *elt)
Definition: rest.cpp:48
~CARest()
Definition: rest.cpp:34
static const QString restTypeToString(CARestType)
Definition: rest.cpp:64
CARestType _restType
Definition: rest.h:38
CARest * clone(CAVoice *voice=0)
Definition: rest.cpp:37
Represents a staff in the sheet.
Definition: staff.h:25
Class which represents a voice in the staff.
Definition: voice.h:23