38 lines
1.1 KiB
C
38 lines
1.1 KiB
C
|
#pragma once
|
|||
|
#include <QtWidgets/QWidget>
|
|||
|
#include <QtWidgets/QGraphicsView>
|
|||
|
#include <QGenericPlugin>
|
|||
|
|
|||
|
class XNonDetectionWidget : public QGraphicsView
|
|||
|
{
|
|||
|
Q_OBJECT
|
|||
|
public:
|
|||
|
XNonDetectionWidget(QWidget* parent = nullptr) : QGraphicsView(parent) {}
|
|||
|
~XNonDetectionWidget() {}
|
|||
|
|
|||
|
signals:
|
|||
|
// 发送画图完毕信号
|
|||
|
void sendNonDetectionDrawingFinished();
|
|||
|
|
|||
|
public slots:
|
|||
|
|
|||
|
// 接收料号信息
|
|||
|
virtual void getInformationForNonDetection(QString dataset, QString jobName, QString layerName) = 0;
|
|||
|
// 选择画图方式0: global, 1: copy
|
|||
|
virtual void getNonDetectionCopyMode(int mode) = 0;
|
|||
|
// 选择画图形状0: none, 1: rect, 2: polygon
|
|||
|
virtual void getNonDetectionShapeMode(int mode) = 0;
|
|||
|
// 设置Z轴
|
|||
|
virtual void getZValueForNonDetection(qreal z) = 0;
|
|||
|
// 0: global, 1: copy
|
|||
|
// 默认颜色:global = QColor(0, 0, 255, 255); copy QColor(0, 255, 0, 255);
|
|||
|
virtual void getColorForNonDetectionItem(QColor color, int mode) = 0;
|
|||
|
// 保存到本地
|
|||
|
virtual void saveNonDetection2File() = 0;
|
|||
|
|
|||
|
};
|
|||
|
|
|||
|
QT_BEGIN_NAMESPACE
|
|||
|
Q_DECLARE_INTERFACE(XNonDetectionWidget, QGenericPluginFactoryInterface_iid)
|
|||
|
QT_END_NAMESPACE
|