Wiring node for circuit connections.
More...
#include <node.h>
|
| enum | { Type = UserType + 1
} |
| |
|
| | Node (GraphWidget *graphWidget) |
| | Construct node with graph widget.
|
| |
| | Node (GraphWidget *graphWidget, struct NodeInfo) |
| | Construct node from NodeInfo structure.
|
| |
|
| ~Node () |
| | Class destructor.
|
| |
| void | addWire (Wire *Wire) |
| | Add wire connection to node.
|
| |
| QList< Wire * > | Wires () const |
| | Get list of connected wires.
|
| |
|
int | type () const |
| |
| QRectF | boundingRect () const |
| | Get node bounding rectangle.
|
| |
| QPainterPath | shape () const |
| | Get node selection shape.
|
| |
| void | paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) |
| | Paint node on scene.
|
| |
| QPoint | getPortLocation (int) |
| | Get port location (always returns origin)
|
| |
| QString | getID () |
| | Get node identifier.
|
| |
|
void | show () |
| | Show node.
|
| |
|
void | hide () |
| | Hide node.
|
| |
|
| Symbol () |
| | Class constructor.
|
| |
|
| QVariant | itemChange (GraphicsItemChange change, const QVariant &value) |
| | Handle item change events.
|
| |
| void | mousePressEvent (QGraphicsSceneMouseEvent *event) |
| | Handle mouse press events.
|
| |
| void | mouseReleaseEvent (QGraphicsSceneMouseEvent *event) |
| | Handle mouse release events.
|
| |
Wiring node for circuit connections.
◆ Node() [1/2]
Construct node with graph widget.
- Parameters
-
| graphWidget | Parent graph widget |
◆ Node() [2/2]
Construct node from NodeInfo structure.
- Parameters
-
| graphWidget | Parent graph widget |
| NI | Node information structure |
◆ addWire()
| void Node::addWire |
( |
Wire * |
Wire | ) |
|
|
inlinevirtual |
Add wire connection to node.
- Parameters
-
Implements Symbol.
◆ boundingRect()
| QRectF Node::boundingRect |
( |
| ) |
const |
|
inlinevirtual |
Get node bounding rectangle.
- Returns
- Bounding rectangle for painting
Implements Symbol.
◆ getID()
Get node identifier.
- Returns
- Node ID string
◆ getPortLocation()
| QPoint Node::getPortLocation |
( |
int |
| ) |
|
|
inlinevirtual |
Get port location (always returns origin)
- Parameters
-
| port_number | Port index (unused) |
- Returns
- Port position at origin
Implements Symbol.
◆ itemChange()
| QVariant Node::itemChange |
( |
GraphicsItemChange |
change, |
|
|
const QVariant & |
value |
|
) |
| |
|
protectedvirtual |
Handle item change events.
Implements Symbol.
◆ mousePressEvent()
| void Node::mousePressEvent |
( |
QGraphicsSceneMouseEvent * |
event | ) |
|
|
inlineprotectedvirtual |
Handle mouse press events.
Implements Symbol.
◆ mouseReleaseEvent()
| void Node::mouseReleaseEvent |
( |
QGraphicsSceneMouseEvent * |
event | ) |
|
|
inlineprotectedvirtual |
Handle mouse release events.
Implements Symbol.
◆ paint()
| void Node::paint |
( |
QPainter * |
painter, |
|
|
const QStyleOptionGraphicsItem * |
option, |
|
|
QWidget * |
widget |
|
) |
| |
|
virtual |
Paint node on scene.
- Parameters
-
| painter | QPainter instance |
| option | Style options |
| widget | Target widget |
Implements Symbol.
◆ shape()
| QPainterPath Node::shape |
( |
| ) |
const |
|
virtual |
Get node selection shape.
- Returns
- Path defining selectable area
Implements Symbol.
◆ Wires()
| QList< Wire * > Node::Wires |
( |
| ) |
const |
|
inline |
Get list of connected wires.
- Returns
- List of wire pointers
The documentation for this class was generated from the following files: