35 lines
919 B
C++
35 lines
919 B
C++
#ifndef EXPERTSMARTPOINTSETWIN_H
|
|
#define EXPERTSMARTPOINTSETWIN_H
|
|
|
|
#include "basewin.h"
|
|
#include <QSpinBox>
|
|
#include <QTableWidget>
|
|
|
|
class PointTable : public QTableWidget {
|
|
public:
|
|
explicit PointTable(QWidget *parent = nullptr) : QTableWidget{parent} {}
|
|
PointTable(int rows, int columns, QWidget *parent = nullptr) : QTableWidget{rows, columns, parent} {}
|
|
void setItem(int row, int column, QTableWidgetItem *item) {
|
|
if(item) item->setTextAlignment(Qt::AlignCenter);
|
|
QTableWidget::setItem(row, column, item);
|
|
}
|
|
};
|
|
struct Point {
|
|
int x;
|
|
int y;
|
|
int c{0};
|
|
};
|
|
|
|
class ExpertSmartPointSetWin : public BaseWin {
|
|
Q_OBJECT
|
|
public:
|
|
explicit ExpertSmartPointSetWin(QWidget *parent = nullptr);
|
|
|
|
QSpinBox *fdModuleWidth, *fdModuleHeight;
|
|
PointTable *table, *tableRow;
|
|
int virtualCnt = 0;
|
|
int moduleWidth{0}, moduleHeight{0};
|
|
};
|
|
|
|
#endif // EXPERTSMARTPOINTSETWIN_H
|