graph_analysis
Public Member Functions | Protected Member Functions | Protected Attributes | Friends | List of all members
graph_analysis::gui::EdgeItemSimple Class Reference

#include <EdgeItemSimple.hpp>

Inheritance diagram for graph_analysis::gui::EdgeItemSimple:
Inheritance graph
[legend]
Collaboration diagram for graph_analysis::gui::EdgeItemSimple:
Collaboration graph
[legend]

Public Member Functions

 EdgeItemSimple (GraphWidget *graphWidget, const graph_analysis::Edge::Ptr &edge, QGraphicsItem *parent)
 
virtual ~EdgeItemSimple ()
 
virtual int type () const
 
void adjustEdgePositioning ()
 
- Public Member Functions inherited from graph_analysis::gui::EdgeItemBase
 EdgeItemBase (GraphWidget *graphWidget, const graph_analysis::Edge::Ptr &edge, QGraphicsItem *parent)
 constructor More...
 
virtual ~EdgeItemBase ()
 
virtual void adjustEdgePoints (QVector< QPointF > points)
 
void drawStraightEdge ()
 
void drawBezierEdge ()
 
void drawArrowHead (size_t arrowSize, QBrush brush=QBrush(Qt::black), QPen pen=QPen(Qt::black))
 
graph_analysis::Edge::Ptr getEdge () const
 
void setEdge (graph_analysis::Edge::Ptr edge)
 
GraphWidget * getGraphWidget () const
 
QGraphicsPathItem * getEdgePath () const
 
QGraphicsPolygonItem * getArrowHead () const
 

Protected Member Functions

 EdgeItemSimple ()
 
void paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=0)
 
QRectF boundingRect () const
 
QPainterPath shape () const
 
void hoverEnterEvent (QGraphicsSceneHoverEvent *event)
 
void hoverLeaveEvent (QGraphicsSceneHoverEvent *event)
 
EdgeItemBase * createNewItem (GraphWidget *graphWidget, const graph_analysis::Edge::Ptr &edge, QGraphicsItem *parent) const
 
- Protected Member Functions inherited from graph_analysis::gui::EdgeItemBase
 EdgeItemBase ()
 

Protected Attributes

QGraphicsTextItem * mpLabel
 
QGraphicsTextItem * mpClassName
 
int mArrowSize
 
- Protected Attributes inherited from graph_analysis::gui::EdgeItemBase
graph_analysis::Edge::Ptr mpEdge
 underlying graph edge pointer More...
 
GraphWidget * mpGraphWidget
 parent managing graph widget More...
 
QGraphicsPathItem * mpEdgePath
 
QGraphicsPolygonItem * mpArrowHead
 render an arrow head More...
 

Friends

class EdgeItemTypeManager
 

Additional Inherited Members

- Public Attributes inherited from graph_analysis::gui::EdgeItemBase
QVector< QPointF > mPoints
 

Detailed Description

simplest possible implementation of EdgeItemBase: just a line from source to target

Constructor & Destructor Documentation

◆ EdgeItemSimple() [1/2]

graph_analysis::gui::EdgeItemSimple::EdgeItemSimple ( )
protected

◆ EdgeItemSimple() [2/2]

graph_analysis::gui::EdgeItemSimple::EdgeItemSimple ( GraphWidget *  graphWidget,
const graph_analysis::Edge::Ptr &  edge,
QGraphicsItem *  parent 
)

◆ ~EdgeItemSimple()

graph_analysis::gui::EdgeItemSimple::~EdgeItemSimple ( )
virtual

Member Function Documentation

◆ adjustEdgePositioning()

void graph_analysis::gui::EdgeItemSimple::adjustEdgePositioning ( )
virtual

Reimplemented from graph_analysis::gui::EdgeItemBase.

◆ boundingRect()

QRectF graph_analysis::gui::EdgeItemSimple::boundingRect ( ) const
protected

◆ createNewItem()

EdgeItemBase * graph_analysis::gui::EdgeItemSimple::createNewItem ( GraphWidget *  graphWidget,
const graph_analysis::Edge::Ptr &  edge,
QGraphicsItem *  parent 
) const
protectedvirtual

◆ hoverEnterEvent()

void graph_analysis::gui::EdgeItemSimple::hoverEnterEvent ( QGraphicsSceneHoverEvent *  event)
protectedvirtual

provide mouse-over status updates of the currently selected Edge

Reimplemented from graph_analysis::gui::EdgeItemBase.

◆ hoverLeaveEvent()

void graph_analysis::gui::EdgeItemSimple::hoverLeaveEvent ( QGraphicsSceneHoverEvent *  event)
protectedvirtual

Reimplemented from graph_analysis::gui::EdgeItemBase.

◆ paint()

void graph_analysis::gui::EdgeItemSimple::paint ( QPainter *  painter,
const QStyleOptionGraphicsItem *  option,
QWidget *  widget = 0 
)
protected

◆ shape()

QPainterPath graph_analysis::gui::EdgeItemSimple::shape ( ) const
protectedvirtual

Compute the shape of the edge (based on the edge path and the arrowhead)

Reimplemented from graph_analysis::gui::EdgeItemBase.

◆ type()

int graph_analysis::gui::EdgeItemSimple::type ( ) const
virtual

Reimplemented from graph_analysis::gui::EdgeItemBase.

Friends And Related Function Documentation

◆ EdgeItemTypeManager

friend class EdgeItemTypeManager
friend

Member Data Documentation

◆ mArrowSize

int graph_analysis::gui::EdgeItemSimple::mArrowSize
protected

◆ mpClassName

QGraphicsTextItem* graph_analysis::gui::EdgeItemSimple::mpClassName
protected

◆ mpLabel

QGraphicsTextItem* graph_analysis::gui::EdgeItemSimple::mpLabel
protected

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