feat: add node edges

This commit is contained in:
parker
2025-06-20 23:12:09 +01:00
parent cf876320d8
commit 20c6ad2b64
10 changed files with 211 additions and 28 deletions

View File

@@ -1,5 +1,6 @@
#include "gui/network/Network.h"
#include "gui/network/NetworkGraphicsView.h"
#include "gui/network/NodeEdgeGraphic.h"
#include "gui/network/NetworkGraphicsScene.h"
#include "gui/network/NodeGraphic.h"
#include <qboxlayout.h>
@@ -33,5 +34,15 @@ Network::Network(QWidget* parent)
NodeGraphic* node1 = new NodeGraphic();
scene->addItem(node1);
NodeGraphic* node2 = new NodeGraphic();
scene->addItem(node2);
NodeEdgeGraphic* edge1 = new NodeEdgeGraphic(node1->getOutput(0), node2->getInput(0));
scene->addItem(edge1);
node1->addEdge(edge1);
node2->addEdge(edge1);
mainLayout_->addWidget(view);
}