summaryrefslogtreecommitdiff
path: root/widgets/plotter.h
diff options
context:
space:
mode:
authorChristoph Berg <myon@debian.org>2026-09-26 23:24:03 +0200
committerChristoph Berg <myon@debian.org>2026-09-26 23:24:03 +0200
commit059831534c7e884f0a607ed86b582fd00d821731 (patch)
tree76bcb67a78f8aa2654fd34c2ad801a62136b0170 /widgets/plotter.h
parentd83a420f0517d7fc47aeb288a6a0cf4891784fcc (diff)
New upstream version 3.2.0~rc1+dfsgupstream/3.2.0_rc1+dfsg
Diffstat (limited to 'widgets/plotter.h')
-rw-r--r--widgets/plotter.h34
1 files changed, 14 insertions, 20 deletions
diff --git a/widgets/plotter.h b/widgets/plotter.h
index 1f3b8c42..af2ec36c 100644
--- a/widgets/plotter.h
+++ b/widgets/plotter.h
@@ -15,8 +15,9 @@
#include <QColor>
#include <QToolTip>
+#include "WaterfallScale.hpp"
+
#define VERT_DIVS 7 //specify grid screen divisions
-#define HORZ_DIVS 20
extern bool g_single_decode;
@@ -50,7 +51,6 @@ public:
int plotWidth();
void UpdateOverlay();
void setDataFromDisk(bool b);
- void setRxRange(int fMin);
void setBinsPerPixel(int n);
int binsPerPixel();
void setWaterfallAvg(int n);
@@ -71,9 +71,9 @@ public:
bool cumulative() const {return m_bCumulative;}
void setLinearAvg(bool b) {m_bLinearAvg = b;}
bool linearAvg() const {return m_bLinearAvg;}
- void setBreadth(qint32 w) {m_w = w;}
- qint32 breadth() const {return m_w;}
- float fSpan() const {return m_fSpan;}
+ void setBreadth(qint32 w) {m_scale.setWidth(w);}
+ qint32 breadth() const {return m_scale.width();}
+ float fSpan() const {return m_scale.spanHz();}
void setColours(QVector<QColor> const& cl);
void setTimestamp(int n);
void setBars(bool b);
@@ -102,6 +102,7 @@ public:
signals:
void freezeDecode1(int n);
void setFreq1(int rxFreq, int txFreq);
+ void jttyDecodeAgainAt(float secondsAgo);
protected:
//re-implemented widget event handlers
@@ -113,9 +114,9 @@ protected:
private:
- void MakeFrequencyStrs();
int XfromFreq(float f);
float FreqfromX(int x);
+ void drawSavedWaterfall();
QAction * m_set_freq_action;
@@ -126,7 +127,7 @@ private:
bool m_bReference;
bool m_bReference0;
bool m_bQ65_Sync;
- bool m_bTotalPower;
+ bool m_bTotalPower=false;
bool m_bVHF;
bool m_bSingleDecode;
bool m_bFirst=true;
@@ -134,8 +135,7 @@ private:
bool m_bSuperFox=false;
bool m_bSuperHound=false;
bool m_bars;
- bool m_freq;
- float m_fSpan;
+ bool m_freq=false;
float m_pdB=0.0;
float m_vpixperdiv;
bool m_useDarkStyle=false;
@@ -144,9 +144,7 @@ private:
qint32 m_plotGain;
qint32 m_plot2dGain;
qint32 m_plot2dZero;
- qint32 m_binsPerPixel;
qint32 m_waterfallAvg;
- qint32 m_w;
qint32 m_Flatten;
qint32 m_nSubMode;
qint32 m_ia;
@@ -166,7 +164,9 @@ private:
QPoint m_pos;
QSize m_Size;
QString m_Str;
- QString m_HDivText[483];
+ QVector<float> m_swideDisplay;
+ QVector<float> m_savgDisplay;
+ QVector<float> m_replotRow;
QString m_mode;
QString m_mode0;
QString m_rxBand;
@@ -177,20 +177,15 @@ private:
bool m_dataFromDisk;
bool m_bReplot;
- double m_fftBinWidth;
double m_dialFreq;
- double m_xOffset;
double m_TRperiod;
float m_sum[2048];
qint32 m_dBStepSize;
- qint32 m_FreqUnits;
- qint32 m_hdivs;
qint32 m_line;
qint32 m_fSample;
qint32 m_xClick;
- qint32 m_freqPerDiv;
qint32 m_nsps;
qint32 m_Percent2DScreen;
qint32 m_Percent2DScreen0;
@@ -200,15 +195,14 @@ private:
qint32 m_rxFreq;
qint32 m_rxFreq0=0;
qint32 m_txFreq;
- qint32 m_fMin;
- qint32 m_fMax;
- qint32 m_startFreq;
qint32 m_tol;
qint32 m_lastMouseX;
qint32 m_lastPaintedX;
qint32 m_j;
char m_sutc[6];
+ WaterfallScale m_scale;
+
private slots:
void leaveEvent(QEvent *event) override;