2023-06-02 15:41:26 -04:00
|
|
|
#ifndef SINGLE_SPECTR_H
|
|
|
|
#define SINGLE_SPECTR_H
|
2023-05-17 17:40:32 -04:00
|
|
|
|
|
|
|
#include <QMainWindow>
|
|
|
|
#include <QChart>
|
|
|
|
#include <QChartView>
|
|
|
|
#include <QLabel>
|
|
|
|
#include <QPushButton>
|
|
|
|
#include <QCheckBox>
|
|
|
|
#include <QLineEdit>
|
|
|
|
#include <QGridLayout>
|
|
|
|
#include <QGroupBox>
|
|
|
|
|
|
|
|
#include "macro.h"
|
|
|
|
#include "ClassDigitizer.h"
|
|
|
|
#include "CustomThreads.h"
|
|
|
|
#include "CustomWidgets.h"
|
2023-06-02 18:13:47 -04:00
|
|
|
#include "Histogram1D.h"
|
2023-05-17 17:40:32 -04:00
|
|
|
|
|
|
|
|
|
|
|
//^====================================================
|
|
|
|
//^====================================================
|
2023-06-02 15:41:26 -04:00
|
|
|
class SingleSpectra : public QMainWindow{
|
2023-05-17 17:40:32 -04:00
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
2023-06-02 15:41:26 -04:00
|
|
|
SingleSpectra(Digitizer ** digi, unsigned int nDigi, QString rawDataPath, QMainWindow * parent = nullptr);
|
|
|
|
~SingleSpectra();
|
|
|
|
|
2023-08-16 17:54:35 -04:00
|
|
|
void ClearInternalDataCount();
|
2023-06-02 15:41:26 -04:00
|
|
|
void SetFillHistograms(bool onOff) { fillHistograms = onOff;}
|
|
|
|
bool IsFillHistograms() const {return fillHistograms;}
|
|
|
|
|
|
|
|
void LoadSetting();
|
|
|
|
void SaveSetting();
|
2023-05-17 17:40:32 -04:00
|
|
|
|
2023-05-18 17:14:24 -04:00
|
|
|
public slots:
|
2023-06-02 15:41:26 -04:00
|
|
|
void FillHistograms();
|
2023-05-19 16:23:04 -04:00
|
|
|
void ChangeHistView();
|
2023-05-17 17:40:32 -04:00
|
|
|
|
|
|
|
private:
|
|
|
|
|
|
|
|
Digitizer ** digi;
|
|
|
|
unsigned short nDigi;
|
|
|
|
|
2023-10-06 16:50:28 -04:00
|
|
|
Histogram1D * hist[MaxNDigitizer][MaxRegChannel];
|
2023-05-19 16:23:04 -04:00
|
|
|
|
|
|
|
RComboBox * cbDivision;
|
|
|
|
|
|
|
|
RComboBox * cbDigi;
|
|
|
|
RComboBox * cbCh;
|
|
|
|
|
|
|
|
QGroupBox * histBox;
|
|
|
|
QGridLayout * histLayout;
|
|
|
|
int oldBd, oldCh;
|
2023-05-17 17:40:32 -04:00
|
|
|
|
2023-10-06 16:50:28 -04:00
|
|
|
int lastFilledIndex[MaxNDigitizer][MaxRegChannel];
|
|
|
|
int loopFilledIndex[MaxNDigitizer][MaxRegChannel];
|
2023-06-01 17:51:00 -04:00
|
|
|
|
2023-06-02 15:41:26 -04:00
|
|
|
bool fillHistograms;
|
|
|
|
|
|
|
|
QString rawDataPath;
|
|
|
|
|
2023-05-17 17:40:32 -04:00
|
|
|
};
|
|
|
|
#endif
|