/media/hdb5/canorusNightlyBuildSystem/trunk/src/core/mark.h

Go to the documentation of this file.
00001 
00008 #ifndef MARK_H_
00009 #define MARK_H_
00010 
00011 #include "core/muselement.h"
00012 
00013 class CAMark : public CAMusElement {
00014 public:
00015         enum CAMarkType {
00016                 Undefined = -1,
00017                 Text,
00018                 Tempo,
00019                 Ritardando,
00020                 Dynamic,
00021                 Crescendo,
00022                 Pedal,
00023                 InstrumentChange,
00024                 BookMark,
00025                 RehersalMark,
00026                 Fermata,
00027                 RepeatMark,
00028                 Articulation,
00029                 Fingering
00030         };
00031         
00032         CAMark( CAMarkType type, CAMusElement *associatedElt, int timeStart=-1, int timeLength=-1 );
00033         CAMark( CAMarkType type, CAContext *context, int timeStart, int timeLength );
00034         virtual ~CAMark();
00035         
00036         virtual CAMusElement *clone();
00037         virtual int compare( CAMusElement* elt );
00038         
00039         inline CAMusElement *associatedElement() { return _associatedElt; }
00040         inline void setAssociatedElement( CAMusElement* elt ) { _associatedElt = elt; }
00041         
00042         inline CAMarkType markType() { return _markType; }
00043         inline void setMarkType( CAMarkType type ) { _markType = type; }
00044         
00045         inline bool isCommon() { return _common; }
00046         
00047         static const QString markTypeToString( CAMarkType t );
00048         static CAMarkType markTypeFromString( const QString s );
00049         
00050 protected:
00051         inline void setCommon( bool c ) { _common=c; }
00052         
00053 private:
00054         CAMusElement *_associatedElt;
00055         CAMarkType    _markType;
00056         bool          _common;        // is mark assigned to a single element only or the whole chord - depends who deletes it!
00057 };
00058 
00059 #endif /* MARK_H_ */

Generated on Sat Feb 9 13:06:25 2008 for Canorus by  doxygen 1.5.3