50 #ifndef VSI_CONNECTIONPOINT_HH
51 #define VSI_CONNECTIONPOINT_HH
54 #include <QGraphicsItem>
55 #include <QGraphicsLayoutItem>
56 #include <QGraphicsSceneMouseEvent>
73 class ConnectionPoint :
public QObject,
public QGraphicsEllipseItem,
public QGraphicsLayoutItem
76 Q_INTERFACES(QGraphicsLayoutItem)
87 OutputNotConnected = 5
112 void paint (QPainter *_painter,
const QStyleOptionGraphicsItem *_option, QWidget *_widget = 0);
117 void mousePressEvent (QGraphicsSceneMouseEvent *_event);
120 void hoverEnterEvent (QGraphicsSceneHoverEvent *_event);
121 void hoverLeaveEvent (QGraphicsSceneHoverEvent *_event);
124 virtual QSizeF sizeHint ( Qt::SizeHint _which,
const QSizeF & _constraint = QSizeF())
const;
~ConnectionPoint()
Destructor.
virtual void setGeometry(const QRectF &_rect)
Sets the geometry.
void setWidth(int _width)
Sets the diameter.
void setState(State _state)
sets the state
ElementInOut * inOut() const
Input/output element.
QPointF connectPos()
Position for connections.
ConnectionPoint(ElementInOut *_e, QGraphicsItem *_parent)
Constructor.
State
State of the connection point.