DynExp
Highly flexible laboratory automation for dynamically changing experiments.
DynExpModule::SignalPlotterWidget Class Reference
+ Inheritance diagram for DynExpModule::SignalPlotterWidget:

Classes

struct  SampleDataType
 

Public Member Functions

 SignalPlotterWidget (SignalPlotter &Owner, QModuleWidget *parent=nullptr)
 
 ~SignalPlotterWidget ()=default
 
bool AllowResize () const noexcept override final
 Indicates the resizing behavior of the user interface window. Override to adjust. More...
 
auto * GetAutoscalePlotAction () noexcept
 
auto * GetRollingViewPlotAction () noexcept
 
auto * GetClearPlotAction () const noexcept
 
void UpdateUI (bool IsRunning)
 
void SetAxes (QValueAxis *XAxis, QValueAxis *YAxis)
 
void SetData (const SampleDataType &SampleData)
 
auto GetXAxis () noexcept
 
auto GetYAxis () noexcept
 
auto GetMultiplier () noexcept
 
- Public Member Functions inherited from DynExp::QModuleWidget
 QModuleWidget (QModuleBase &Owner, QWidget *Parent=nullptr)
 Constructs a QModuleWidget instance. More...
 
 ~QModuleWidget ()=default
 
const auto & GetOwner () const noexcept
 Getter for the owning module. More...
 
Qt::WindowFlags GetQtWindowFlags () const noexcept
 Depending on thr return value of AllowResize(), returns either the return value of GetQtWindowFlagsResizable() or GetQtWindowFlagsNonResizable(). More...
 
std::string GetDataSaveDirectory () const
 Recalls a path where modules might save recorded data to. Used by Util::PromptSaveFilePathModule() to recall the directory the user has chosen last for saving a file. This directory is the same across all modules. More...
 
void SetDataSaveDirectory (std::string_view Directory) const
 Sets a path where modules might save recorded data to. Used by Util::PromptSaveFilePathModule() to store the directory the user has chosen last for saving a file. This directory is the same across all modules. More...
 

Public Attributes

Ui::SignalPlotter ui
 

Private Types

using FinishedSavingDataGuardType = Util::OnDestruction< SignalPlotterWidget, decltype(&SignalPlotterWidget::FinishedSavingData)>
 

Private Slots

void OnPlotContextMenuRequested (const QPoint &Position)
 
void OnSaveCSVClicked ()
 

Private Member Functions

void FinishedSavingData () noexcept
 

Private Attributes

QMenu * PlotContextMenu
 
QAction * PlotAutoscaleAction
 
QAction * PlotRollingViewAction
 
QAction * PlotClearAction
 
QXYSeries * DataSeries
 
QChart * DataChart
 
QValueAxis * XAxis
 
QValueAxis * YAxis
 
decltype(SampleDataType::Multiplier) Multiplier = 0
 Describes the factor 10^Multiplier the displayed data has been multiplied with for better x-label readability. More...
 
std::atomic_bool IsSavingData = false
 

Additional Inherited Members

- Static Public Member Functions inherited from DynExp::QModuleWidget
constexpr static Qt::WindowFlags GetQtWindowFlagsResizable ()
 Default Qt window flags for resizable module windows. More...
 
constexpr static Qt::WindowFlags GetQtWindowFlagsNonResizable ()
 Default Qt window flags for non-resizable module windows. More...
 

Detailed Description

Definition at line 21 of file SignalPlotter.h.

Member Typedef Documentation

◆ FinishedSavingDataGuardType

Constructor & Destructor Documentation

◆ SignalPlotterWidget()

DynExpModule::SignalPlotterWidget::SignalPlotterWidget ( SignalPlotter Owner,
QModuleWidget parent = nullptr 
)

Definition at line 9 of file SignalPlotter.cpp.

◆ ~SignalPlotterWidget()

DynExpModule::SignalPlotterWidget::~SignalPlotterWidget ( )
default

Member Function Documentation

◆ AllowResize()

bool DynExpModule::SignalPlotterWidget::AllowResize ( ) const
inlinefinaloverridevirtualnoexcept

Indicates the resizing behavior of the user interface window. Override to adjust.

Returns
Return true when the window should be resizable by the user, false otherwise.

Reimplemented from DynExp::QModuleWidget.

Definition at line 42 of file SignalPlotter.h.

◆ FinishedSavingData()

void DynExpModule::SignalPlotterWidget::FinishedSavingData ( )
inlineprivatenoexcept

Definition at line 59 of file SignalPlotter.h.

◆ GetAutoscalePlotAction()

auto* DynExpModule::SignalPlotterWidget::GetAutoscalePlotAction ( )
inlinenoexcept

Definition at line 44 of file SignalPlotter.h.

◆ GetClearPlotAction()

auto* DynExpModule::SignalPlotterWidget::GetClearPlotAction ( ) const
inlinenoexcept

Definition at line 46 of file SignalPlotter.h.

◆ GetMultiplier()

auto DynExpModule::SignalPlotterWidget::GetMultiplier ( )
inlinenoexcept

Definition at line 54 of file SignalPlotter.h.

◆ GetRollingViewPlotAction()

auto* DynExpModule::SignalPlotterWidget::GetRollingViewPlotAction ( )
inlinenoexcept

Definition at line 45 of file SignalPlotter.h.

◆ GetXAxis()

auto DynExpModule::SignalPlotterWidget::GetXAxis ( )
inlinenoexcept

Definition at line 52 of file SignalPlotter.h.

◆ GetYAxis()

auto DynExpModule::SignalPlotterWidget::GetYAxis ( )
inlinenoexcept

Definition at line 53 of file SignalPlotter.h.

◆ OnPlotContextMenuRequested

void DynExpModule::SignalPlotterWidget::OnPlotContextMenuRequested ( const QPoint &  Position)
privateslot

Definition at line 113 of file SignalPlotter.cpp.

◆ OnSaveCSVClicked

void DynExpModule::SignalPlotterWidget::OnSaveCSVClicked ( )
privateslot

Definition at line 118 of file SignalPlotter.cpp.

◆ SetAxes()

void DynExpModule::SignalPlotterWidget::SetAxes ( QValueAxis *  XAxis,
QValueAxis *  YAxis 
)

Definition at line 38 of file SignalPlotter.cpp.

◆ SetData()

void DynExpModule::SignalPlotterWidget::SetData ( const SampleDataType SampleData)

Definition at line 62 of file SignalPlotter.cpp.

◆ UpdateUI()

void DynExpModule::SignalPlotterWidget::UpdateUI ( bool  IsRunning)

Definition at line 32 of file SignalPlotter.cpp.

Member Data Documentation

◆ DataChart

QChart* DynExpModule::SignalPlotterWidget::DataChart
private

Definition at line 68 of file SignalPlotter.h.

◆ DataSeries

QXYSeries* DynExpModule::SignalPlotterWidget::DataSeries
private

Definition at line 67 of file SignalPlotter.h.

◆ IsSavingData

std::atomic_bool DynExpModule::SignalPlotterWidget::IsSavingData = false
private

Definition at line 78 of file SignalPlotter.h.

◆ Multiplier

decltype(SampleDataType::Multiplier) DynExpModule::SignalPlotterWidget::Multiplier = 0
private

Describes the factor 10^Multiplier the displayed data has been multiplied with for better x-label readability.

Definition at line 75 of file SignalPlotter.h.

◆ PlotAutoscaleAction

QAction* DynExpModule::SignalPlotterWidget::PlotAutoscaleAction
private

Definition at line 63 of file SignalPlotter.h.

◆ PlotClearAction

QAction* DynExpModule::SignalPlotterWidget::PlotClearAction
private

Definition at line 65 of file SignalPlotter.h.

◆ PlotContextMenu

QMenu* DynExpModule::SignalPlotterWidget::PlotContextMenu
private

Definition at line 62 of file SignalPlotter.h.

◆ PlotRollingViewAction

QAction* DynExpModule::SignalPlotterWidget::PlotRollingViewAction
private

Definition at line 64 of file SignalPlotter.h.

◆ ui

Ui::SignalPlotter DynExpModule::SignalPlotterWidget::ui

Definition at line 56 of file SignalPlotter.h.

◆ XAxis

QValueAxis* DynExpModule::SignalPlotterWidget::XAxis
private

Definition at line 69 of file SignalPlotter.h.

◆ YAxis

QValueAxis* DynExpModule::SignalPlotterWidget::YAxis
private

Definition at line 70 of file SignalPlotter.h.


The documentation for this class was generated from the following files: