Vuo  0.3
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
Public Member Functions | Protected Member Functions | List of all members
VuoRendererCable Class Reference

Description

Renders a cable in a VuoRendererGraph.

Public Member Functions

 VuoRendererCable (VuoCable *baseCable)
 Creates a renderer detail for the specified baseCable.
 
QRectF boundingRect (void) const
 Returns a rectangle containing the rendered cable (including thick cable width).
 
QPainterPath shape (void) const
 Returns the shape of the rendered cable, for use in collision detection, hit tests, and QGraphicsScene::items() functions.
 
void paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
 Draws the cable on painter.
 
void setPenToHighlightSelection (QPen *pen)
 Customizes the pen to function as a highlighter to indicate that the cable is currently selected.
 
void setPenToHighlightDisconnectionPotential (QPen *pen)
 Customizes the pen to function as a highlighter to indicate that the cable would be disconnected if dragged from the cursor's current location.
 
void setFloatingEndpointLoc (QPointF loc)
 Sets the coordinates of the cable's floating endpoint.
 
void removeFromScene ()
 Removes a cable from the canvas and performs other necessary cleanup.
 
void highlightEligiblePorts (void)
 Highlights all ports eligible to be connected to the unattached end of this cable.
 
void extendedHoverEnterEvent (QPointF scenePos)
 Handle mouse hover start events generated by custom code making use of an extended hover range.
 
void extendedHoverMoveEvent (QPointF scenePos)
 Handle mouse hover move events generated by custom code making use of an extended hover range.
 
void extendedHoverLeaveEvent (QPointF scenePos)
 Handle mouse hover leave events generated by custom code making use of an extended hover range.
 
VuoPortgetFloatingEndpointPreviousToPort ()
 Returns the cable's previous 'To' port (if the cable has since been disconnected from that port by dragging), or NULL if not applicable.
 
void setFloatingEndpointPreviousToPort (VuoPort *port)
 Sets the cable's previous 'To' port (if the cable has since been disconnected from that port by dragging), or NULL if not applicable.
 
void setEligibleForDisconnection (bool eligible)
 Sets the boolean indicating that the cable would be disconnected if dragged from the cursor's current location.
 
void updateGeometry (void)
 Schedules a redraw of this cable.
 
- Public Member Functions inherited from VuoBaseDetail< VuoCable >
 VuoBaseDetail (string id, VuoCable *base)
 Creates a VuoCable detail class.
 
VuoCablegetBase (void) const
 Returns the VuoCable detail class instance's base class instance.
 
void setBase (VuoCable *base)
 Sets the VuoCable detail class instance's base class instance.
 

Protected Member Functions

void mousePressEvent (QGraphicsSceneMouseEvent *event)
 Re-implements QGraphicsItem::mousePressEvent(QGraphicsSceneMouseEvent *event) to address bug https://bugreports.qt-project.org/browse/QTBUG-3306, which causes non-movable graphics items to be deselected upon right-click.
 
- Protected Member Functions inherited from VuoRendererItem
void drawBoundingRect (QPainter *painter)
 Draws this item's bounding rect, for debugging.
 

Additional Inherited Members

- Static Public Member Functions inherited from VuoRendererItem
static void setDrawBoundingRects (bool drawBoundingRects)
 Specifies whether bounding rects will be shown the next time the QGraphicsScene is rendered.
 

The documentation for this class was generated from the following files: