mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-16 06:47:14 +02:00
WIP
This commit is contained in:
@ -1,55 +1,28 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
class SlsQtH1D;
|
class SlsQtH1D;
|
||||||
#include "SlsQt1DPlot.h"
|
class SlsQt1DPlot;
|
||||||
#include "SlsQt2DPlotLayout.h"
|
class SlsQt2DPlotLayout;
|
||||||
|
|
||||||
#include <QAction>
|
|
||||||
#include <QCheckBox>
|
|
||||||
#include <QCloseEvent>
|
|
||||||
#include <QComboBox>
|
|
||||||
#include <QGridLayout>
|
|
||||||
#include <QGroupBox>
|
|
||||||
#include <QHBoxLayout>
|
|
||||||
#include <QLabel>
|
|
||||||
#include <QLineEdit>
|
|
||||||
#include <QMainWindow>
|
|
||||||
#include <QMenu>
|
|
||||||
#include <QMenuBar>
|
|
||||||
#include <QPushButton>
|
|
||||||
#include <QSpacerItem>
|
|
||||||
#include <QString>
|
#include <QString>
|
||||||
#include <QWidget>
|
#include <QMainWindow>
|
||||||
|
class QwtSymbol;
|
||||||
|
class QGridLayout;
|
||||||
|
class QGroupBox;
|
||||||
|
class QLabel;
|
||||||
|
class QCloseEvent;
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
/**
|
|
||||||
*@short Sets up the clone plot widget
|
|
||||||
*/
|
|
||||||
class qCloneWidget : public QMainWindow {
|
class qCloneWidget : public QMainWindow {
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
/**
|
|
||||||
* The constructor
|
|
||||||
*/
|
|
||||||
qCloneWidget(QWidget *parent, int id, QString title, QString xTitle, QString yTitle, QString zTitle, int numDim, std::string FilePath,
|
qCloneWidget(QWidget *parent, int id, QString title, QString xTitle, QString yTitle, QString zTitle, int numDim, std::string FilePath,
|
||||||
bool displayStats, QString min, QString max, QString sum);
|
bool displayStats, QString min, QString max, QString sum);
|
||||||
|
|
||||||
/**
|
|
||||||
* Destructor
|
|
||||||
*/
|
|
||||||
~qCloneWidget();
|
~qCloneWidget();
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets up the widget window
|
|
||||||
* @param title title of the image with frame number
|
|
||||||
* @param xTitle title of x axis
|
|
||||||
* @param yTitle title of y axis
|
|
||||||
* @param zTitle title of z axis
|
|
||||||
* @param numDim 1D or 2D
|
|
||||||
* */
|
|
||||||
void SetupWidgetWindow(QString title, QString xTitle, QString yTitle, QString zTitle, int numDim);
|
void SetupWidgetWindow(QString title, QString xTitle, QString yTitle, QString zTitle, int numDim);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -95,53 +68,35 @@ class qCloneWidget : public QMainWindow {
|
|||||||
*/
|
*/
|
||||||
void SetRange(bool IsXYRange[], double XYRangeValues[]);
|
void SetRange(bool IsXYRange[], double XYRangeValues[]);
|
||||||
|
|
||||||
/**
|
|
||||||
* Returns the 1d plot
|
|
||||||
*/
|
|
||||||
SlsQt1DPlot *Get1dPlot();
|
SlsQt1DPlot *Get1dPlot();
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
/**
|
|
||||||
* Save Plots automatically by save all clones
|
|
||||||
* returns -1 if fail
|
|
||||||
*/
|
|
||||||
int SavePlotAutomatic();
|
int SavePlotAutomatic();
|
||||||
|
|
||||||
private:
|
|
||||||
/** Gets the current time stamp for the window title*/
|
|
||||||
char *GetCurrentTimeStamp();
|
|
||||||
|
|
||||||
/** Display Statistics */
|
|
||||||
void DisplayStats(bool enable, QString min, QString max, QString sum);
|
|
||||||
|
|
||||||
/** clone window id*/
|
|
||||||
int id;
|
|
||||||
/** Default Save file path */
|
|
||||||
std::string filePath;
|
|
||||||
/** clone 1D Plot */
|
|
||||||
SlsQt1DPlot *cloneplot1D;
|
|
||||||
/** clone 2D Plot */
|
|
||||||
SlsQt2DPlotLayout *cloneplot2D;
|
|
||||||
/** vector of 1D hist values */
|
|
||||||
QVector<SlsQtH1D *> cloneplot1D_hists;
|
|
||||||
|
|
||||||
/** markers for the plot*/
|
|
||||||
QwtSymbol *marker;
|
|
||||||
QwtSymbol *nomarker;
|
|
||||||
|
|
||||||
QGridLayout *mainLayout;
|
|
||||||
QGroupBox *cloneBox;
|
|
||||||
|
|
||||||
QLabel *lblHistTitle;
|
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
/** Save Plot */
|
|
||||||
void SavePlot();
|
void SavePlot();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void closeEvent(QCloseEvent *event);
|
void closeEvent(QCloseEvent *event);
|
||||||
|
|
||||||
|
private:
|
||||||
|
char *GetCurrentTimeStamp();
|
||||||
|
void DisplayStats(bool enable, QString min, QString max, QString sum);
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void CloneClosedSignal(int);
|
void CloneClosedSignal(int);
|
||||||
|
|
||||||
|
private:
|
||||||
|
int id;
|
||||||
|
std::string filePath;
|
||||||
|
SlsQt1DPlot *cloneplot1D;
|
||||||
|
SlsQt2DPlotLayout *cloneplot2D;
|
||||||
|
QVector<SlsQtH1D *> cloneplot1D_hists;
|
||||||
|
|
||||||
|
QwtSymbol *marker;
|
||||||
|
QwtSymbol *nomarker;
|
||||||
|
QGridLayout *mainLayout;
|
||||||
|
QGroupBox *cloneBox;
|
||||||
|
QLabel *lblHistTitle;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -1,10 +1,11 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "qDefs.h"
|
|
||||||
#include "qDrawPlot.h"
|
|
||||||
#include "qTabDataOutput.h"
|
|
||||||
#include "qTabMeasurement.h"
|
|
||||||
#include "ui_form_detectormain.h"
|
#include "ui_form_detectormain.h"
|
||||||
|
|
||||||
|
#include "qDefs.h"
|
||||||
|
class qDrawPlot;
|
||||||
|
class qTabMeasurement;
|
||||||
|
class qTabDataOutput;
|
||||||
class qTabPlot;
|
class qTabPlot;
|
||||||
class qTabAdvanced;
|
class qTabAdvanced;
|
||||||
class qTabSettings;
|
class qTabSettings;
|
||||||
@ -15,12 +16,8 @@ class qServer;
|
|||||||
|
|
||||||
class multiSlsDetector;
|
class multiSlsDetector;
|
||||||
|
|
||||||
#include <QGridLayout>
|
|
||||||
#include <QResizeEvent>
|
|
||||||
#include <QScrollArea>
|
|
||||||
#include <QTabWidget>
|
#include <QTabWidget>
|
||||||
|
class QResizeEvent;
|
||||||
#include <iostream>
|
|
||||||
|
|
||||||
/** To Over-ride the QTabWidget class to get the tabBar */
|
/** To Over-ride the QTabWidget class to get the tabBar */
|
||||||
class MyTabWidget : public QTabWidget {
|
class MyTabWidget : public QTabWidget {
|
||||||
@ -30,27 +27,12 @@ class MyTabWidget : public QTabWidget {
|
|||||||
QTabBar *tabBar() { return QTabWidget::tabBar(); }
|
QTabBar *tabBar() { return QTabWidget::tabBar(); }
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
|
||||||
*@short Main window of the GUI.
|
|
||||||
*/
|
|
||||||
class qDetectorMain : public QMainWindow, private Ui::DetectorMainObject {
|
class qDetectorMain : public QMainWindow, private Ui::DetectorMainObject {
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
/**
|
|
||||||
* Main Window constructor.
|
|
||||||
* This is mainly used to create detector object and all the tabs
|
|
||||||
* @param argc number of command line arguments for server options
|
|
||||||
* @param argv server options
|
|
||||||
* @param app the qapplication3
|
|
||||||
* @param parent makes the parent window 0 by default
|
|
||||||
*/
|
|
||||||
qDetectorMain(int argc, char **argv, QApplication *app,
|
qDetectorMain(int argc, char **argv, QApplication *app,
|
||||||
QWidget *parent = 0);
|
QWidget *parent = 0);
|
||||||
|
|
||||||
/**
|
|
||||||
* Destructor
|
|
||||||
*/
|
|
||||||
~qDetectorMain();
|
~qDetectorMain();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -59,37 +41,13 @@ class qDetectorMain : public QMainWindow, private Ui::DetectorMainObject {
|
|||||||
* @returns success or fail
|
* @returns success or fail
|
||||||
*/
|
*/
|
||||||
int StartStopAcquisitionFromClient(bool start);
|
int StartStopAcquisitionFromClient(bool start);
|
||||||
|
|
||||||
/**
|
|
||||||
* Returns if plot is running
|
|
||||||
*/
|
|
||||||
bool isPlotRunning();
|
bool isPlotRunning();
|
||||||
|
|
||||||
/**
|
|
||||||
* Returns progress bar value
|
|
||||||
*/
|
|
||||||
int GetProgress();
|
int GetProgress();
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
/**
|
|
||||||
* Enables modes as selected -Debug, Expert, Dockable: calls setdockablemode
|
|
||||||
*/
|
|
||||||
void EnableModes(QAction *action);
|
void EnableModes(QAction *action);
|
||||||
|
|
||||||
/**
|
|
||||||
* Executes actions in the utilities menu as selected
|
|
||||||
*/
|
|
||||||
void ExecuteUtilities(QAction *action);
|
void ExecuteUtilities(QAction *action);
|
||||||
|
|
||||||
/**
|
|
||||||
* Executes actions in the utilities menu as selected
|
|
||||||
*/
|
|
||||||
void ExecuteHelp(QAction *action);
|
void ExecuteHelp(QAction *action);
|
||||||
|
|
||||||
/**
|
|
||||||
* Refreshes the tab each time the tab is changed. Also displays the next
|
|
||||||
* enabled tab
|
|
||||||
*/
|
|
||||||
void Refresh(int index);
|
void Refresh(int index);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -97,51 +55,17 @@ class qDetectorMain : public QMainWindow, private Ui::DetectorMainObject {
|
|||||||
* @param b bool TRUE if undocked(outside main window), FALSE docked
|
* @param b bool TRUE if undocked(outside main window), FALSE docked
|
||||||
*/
|
*/
|
||||||
void ResizeMainWindow(bool b);
|
void ResizeMainWindow(bool b);
|
||||||
|
|
||||||
/**
|
|
||||||
* Enables/disables tabs depending on if acquisition is currently in
|
|
||||||
* progress
|
|
||||||
*/
|
|
||||||
void EnableTabs();
|
void EnableTabs();
|
||||||
|
|
||||||
/**
|
|
||||||
* Set the tool tip of mouse controlled zooming depening on if its
|
|
||||||
* enabled/disabled
|
|
||||||
*/
|
|
||||||
void SetZoomToolTip(bool disable);
|
void SetZoomToolTip(bool disable);
|
||||||
|
|
||||||
/**
|
|
||||||
* Uncheck the Listen to gui client mode when the server has exited
|
|
||||||
*/
|
|
||||||
void UncheckServer();
|
void UncheckServer();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
/**
|
|
||||||
* Adjust the resizing to resize plot
|
|
||||||
*/
|
|
||||||
void resizeEvent(QResizeEvent *event);
|
void resizeEvent(QResizeEvent *event);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/**
|
|
||||||
* Sets up the layout of the widget
|
|
||||||
*/
|
|
||||||
void SetUpWidgetWindow();
|
void SetUpWidgetWindow();
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets up detector
|
|
||||||
* @param fName file name of the config file at start up
|
|
||||||
* @param multi detector ID
|
|
||||||
*/
|
|
||||||
void SetUpDetector(const std::string fName, int multiID);
|
void SetUpDetector(const std::string fName, int multiID);
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets up the signals and the slots
|
|
||||||
*/
|
|
||||||
void Initialization();
|
void Initialization();
|
||||||
|
|
||||||
/**
|
|
||||||
* Loads config file at start up
|
|
||||||
*/
|
|
||||||
void LoadConfigFile(const std::string fName);
|
void LoadConfigFile(const std::string fName);
|
||||||
|
|
||||||
/** enumeration of the tabs */
|
/** enumeration of the tabs */
|
||||||
@ -156,40 +80,22 @@ class qDetectorMain : public QMainWindow, private Ui::DetectorMainObject {
|
|||||||
MESSAGES,
|
MESSAGES,
|
||||||
NumberOfTabs
|
NumberOfTabs
|
||||||
};
|
};
|
||||||
/** Detector Type */
|
|
||||||
slsDetectorDefs::detectorType detType;
|
slsDetectorDefs::detectorType detType;
|
||||||
/** The sls detector object */
|
|
||||||
multiSlsDetector* myDet;
|
multiSlsDetector* myDet;
|
||||||
/** The Plot widget */
|
|
||||||
qDrawPlot* myPlot;
|
qDrawPlot* myPlot;
|
||||||
/**Tab Widget */
|
|
||||||
MyTabWidget* tabs;
|
MyTabWidget* tabs;
|
||||||
/**Measurement tab */
|
|
||||||
qTabMeasurement* tabMeasurement;
|
qTabMeasurement* tabMeasurement;
|
||||||
/**DataOutput tab */
|
|
||||||
qTabDataOutput* tabDataOutput;
|
qTabDataOutput* tabDataOutput;
|
||||||
/**Plot tab */
|
|
||||||
qTabPlot* tabPlot;
|
qTabPlot* tabPlot;
|
||||||
/**Settings tab */
|
|
||||||
qTabSettings* tabSettings;
|
qTabSettings* tabSettings;
|
||||||
/**Advanced tab */
|
|
||||||
qTabAdvanced* tabAdvanced;
|
qTabAdvanced* tabAdvanced;
|
||||||
/**Debugging tab */
|
|
||||||
qTabDebugging* tabDebugging;
|
qTabDebugging* tabDebugging;
|
||||||
/**Developer tab */
|
|
||||||
qTabDeveloper* tabDeveloper;
|
qTabDeveloper* tabDeveloper;
|
||||||
/**Messages tab */
|
|
||||||
qTabMessages* tabMessages;
|
qTabMessages* tabMessages;
|
||||||
/** server object*/
|
|
||||||
qServer* myServer;
|
qServer* myServer;
|
||||||
/**if the developer tab should be enabled,known from command line */
|
|
||||||
int isDeveloper;
|
int isDeveloper;
|
||||||
/** default height of Plot Window when docked */
|
|
||||||
int heightPlotWindow;
|
int heightPlotWindow;
|
||||||
/** default height of central widgetwhen plot Window when docked */
|
|
||||||
int heightCentralWidget;
|
int heightCentralWidget;
|
||||||
/** The default zooming tool tip */
|
|
||||||
QString zoomToolTip;
|
QString zoomToolTip;
|
||||||
/** The default tab heading color */
|
|
||||||
QColor defaultTabColor;
|
QColor defaultTabColor;
|
||||||
};
|
};
|
||||||
|
@ -27,6 +27,11 @@ class qServer : public QWidget {
|
|||||||
void Acquire(sls::ServerInterface2* socket);
|
void Acquire(sls::ServerInterface2* socket);
|
||||||
void ExitServer(sls::ServerInterface2* socket);
|
void ExitServer(sls::ServerInterface2* socket);
|
||||||
|
|
||||||
|
signals:
|
||||||
|
// to update the Listening to Gui check box
|
||||||
|
void ServerStoppedSignal();
|
||||||
|
|
||||||
|
private:
|
||||||
void (qServer::*flist[qDefs::QF_NUM_FUNCTIONS])(sls::ServerInterface2 &socket);
|
void (qServer::*flist[qDefs::QF_NUM_FUNCTIONS])(sls::ServerInterface2 &socket);
|
||||||
qDetectorMain *mainTab;
|
qDetectorMain *mainTab;
|
||||||
bool tcpThreadCreated{false};
|
bool tcpThreadCreated{false};
|
||||||
@ -38,7 +43,5 @@ class qServer : public QWidget {
|
|||||||
std::unique_ptr<sls::ServerSocket> controlSocket{nullptr};
|
std::unique_ptr<sls::ServerSocket> controlSocket{nullptr};
|
||||||
std::unique_ptr<sls::ServerSocket> stopSocket{nullptr};
|
std::unique_ptr<sls::ServerSocket> stopSocket{nullptr};
|
||||||
|
|
||||||
signals:
|
|
||||||
// to update the Listening to Gui check box
|
|
||||||
void ServerStoppedSignal();
|
|
||||||
};
|
};
|
||||||
|
@ -64,6 +64,13 @@ private:
|
|||||||
void Enable(bool enable);
|
void Enable(bool enable);
|
||||||
int VerifyOutputDirectoryError();
|
int VerifyOutputDirectoryError();
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void StartSignal();
|
||||||
|
void StopSignal();
|
||||||
|
void CheckPlotIntervalSignal();
|
||||||
|
|
||||||
|
|
||||||
|
private:
|
||||||
multiSlsDetector *myDet;
|
multiSlsDetector *myDet;
|
||||||
qDrawPlot *myPlot;
|
qDrawPlot *myPlot;
|
||||||
// enum for the timing mode
|
// enum for the timing mode
|
||||||
@ -81,9 +88,4 @@ private:
|
|||||||
QPalette red;
|
QPalette red;
|
||||||
bool delayImplemented;
|
bool delayImplemented;
|
||||||
bool sampleImplemented;
|
bool sampleImplemented;
|
||||||
|
|
||||||
signals:
|
|
||||||
void StartSignal();
|
|
||||||
void StopSignal();
|
|
||||||
void CheckPlotIntervalSignal();
|
|
||||||
};
|
};
|
||||||
|
@ -1,64 +1,70 @@
|
|||||||
/*
|
#pragma once
|
||||||
* qTabPlot.h
|
|
||||||
*
|
|
||||||
* Created on: May 10, 2012
|
|
||||||
* Author: l_maliakal_d
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef QTABPLOT_H_
|
|
||||||
#define QTABPLOT_H_
|
|
||||||
|
|
||||||
#include "qDefs.h"
|
|
||||||
|
|
||||||
|
|
||||||
/** Form Header */
|
|
||||||
#include "ui_form_tab_plot.h"
|
#include "ui_form_tab_plot.h"
|
||||||
/** Project Class Headers */
|
|
||||||
class multiSlsDetector;
|
|
||||||
/** Qt Project Class Headers */
|
|
||||||
class qDrawPlot;
|
class qDrawPlot;
|
||||||
/** Qt Include Headers */
|
|
||||||
#include <QStackedLayout>
|
|
||||||
#include <QButtonGroup>
|
|
||||||
#include <QAbstractButton>
|
|
||||||
|
|
||||||
|
class multiSlsDetector;
|
||||||
|
|
||||||
|
class QStackedLayout;
|
||||||
|
class QSpinBox;
|
||||||
|
class QDoubleSpinBox;
|
||||||
|
class QComboBox;
|
||||||
|
class QButtonGroup;
|
||||||
|
class QPalette;
|
||||||
|
|
||||||
/**
|
|
||||||
*@short sets up the Plot parameters
|
|
||||||
*/
|
|
||||||
class qTabPlot:public QWidget, private Ui::TabPlotObject{
|
class qTabPlot:public QWidget, private Ui::TabPlotObject{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
/** \short The constructor
|
|
||||||
* @param parent is the parent tab widget
|
|
||||||
* @param detector is the detector returned from the detector tab
|
|
||||||
* @param plot plot object reference
|
|
||||||
*/
|
|
||||||
qTabPlot(QWidget *parent,multiSlsDetector* detector, qDrawPlot* plot);
|
qTabPlot(QWidget *parent,multiSlsDetector* detector, qDrawPlot* plot);
|
||||||
|
|
||||||
/** Destructor
|
|
||||||
*/
|
|
||||||
~qTabPlot();
|
~qTabPlot();
|
||||||
|
|
||||||
/** Sets the scan argument of the plot
|
|
||||||
*/
|
|
||||||
void SetScanArgument();
|
void SetScanArgument();
|
||||||
|
|
||||||
/** To refresh and update widgets
|
|
||||||
*/
|
|
||||||
void Refresh();
|
void Refresh();
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void SetFrequency();
|
||||||
|
void EnableScanBox();
|
||||||
|
|
||||||
|
private slots:
|
||||||
|
void Select1DPlot(bool b);
|
||||||
|
|
||||||
|
/**Enables Persistency depending on Superimpose checkbox */
|
||||||
|
void EnablePersistency(bool enable);
|
||||||
|
void SetTitles();
|
||||||
|
void EnableTitles();
|
||||||
|
void checkAspectRatio();
|
||||||
|
|
||||||
|
/** maintain aspect ratio
|
||||||
|
* @param axis axis to be changed: 0 for x(y axis values changed), 1 for y (xaxis values changes), -1 for the larger one (aspect ratio checked)
|
||||||
|
*/
|
||||||
|
void maintainAspectRatio(int axis);
|
||||||
|
void EnableXRange();
|
||||||
|
void EnableYRange();
|
||||||
|
void EnableRange();
|
||||||
|
void SetXAxisRange();
|
||||||
|
void SetYAxisRange();
|
||||||
|
void SetAxesRange();
|
||||||
|
void SetZRange();
|
||||||
|
void EnableZRange();
|
||||||
|
bool CheckZRange(QString value);
|
||||||
|
void SetPlot();
|
||||||
|
void SetPlotOptionsRightPage();
|
||||||
|
void SetPlotOptionsLeftPage();
|
||||||
|
void SetBinary();
|
||||||
|
void SetHistogramOptions();
|
||||||
|
void EnableGapPixels(bool enable);
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void DisableZoomSignal(bool);
|
||||||
|
void ResetZMinZMaxSignal(bool,bool,double,double);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/** The sls detector object */
|
void SetupWidgetWindow();
|
||||||
|
void Initialization();
|
||||||
|
|
||||||
multiSlsDetector *myDet;
|
multiSlsDetector *myDet;
|
||||||
|
|
||||||
/** The Plot widget */
|
|
||||||
qDrawPlot *myPlot;
|
qDrawPlot *myPlot;
|
||||||
|
|
||||||
|
|
||||||
/** 1d/2d plot */
|
|
||||||
bool isOneD;
|
bool isOneD;
|
||||||
bool isOriginallyOneD;
|
bool isOriginallyOneD;
|
||||||
|
|
||||||
@ -72,6 +78,8 @@ private:
|
|||||||
QButtonGroup *btnGroupScan;
|
QButtonGroup *btnGroupScan;
|
||||||
QButtonGroup *btnGroupPlotType;
|
QButtonGroup *btnGroupPlotType;
|
||||||
QButtonGroup *btnGroupHistogram;
|
QButtonGroup *btnGroupHistogram;
|
||||||
|
QPalette *red;
|
||||||
|
QString intervalTip;
|
||||||
|
|
||||||
/** some Default Values */
|
/** some Default Values */
|
||||||
static QString defaultPlotTitle;
|
static QString defaultPlotTitle;
|
||||||
@ -84,105 +92,6 @@ private:
|
|||||||
/** scans */
|
/** scans */
|
||||||
static const QString modeNames[5];
|
static const QString modeNames[5];
|
||||||
|
|
||||||
/** error palette*/
|
|
||||||
QPalette *red;
|
|
||||||
QString intervalTip;
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/** Sets up the widget
|
|
||||||
*/
|
|
||||||
void SetupWidgetWindow();
|
|
||||||
|
|
||||||
/** Sets up all the slots and signals
|
|
||||||
*/
|
|
||||||
void Initialization();
|
|
||||||
|
|
||||||
|
|
||||||
public slots:
|
|
||||||
/** Set frequency between plots*/
|
|
||||||
void SetFrequency();
|
|
||||||
|
|
||||||
/** Enable Scan box
|
|
||||||
*/
|
|
||||||
void EnableScanBox();
|
|
||||||
|
|
||||||
|
|
||||||
private slots:
|
|
||||||
/** Selects the plot to display, enables/disables widgets
|
|
||||||
* @param b true to select plot dimension 1, else false to select 2D
|
|
||||||
*/
|
|
||||||
void Select1DPlot(bool b);
|
|
||||||
|
|
||||||
/**Enables Persistency depending on Superimpose checkbox */
|
|
||||||
void EnablePersistency(bool enable);
|
|
||||||
|
|
||||||
/**Sets the titles in plot axis */
|
|
||||||
void SetTitles();
|
|
||||||
|
|
||||||
/** Enables/Sets default Titles to default */
|
|
||||||
void EnableTitles();
|
|
||||||
|
|
||||||
/** check aspect ratio */
|
|
||||||
void checkAspectRatio();
|
|
||||||
|
|
||||||
/** maintain aspect ratio
|
|
||||||
* @param axis axis to be changed: 0 for x(y axis values changed), 1 for y (xaxis values changes), -1 for the larger one (aspect ratio checked)
|
|
||||||
*/
|
|
||||||
void maintainAspectRatio(int axis);
|
|
||||||
|
|
||||||
/** Enables range of the X axis */
|
|
||||||
void EnableXRange();
|
|
||||||
|
|
||||||
/** Enables range of the Y axis */
|
|
||||||
void EnableYRange();
|
|
||||||
|
|
||||||
/** Enables range of all axes, called by EnableXRange and EnableYRange */
|
|
||||||
void EnableRange();
|
|
||||||
|
|
||||||
/** Sets the range of the x axis */
|
|
||||||
void SetXAxisRange();
|
|
||||||
|
|
||||||
/** Sets the range of the y axis */
|
|
||||||
void SetYAxisRange();
|
|
||||||
|
|
||||||
/** Sets the range of both axes, called by SetXAxisRange and SetYAxisRange */
|
|
||||||
void SetAxesRange();
|
|
||||||
|
|
||||||
/** Sets the range of the z axis */
|
|
||||||
void SetZRange();
|
|
||||||
|
|
||||||
/** Enables the range of the z axis */
|
|
||||||
void EnableZRange();
|
|
||||||
|
|
||||||
/** Return true if valid */
|
|
||||||
bool CheckZRange(QString value);
|
|
||||||
|
|
||||||
/** Set Plot to none, data graph, histogram*/
|
|
||||||
void SetPlot();
|
|
||||||
|
|
||||||
/** Change pages in plot options box to the right*/
|
|
||||||
void SetPlotOptionsRightPage();
|
|
||||||
|
|
||||||
/** Change pages in plot options box to the left*/
|
|
||||||
void SetPlotOptionsLeftPage();
|
|
||||||
|
|
||||||
/** Plot binary plot */
|
|
||||||
void SetBinary();
|
|
||||||
|
|
||||||
/** Set histogram options */
|
|
||||||
void SetHistogramOptions();
|
|
||||||
|
|
||||||
/** Enable Gap pixels */
|
|
||||||
void EnableGapPixels(bool enable);
|
|
||||||
|
|
||||||
signals:
|
|
||||||
void DisableZoomSignal(bool);
|
|
||||||
void ResetZMinZMaxSignal(bool,bool,double,double);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#endif /* QTABPLOT_H_ */
|
|
||||||
|
@ -1,7 +1,23 @@
|
|||||||
#include "qCloneWidget.h"
|
#include "qCloneWidget.h"
|
||||||
#include "qDefs.h"
|
#include "qDefs.h"
|
||||||
|
#include "SlsQt1DPlot.h"
|
||||||
|
#include "SlsQt2DPlotLayout.h"
|
||||||
|
|
||||||
#include "qwt_symbol.h"
|
#include "qwt_symbol.h"
|
||||||
|
#include <QWidget>
|
||||||
|
#include <QCloseEvent>
|
||||||
|
#include <QGridLayout>
|
||||||
|
#include <QGroupBox>
|
||||||
|
#include <QLabel>
|
||||||
|
#include <QAction>
|
||||||
|
#include <QCheckBox>
|
||||||
|
#include <QComboBox>
|
||||||
|
#include <QHBoxLayout>
|
||||||
|
#include <QLineEdit>
|
||||||
|
#include <QMenu>
|
||||||
|
#include <QMenuBar>
|
||||||
|
#include <QPushButton>
|
||||||
|
#include <QSpacerItem>
|
||||||
#include <QFileDialog>
|
#include <QFileDialog>
|
||||||
#include <QImage>
|
#include <QImage>
|
||||||
#include <QPainter>
|
#include <QPainter>
|
||||||
@ -24,7 +40,6 @@ qCloneWidget::qCloneWidget(QWidget *parent, int id, QString title, QString xTitl
|
|||||||
DisplayStats(displayStats, min, max, sum);
|
DisplayStats(displayStats, min, max, sum);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
qCloneWidget::~qCloneWidget() {
|
qCloneWidget::~qCloneWidget() {
|
||||||
delete cloneplot1D;
|
delete cloneplot1D;
|
||||||
delete cloneplot2D;
|
delete cloneplot2D;
|
||||||
@ -32,12 +47,10 @@ qCloneWidget::~qCloneWidget() {
|
|||||||
cloneplot1D_hists.clear();
|
cloneplot1D_hists.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
SlsQt1DPlot* qCloneWidget::Get1dPlot() {
|
SlsQt1DPlot* qCloneWidget::Get1dPlot() {
|
||||||
return cloneplot1D;
|
return cloneplot1D;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void qCloneWidget::SetupWidgetWindow(QString title, QString xTitle, QString yTitle, QString zTitle, int numDim) {
|
void qCloneWidget::SetupWidgetWindow(QString title, QString xTitle, QString yTitle, QString zTitle, int numDim) {
|
||||||
|
|
||||||
QMenuBar* menubar = new QMenuBar(this);
|
QMenuBar* menubar = new QMenuBar(this);
|
||||||
@ -97,7 +110,6 @@ void qCloneWidget::SetupWidgetWindow(QString title, QString xTitle, QString yTit
|
|||||||
resize(500, 350);
|
resize(500, 350);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void qCloneWidget::SetCloneHists(int nHists, int histNBins, double *histXAxis, double *histYAxis[], std::string histTitle[], bool lines, bool markers) {
|
void qCloneWidget::SetCloneHists(int nHists, int histNBins, double *histXAxis, double *histYAxis[], std::string histTitle[], bool lines, bool markers) {
|
||||||
//for each plot, create hists
|
//for each plot, create hists
|
||||||
for (int hist_num = 0; hist_num < nHists; ++hist_num) {
|
for (int hist_num = 0; hist_num < nHists; ++hist_num) {
|
||||||
@ -134,7 +146,6 @@ void qCloneWidget::SetCloneHists(int nHists, int histNBins, double *histXAxis, d
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void qCloneWidget::SetCloneHists(int nHists, int histNBins, double *histXAxis, double *histYAxis, std::string histTitle[], bool lines, bool markers) {
|
void qCloneWidget::SetCloneHists(int nHists, int histNBins, double *histXAxis, double *histYAxis, std::string histTitle[], bool lines, bool markers) {
|
||||||
// for each plot create hists
|
// for each plot create hists
|
||||||
for (int hist_num = 0; hist_num < nHists; ++hist_num) {
|
for (int hist_num = 0; hist_num < nHists; ++hist_num) {
|
||||||
@ -174,13 +185,11 @@ void qCloneWidget::SetCloneHists(int nHists, int histNBins, double *histXAxis, d
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void qCloneWidget::SetCloneHists2D(int nbinsx, double xmin, double xmax, int nbinsy, double ymin, double ymax, double *d) {
|
void qCloneWidget::SetCloneHists2D(int nbinsx, double xmin, double xmax, int nbinsy, double ymin, double ymax, double *d) {
|
||||||
cloneplot2D->GetPlot()->SetData(nbinsx, xmin, xmax, nbinsy, ymin, ymax, d);
|
cloneplot2D->GetPlot()->SetData(nbinsx, xmin, xmax, nbinsy, ymin, ymax, d);
|
||||||
cloneplot2D->UpdateNKeepSetRangeIfSet();
|
cloneplot2D->UpdateNKeepSetRangeIfSet();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void qCloneWidget::SetRange(bool IsXYRange[], double XYRangeValues[]) {
|
void qCloneWidget::SetRange(bool IsXYRange[], double XYRangeValues[]) {
|
||||||
double XYCloneRangeValues[4];
|
double XYCloneRangeValues[4];
|
||||||
|
|
||||||
@ -226,7 +235,6 @@ void qCloneWidget::SetRange(bool IsXYRange[], double XYRangeValues[]) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void qCloneWidget::SavePlot() {
|
void qCloneWidget::SavePlot() {
|
||||||
char cID[10];
|
char cID[10];
|
||||||
sprintf(cID, "%d", id);
|
sprintf(cID, "%d", id);
|
||||||
@ -257,7 +265,6 @@ void qCloneWidget::SavePlot() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
int qCloneWidget::SavePlotAutomatic() {
|
int qCloneWidget::SavePlotAutomatic() {
|
||||||
char cID[10];
|
char cID[10];
|
||||||
sprintf(cID, "%d", id);
|
sprintf(cID, "%d", id);
|
||||||
@ -280,13 +287,11 @@ int qCloneWidget::SavePlotAutomatic() {
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void qCloneWidget::closeEvent(QCloseEvent *event) {
|
void qCloneWidget::closeEvent(QCloseEvent *event) {
|
||||||
emit CloneClosedSignal(id);
|
emit CloneClosedSignal(id);
|
||||||
event->accept();
|
event->accept();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
char *qCloneWidget::GetCurrentTimeStamp() {
|
char *qCloneWidget::GetCurrentTimeStamp() {
|
||||||
char output[30];
|
char output[30];
|
||||||
char *result;
|
char *result;
|
||||||
@ -300,7 +305,6 @@ char *qCloneWidget::GetCurrentTimeStamp() {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void qCloneWidget::DisplayStats(bool enable, QString min, QString max, QString sum) {
|
void qCloneWidget::DisplayStats(bool enable, QString min, QString max, QString sum) {
|
||||||
if (enable) {
|
if (enable) {
|
||||||
QWidget *widgetStatistics = new QWidget(this);
|
QWidget *widgetStatistics = new QWidget(this);
|
||||||
|
@ -1,22 +1,26 @@
|
|||||||
#include "qDetectorMain.h"
|
#include "qDetectorMain.h"
|
||||||
#include "qDefs.h"
|
#include "qDefs.h"
|
||||||
#include "qServer.h"
|
#include "qDrawPlot.h"
|
||||||
#include "qTabAdvanced.h"
|
#include "qTabMeasurement.h"
|
||||||
#include "qTabDataOutput.h"
|
#include "qTabDataOutput.h"
|
||||||
|
#include "qTabPlot.h"
|
||||||
|
#include "qTabAdvanced.h"
|
||||||
|
#include "qTabSettings.h"
|
||||||
#include "qTabDebugging.h"
|
#include "qTabDebugging.h"
|
||||||
#include "qTabDeveloper.h"
|
#include "qTabDeveloper.h"
|
||||||
#include "qTabMessages.h"
|
#include "qTabMessages.h"
|
||||||
#include "qTabPlot.h"
|
#include "qServer.h"
|
||||||
#include "qTabSettings.h"
|
|
||||||
|
|
||||||
#include "multiSlsDetector.h"
|
|
||||||
#include "sls_detector_defs.h"
|
|
||||||
#include "versionAPI.h"
|
#include "versionAPI.h"
|
||||||
|
|
||||||
|
#include <QGridLayout>
|
||||||
|
#include <QResizeEvent>
|
||||||
|
#include <QScrollArea>
|
||||||
#include <QFileDialog>
|
#include <QFileDialog>
|
||||||
#include <QPlastiqueStyle>
|
#include <QPlastiqueStyle>
|
||||||
#include <QSizePolicy>
|
#include <QSizePolicy>
|
||||||
|
|
||||||
|
#include <iostream>
|
||||||
#include <getopt.h>
|
#include <getopt.h>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <string>
|
#include <string>
|
||||||
@ -111,7 +115,6 @@ qDetectorMain::qDetectorMain(int argc, char **argv, QApplication *app,
|
|||||||
setupUi(this);
|
setupUi(this);
|
||||||
SetUpDetector(fname, multiId);
|
SetUpDetector(fname, multiId);
|
||||||
SetUpWidgetWindow();
|
SetUpWidgetWindow();
|
||||||
Initialization();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
qDetectorMain::~qDetectorMain() {
|
qDetectorMain::~qDetectorMain() {
|
||||||
@ -277,6 +280,8 @@ void qDetectorMain::SetUpDetector(const std::string fName, int multiID) {
|
|||||||
//FIXME: not needed anymore due to client creating socket each time
|
//FIXME: not needed anymore due to client creating socket each time
|
||||||
//myDet->setOnline(slsDetectorDefs::ONLINE_FLAG);
|
//myDet->setOnline(slsDetectorDefs::ONLINE_FLAG);
|
||||||
//myDet->setReceiverOnline(slsDetectorDefs::ONLINE_FLAG);
|
//myDet->setReceiverOnline(slsDetectorDefs::ONLINE_FLAG);
|
||||||
|
|
||||||
|
Initialization();
|
||||||
}
|
}
|
||||||
|
|
||||||
void qDetectorMain::Initialization() {
|
void qDetectorMain::Initialization() {
|
||||||
|
@ -1,17 +1,17 @@
|
|||||||
#include "qTabPlot.h"
|
#include "qTabPlot.h"
|
||||||
|
#include "qDefs.h"
|
||||||
#include "qDrawPlot.h"
|
#include "qDrawPlot.h"
|
||||||
// Project Class Headers
|
|
||||||
#include "multiSlsDetector.h"
|
|
||||||
// Qt Include Headers
|
|
||||||
#include <QStandardItemModel>
|
#include <QStandardItemModel>
|
||||||
// C++ Include Headers
|
#include <QStackedLayout>
|
||||||
|
#include <QButtonGroup>
|
||||||
|
#include <QAbstractButton>
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
// const QString qTabPlot::modeNames[5] = {"None", "Energy Scan", "Threshold Scan", "Trimbits Scan", "Custom Script Scan"};
|
|
||||||
|
|
||||||
QString qTabPlot::defaultPlotTitle("");
|
QString qTabPlot::defaultPlotTitle("");
|
||||||
QString qTabPlot::defaultHistXAxisTitle("Channel Number");
|
QString qTabPlot::defaultHistXAxisTitle("Channel Number");
|
||||||
@ -20,7 +20,6 @@ QString qTabPlot::defaultImageXAxisTitle("Pixel");
|
|||||||
QString qTabPlot::defaultImageYAxisTitle("Pixel");
|
QString qTabPlot::defaultImageYAxisTitle("Pixel");
|
||||||
QString qTabPlot::defaultImageZAxisTitle("Intensity");
|
QString qTabPlot::defaultImageZAxisTitle("Intensity");
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
qTabPlot::qTabPlot(QWidget *parent, multiSlsDetector *detector, qDrawPlot *plot) : QWidget(parent),
|
qTabPlot::qTabPlot(QWidget *parent, multiSlsDetector *detector, qDrawPlot *plot) : QWidget(parent),
|
||||||
myDet(detector),
|
myDet(detector),
|
||||||
@ -41,15 +40,12 @@ qTabPlot::qTabPlot(QWidget *parent, multiSlsDetector *detector, qDrawPlot *plot)
|
|||||||
FILE_LOG(logDEBUG) << "Plot ready";
|
FILE_LOG(logDEBUG) << "Plot ready";
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
qTabPlot::~qTabPlot() {
|
qTabPlot::~qTabPlot() {
|
||||||
delete myDet;
|
delete myDet;
|
||||||
delete myPlot;
|
delete myPlot;
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetupWidgetWindow() {
|
void qTabPlot::SetupWidgetWindow() {
|
||||||
//error for interval between plots
|
//error for interval between plots
|
||||||
red = new QPalette();
|
red = new QPalette();
|
||||||
@ -181,7 +177,6 @@ void qTabPlot::SetupWidgetWindow() {
|
|||||||
qDefs::checkErrorMessage(myDet, "qTabPlot::SetupWidgetWindow");
|
qDefs::checkErrorMessage(myDet, "qTabPlot::SetupWidgetWindow");
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetPlotOptionsRightPage() {
|
void qTabPlot::SetPlotOptionsRightPage() {
|
||||||
if (isOneD) {
|
if (isOneD) {
|
||||||
@ -201,8 +196,6 @@ void qTabPlot::SetPlotOptionsRightPage() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetPlotOptionsLeftPage() {
|
void qTabPlot::SetPlotOptionsLeftPage() {
|
||||||
if (isOneD) {
|
if (isOneD) {
|
||||||
int i = stackedWidget->currentIndex();
|
int i = stackedWidget->currentIndex();
|
||||||
@ -221,8 +214,6 @@ void qTabPlot::SetPlotOptionsLeftPage() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::Select1DPlot(bool b) {
|
void qTabPlot::Select1DPlot(bool b) {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
if (b)
|
if (b)
|
||||||
@ -256,8 +247,6 @@ void qTabPlot::Select1DPlot(bool b) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::Initialization() {
|
void qTabPlot::Initialization() {
|
||||||
// Plot arguments box
|
// Plot arguments box
|
||||||
connect(btnGroupPlotType, SIGNAL(buttonClicked(int)), this, SLOT(SetPlot()));
|
connect(btnGroupPlotType, SIGNAL(buttonClicked(int)), this, SLOT(SetPlot()));
|
||||||
@ -349,8 +338,6 @@ void qTabPlot::Initialization() {
|
|||||||
connect(chkGapPixels, SIGNAL(toggled(bool)), this, SLOT(EnableGapPixels(bool)));
|
connect(chkGapPixels, SIGNAL(toggled(bool)), this, SLOT(EnableGapPixels(bool)));
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::EnablePersistency(bool enable) {
|
void qTabPlot::EnablePersistency(bool enable) {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
if (enable)
|
if (enable)
|
||||||
@ -366,8 +353,6 @@ void qTabPlot::EnablePersistency(bool enable) {
|
|||||||
myPlot->SetPersistency(0);
|
myPlot->SetPersistency(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetTitles() {
|
void qTabPlot::SetTitles() {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
cout << "Setting Plot Titles" << endl;
|
cout << "Setting Plot Titles" << endl;
|
||||||
@ -394,8 +379,6 @@ void qTabPlot::SetTitles() {
|
|||||||
myPlot->SetImageZAxisTitle(dispZAxis->text());
|
myPlot->SetImageZAxisTitle(dispZAxis->text());
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::EnableTitles() {
|
void qTabPlot::EnableTitles() {
|
||||||
// Plot Title
|
// Plot Title
|
||||||
dispTitle->setEnabled(chkTitle->isChecked());
|
dispTitle->setEnabled(chkTitle->isChecked());
|
||||||
@ -433,15 +416,12 @@ void qTabPlot::EnableTitles() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::checkAspectRatio() {
|
void qTabPlot::checkAspectRatio() {
|
||||||
if (chkAspectRatio->isChecked()) {
|
if (chkAspectRatio->isChecked()) {
|
||||||
maintainAspectRatio(-1);
|
maintainAspectRatio(-1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::maintainAspectRatio(int axis) {
|
void qTabPlot::maintainAspectRatio(int axis) {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
@ -581,8 +561,6 @@ void qTabPlot::maintainAspectRatio(int axis) {
|
|||||||
myPlot->SetXYRange(true);
|
myPlot->SetXYRange(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::EnableXRange() {
|
void qTabPlot::EnableXRange() {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
cout << "Enable X Axis Range" << endl;
|
cout << "Enable X Axis Range" << endl;
|
||||||
@ -620,8 +598,6 @@ void qTabPlot::EnableXRange() {
|
|||||||
EnableRange();
|
EnableRange();
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::EnableYRange() {
|
void qTabPlot::EnableYRange() {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
cout << "Enable Y Axis Range" << endl;
|
cout << "Enable Y Axis Range" << endl;
|
||||||
@ -659,8 +635,6 @@ void qTabPlot::EnableYRange() {
|
|||||||
EnableRange();
|
EnableRange();
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::EnableRange() {
|
void qTabPlot::EnableRange() {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
cout << "Enable Axes Range" << endl;
|
cout << "Enable Axes Range" << endl;
|
||||||
@ -673,8 +647,6 @@ void qTabPlot::EnableRange() {
|
|||||||
SetAxesRange();
|
SetAxesRange();
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetXAxisRange() {
|
void qTabPlot::SetXAxisRange() {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
cout << "Setting X Axis Range" << endl;
|
cout << "Setting X Axis Range" << endl;
|
||||||
@ -705,8 +677,6 @@ void qTabPlot::SetXAxisRange() {
|
|||||||
SetAxesRange();
|
SetAxesRange();
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetYAxisRange() {
|
void qTabPlot::SetYAxisRange() {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
cout << "Setting Y Axis Range" << endl;
|
cout << "Setting Y Axis Range" << endl;
|
||||||
@ -737,8 +707,6 @@ void qTabPlot::SetYAxisRange() {
|
|||||||
SetAxesRange();
|
SetAxesRange();
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetAxesRange() {
|
void qTabPlot::SetAxesRange() {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
cout << "Setting Axes Range" << endl;
|
cout << "Setting Axes Range" << endl;
|
||||||
@ -773,7 +741,6 @@ void qTabPlot::SetAxesRange() {
|
|||||||
myPlot->SetXYRange(true);
|
myPlot->SetXYRange(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetZRange() {
|
void qTabPlot::SetZRange() {
|
||||||
emit ResetZMinZMaxSignal(
|
emit ResetZMinZMaxSignal(
|
||||||
@ -783,7 +750,6 @@ void qTabPlot::SetZRange() {
|
|||||||
dispZMax->text().toDouble());
|
dispZMax->text().toDouble());
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::EnableZRange() {
|
void qTabPlot::EnableZRange() {
|
||||||
|
|
||||||
@ -802,7 +768,6 @@ void qTabPlot::EnableZRange() {
|
|||||||
connect(dispZMax, SIGNAL(editingFinished()), this, SLOT(SetZRange()));
|
connect(dispZMax, SIGNAL(editingFinished()), this, SLOT(SetZRange()));
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
bool qTabPlot::CheckZRange(QString value) {
|
bool qTabPlot::CheckZRange(QString value) {
|
||||||
if (value.isEmpty())
|
if (value.isEmpty())
|
||||||
@ -820,7 +785,6 @@ bool qTabPlot::CheckZRange(QString value) {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetPlot() {
|
void qTabPlot::SetPlot() {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
@ -890,7 +854,6 @@ void qTabPlot::SetPlot() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetFrequency() {
|
void qTabPlot::SetFrequency() {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
@ -1029,8 +992,6 @@ void qTabPlot::SetFrequency() {
|
|||||||
qDefs::checkErrorMessage(myDet, "qTabPlot::SetFrequency");
|
qDefs::checkErrorMessage(myDet, "qTabPlot::SetFrequency");
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::EnableScanBox(){
|
void qTabPlot::EnableScanBox(){
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
cout << "Entering Enable Scan Box"<< endl;
|
cout << "Entering Enable Scan Box"<< endl;
|
||||||
@ -1218,7 +1179,6 @@ void qTabPlot::SetFrequency() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetScanArgument(){
|
void qTabPlot::SetScanArgument(){
|
||||||
#ifdef VERYVERBOSE
|
#ifdef VERYVERBOSE
|
||||||
@ -1332,7 +1292,6 @@ void qTabPlot::SetFrequency() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetBinary() {
|
void qTabPlot::SetBinary() {
|
||||||
//1d
|
//1d
|
||||||
@ -1387,7 +1346,6 @@ void qTabPlot::SetBinary() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::SetHistogramOptions() {
|
void qTabPlot::SetHistogramOptions() {
|
||||||
if (radioHistIntensity->isChecked()) {
|
if (radioHistIntensity->isChecked()) {
|
||||||
@ -1399,7 +1357,6 @@ void qTabPlot::SetHistogramOptions() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::EnableGapPixels(bool enable) {
|
void qTabPlot::EnableGapPixels(bool enable) {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
@ -1415,7 +1372,6 @@ void qTabPlot::EnableGapPixels(bool enable) {
|
|||||||
connect(chkGapPixels, SIGNAL(toggled(bool)), this, SLOT(EnableGapPixels(bool)));
|
connect(chkGapPixels, SIGNAL(toggled(bool)), this, SLOT(EnableGapPixels(bool)));
|
||||||
}
|
}
|
||||||
|
|
||||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
void qTabPlot::Refresh() {
|
void qTabPlot::Refresh() {
|
||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
|
Reference in New Issue
Block a user