00001 #ifndef _TRANSITIONVCURVE_H_2523452656797_ 00002 #define _TRANSITIONVCURVE_H_2523452656797_ 00003 00004 #include "twoStatesTransition.h" 00005 00006 class TransitionVCurve : public TwoStatesTransition 00007 { 00008 public: 00009 TransitionVCurve(Editor *parent, State *ss, State *es, const QString &label, 00010 bool leftOriented, bool dimmed); 00011 // leftOriented only due to bug in VauCanSon 00012 virtual ~TransitionVCurve(); 00013 00014 virtual void adjust(); 00015 virtual void setLabelPosition(); 00016 00017 virtual QString getTypeName() const; 00018 00019 virtual void setArcAngle(int aa){arcangle = aa;} 00020 virtual void setArcAngleB(int aaB){arcangleB = aaB;} 00021 virtual void setNCurv(float nc){ncurv = nc;} 00022 virtual int getArcAngle() const { return arcangle; } 00023 virtual int getArcAngleB() const { return arcangleB; } 00024 virtual float getNCurv() const { return ncurv; } 00025 00026 virtual QString getVCCommand() const; 00027 virtual QString getGraphMLParams() const; 00028 //virtual QString getEPS() const; 00029 00030 protected: 00031 //void paint(QPainter * painter, const QStyleOptionGraphicsItem * option, QWidget * widget = 0); 00032 00033 private: 00034 bool radius; // if true, angle is 15 degrees, otherwise 30 degrees 00035 00036 QLineF text_v; // label vector 00037 00038 int arcangle; 00039 int arcangleB; 00040 float ncurv; 00041 00042 //float r; // radius of arc 00043 //float startAngle; 00044 //float endAngle; 00045 00046 // TODO: make possible to move with them using mouse 00047 QPointF a_point; // point for curve contruction 00048 QPointF b_point; 00049 }; 00050 00051 #endif //_TRANSITIONVCURVE_H_2523452656797_