Workspace 6.21.5
Public Types | Public Member Functions | Protected Member Functions | List of all members
ConnectionAnchor Class Reference

Workspace scene item for connection anchors.

#include <Workspace/Presentation/connectionanchor.h>

Inherits QObject, and QGraphicsPathItem.

Public Types

enum  { Type = WorkspaceScene::ConnectionAnchorT }
 

Public Member Functions

 ConnectionAnchor (WorkspaceScene &wsScene, const QUuid &id=DataExecution::OperationIdRegistry::generateId())
 
 ~ConnectionAnchor () override
 
void add (DataExecution::Connection &connection)
 
int getAngle () const
 
const QUuid & getId () const
 
WorkspaceScenegetWorkspaceScene ()
 
void remove (DataExecution::Connection &connection, bool byUser)
 
void removeAnchor ()
 
void setAngle (int angle)
 
void setDefaultZValue ()
 
int type () const override
 

Protected Member Functions

void contextMenuEvent (QGraphicsSceneContextMenuEvent *event) override
 
void hoverEnterEvent (QGraphicsSceneHoverEvent *event) override
 
QVariant itemChange (GraphicsItemChange change, const QVariant &value) override
 
void mouseDoubleClickEvent (QGraphicsSceneMouseEvent *event) override
 
void mouseMoveEvent (QGraphicsSceneMouseEvent *event) override
 
void mousePressEvent (QGraphicsSceneMouseEvent *event) override
 
void mouseReleaseEvent (QGraphicsSceneMouseEvent *event) override
 
void wheelEvent (QGraphicsSceneWheelEvent *event) override
 

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
Type 

Constructor & Destructor Documentation

◆ ConnectionAnchor()

Parameters
wsSceneThe workspace scene this connection anchor will be in.
idThe id to associate with this anchor.

◆ ~ConnectionAnchor()

~ConnectionAnchor ( )
override

Member Function Documentation

◆ add()

void add ( DataExecution::Connection connection)

This only adds the connection to this anchor's internal data. It does not attempt to update anything else nor trigger any redrawing of its own.

◆ contextMenuEvent()

void contextMenuEvent ( QGraphicsSceneContextMenuEvent *  event)
overrideprotected

◆ getAngle()

int getAngle ( ) const

◆ getId()

const QUuid & getId ( ) const

◆ getWorkspaceScene()

WorkspaceScene & getWorkspaceScene ( )

◆ hoverEnterEvent()

void hoverEnterEvent ( QGraphicsSceneHoverEvent *  event)
overrideprotected

◆ itemChange()

QVariant itemChange ( GraphicsItemChange  change,
const QVariant &  value 
)
overrideprotected

◆ mouseDoubleClickEvent()

void mouseDoubleClickEvent ( QGraphicsSceneMouseEvent *  event)
overrideprotected

◆ mouseMoveEvent()

void mouseMoveEvent ( QGraphicsSceneMouseEvent *  event)
overrideprotected

◆ mousePressEvent()

void mousePressEvent ( QGraphicsSceneMouseEvent *  event)
overrideprotected

◆ mouseReleaseEvent()

void mouseReleaseEvent ( QGraphicsSceneMouseEvent *  event)
overrideprotected

◆ remove()

void remove ( DataExecution::Connection connection,
bool  byUser 
)

This only removes the connection from this anchor's internal data. It does not attempt to update anything else nor trigger any redrawing of its own.

◆ removeAnchor()

void removeAnchor ( )

Causes the anchor to be deleted via an undoable command. It will ensure any connections using the anchor are updated via undoable commands first before the anchor is deleted.

◆ setAngle()

void setAngle ( int  angle)

◆ setDefaultZValue()

void setDefaultZValue ( )

◆ type()

int type ( ) const
inlineoverride

◆ wheelEvent()

void wheelEvent ( QGraphicsSceneWheelEvent *  event)
overrideprotected