1 #ifndef VIEW_PROFILE_DIVIDER_H
2 #define VIEW_PROFILE_DIVIDER_H
4 #include <QGraphicsRectItem>
7 class QGraphicsLineItem;
9 class QGraphicsPolygonItem;
28 bool isLowerBoundary);
31 virtual QVariant
itemChange (GraphicsItemChange change,
const QVariant &value);
43 void slotOtherMoved(
double xSceneOther);
55 void sendSignalMoved ();
58 void updateGeometryDivider ();
59 void updateGeometryNonPaddle ();
60 void updateGeometryPaddle ();
62 QGraphicsView &m_view;
67 QGraphicsLineItem *m_divider;
68 QGraphicsRectItem *m_shadedArea;
69 QGraphicsPolygonItem *m_arrow;
72 bool m_isLowerBoundary;
74 QPointF m_startDragPos;
77 #endif // VIEW_PROFILE_DIVIDER_H
void signalMovedHigh(double xSceneOther)
Signal used when divider is dragged and m_isLowerBoundary is false.
void setX(double x, double xLow, double xHigh)
Set the position by specifying the new x coordinate.
void signalMovedLow(double xSceneOther)
Signal used when divider is dragged and m_isLowerBoundary is true.
virtual QVariant itemChange(GraphicsItemChange change, const QVariant &value)
Intercept changes so divider movement can be restricted to horizontal direction only.
Divider that can be dragged, in a dialog QGraphicsView.
virtual void mousePressEvent(QGraphicsSceneMouseEvent *event)
Save paddle position at start of click-and-drag.