#include <transitionLoop.h>
Public Types | |
enum | ELoopType { eLoop, eCLoop, eLoopVar } |
Public Member Functions | |
TransitionLoop (Editor *parent, State *state, const QString &label, int type=eLoop, bool dimmed=false, int direction=0) | |
~TransitionLoop () | |
virtual void | adjust () |
The only method where graphics changes are computed. | |
virtual int | getDirection () const |
virtual State * | getEndState () const |
virtual QString | getTypeName () const |
virtual QString | getVCCommand () const |
VauCanSon-G transition command. | |
void | paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=0) |
virtual QPainterPath | path () const |
Return path mapped to scene. | |
virtual void | setDirection (int d) |
virtual void | setLabelPosition () |
Protected Attributes | |
int | direction |
int | loopType |
Definition at line 6 of file transitionLoop.h.
Definition at line 9 of file transitionLoop.h.
TransitionLoop::TransitionLoop | ( | Editor * | parent, | |
State * | state, | |||
const QString & | label, | |||
int | type = eLoop , |
|||
bool | dimmed = false , |
|||
int | direction = 0 | |||
) |
Definition at line 12 of file transitionLoop.cpp.
References adjust(), DEF_LOOP_LAB_POS, Transition::dimEdgeLabelColor, Transition::edgeLabelColor, Transition::label, Transition::leftOriented, Transition::m_labelFontSize, LabelX::setPosParam(), Z_TR_LABEL, and Z_TRANSITION.
TransitionLoop::~TransitionLoop | ( | ) |
Definition at line 24 of file transitionLoop.cpp.
References DBGLOG.
void TransitionLoop::adjust | ( | ) | [virtual] |
The only method where graphics changes are computed.
Implements Transition.
Definition at line 29 of file transitionLoop.cpp.
References Transition::createStrokes(), direction, EAST, eCLoop, eLoop, Transition::findIntersectedPoints(), Transition::getArrowPolygon(), State::getMyPolygon(), State::getWidth(), loopType, NORTH, NORTH_EAST, NORTH_WEST, Transition::p, Transition::pa, RELLOG, setLabelPosition(), SOUTH, SOUTH_EAST, SOUTH_WEST, Transition::startPoint, Transition::startState, TR_CLOOP_OPENING_ANGLE, TR_LOOP_OPENING_ANGLE, trAngleFromDirection(), and WEST.
Referenced by setDirection(), and TransitionLoop().
int TransitionLoop::getDirection | ( | ) | const [virtual] |
Reimplemented from Transition.
Definition at line 118 of file transitionLoop.cpp.
References direction.
Referenced by getVCCommand().
virtual State* TransitionLoop::getEndState | ( | ) | const [inline, virtual] |
Reimplemented from Transition.
Definition at line 27 of file transitionLoop.h.
References Transition::startState.
QString TransitionLoop::getTypeName | ( | ) | const [virtual] |
Implements Transition.
Definition at line 101 of file transitionLoop.cpp.
QString TransitionLoop::getVCCommand | ( | ) | const [virtual] |
VauCanSon-G transition command.
Implements Transition.
Definition at line 179 of file transitionLoop.cpp.
References eCLoop, eLoop, eLoopVar, getDirection(), State::getName(), Transition::getNextLabelsVCCommand(), OneStateTransition::getTypeNameSuffix(), Transition::label, loopType, NORTH, LabelX::posParam(), SOUTH, Transition::startState, and LabelX::text().
void TransitionLoop::paint | ( | QPainter * | painter, | |
const QStyleOptionGraphicsItem * | option, | |||
QWidget * | widget = 0 | |||
) | [virtual] |
Reimplemented from Transition.
Definition at line 134 of file transitionLoop.cpp.
References Transition::boundingRect(), Transition::checked, Transition::checkedColor, Transition::dimEdgeLineColor, Transition::dimEdgeLineStyle, Transition::dimmed, Transition::edgeLineColor, Transition::edgeLineStyle, Transition::m_lineWidth, Transition::p, Transition::pa, Transition::paintSelectionDecoration(), and Transition::shape().
virtual QPainterPath TransitionLoop::path | ( | ) | const [inline, virtual] |
Return path mapped to scene.
Reimplemented from Transition.
Definition at line 29 of file transitionLoop.h.
References Transition::p.
void TransitionLoop::setDirection | ( | int | d | ) | [virtual] |
Reimplemented from Transition.
Definition at line 111 of file transitionLoop.cpp.
References adjust(), direction, and setLabelPosition().
void TransitionLoop::setLabelPosition | ( | ) | [virtual] |
Reimplemented from Transition.
Definition at line 123 of file transitionLoop.cpp.
References direction, EAST, LabelX::getHeight(), LabelX::getWidth(), Transition::label, NORTH, NORTH_EAST, and LabelX::posParam().
Referenced by adjust(), and setDirection().
int TransitionLoop::direction [protected] |
Definition at line 38 of file transitionLoop.h.
Referenced by adjust(), getDirection(), setDirection(), and setLabelPosition().
int TransitionLoop::loopType [protected] |
Definition at line 37 of file transitionLoop.h.
Referenced by adjust(), getTypeName(), and getVCCommand().