1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374 |
- #ifndef SCHEMEFLOWWIDGET_H
- #define SCHEMEFLOWWIDGET_H
- #include <QWidget>
- #include "SchemePlanManager.h"
- #include <shemeFlow/DataFlowModel.h>
- #include <shemeFlow/FlowGraphModel.h>
- #include <shemeFlow/DataFlowModel.h>
- #include <shemeFlow/FlowTemplateDataModel.h>
- #include <QtNodes/BasicGraphicsScene>
- #include <QtNodes/ConnectionStyle>
- #include <QtNodes/DataFlowGraphicsScene>
- // #include <QtNodes/GraphicsView>
- #include <QtNodes/GraphicsViewStyle>
- #include <QtNodes/NodeDelegateModelRegistry>
- using QtNodes::BasicGraphicsScene;
- using QtNodes::ConnectionStyle;
- using QtNodes::DataFlowGraphicsScene;
- // using QtNodes::GraphicsView;
- using QtNodes::GraphicsViewStyle;
- using QtNodes::NodeDelegateModelRegistry;
- using QtNodes::NodeRole;
- using QtNodes::NodeStyle;
- // class GraphicsView;
- class ProjectInfo;
- class QHBoxLayout;
- /**
- * @brief The SchemeFlowWidget class
- * 方案流程图
- */
- class SchemeFlowWidget : public QWidget
- {
- Q_OBJECT
- public:
- explicit SchemeFlowWidget(ProjectInfo *proj, int indexType, QWidget *parent = nullptr);
- ~SchemeFlowWidget();
- void setType(int t);
- static QList<SchemePlanManager::SchemeProcessType> schemeTemplate(int indexType);
- signals:
- private:
- void initWidget();
- void clearAllNodes();
- void refresh();
- private slots:
- void slotSchemeProcessEdited(const SchemePlanManager::SchemeProcessInfo &process);
- private:
- ProjectInfo *m_proj = nullptr;
- int m_indexType = 0;
- // GraphicsView *m_view = nullptr;
- DataFlowModel *m_graphModel = nullptr;
- QHBoxLayout *m_layout = nullptr;
- };
- #endif // SCHEMEFLOWWIDGET_H
|