diff --git a/mainwindow.cpp b/mainwindow.cpp index c96fb1da9..773adb9ef 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -246,6 +246,7 @@ MainWindow::MainWindow(QSharedMemory *shdmem, QWidget *parent) : g_pWideGraph->setFmin(m_fMin); g_pWideGraph->setModeTx(m_mode); g_pWideGraph->setModeTx(m_modeTx); + dialFreqChanged2(m_dialFreq); connect(g_pWideGraph, SIGNAL(setFreq3(int,int)),this, SLOT(setFreq4(int,int))); @@ -991,6 +992,7 @@ void MainWindow::dialFreqChanged2(double f) } ui->labDialFreq->setText(t); statusChanged(); + if(g_pWideGraph!=NULL) g_pWideGraph->setDialFreq(m_dialFreq); } void MainWindow::statusChanged() @@ -1596,9 +1598,9 @@ void MainWindow::guiUpdate() if(onAirFreq!=onAirFreq0) { onAirFreq0=onAirFreq; on_autoButton_clicked(); - QString t="Please choose another Tx frequency.\nWSJT-X will not "; - t+="knowingly transmit\nbetween 10.139 900 and 10.140 320 MHz,\n"; - t+="the 30 m sub-band for WSPR transmissions."; + QString t="Please choose another Tx frequency.\n"; + t+="WSJT-X will not knowingly transmit\n"; + t+="in the WSPR sub-band on 30 m."; msgBox0.setText(t); msgBox0.show(); } diff --git a/plotter.cpp b/plotter.cpp index 39f12eb75..a43bdbf2d 100644 --- a/plotter.cpp +++ b/plotter.cpp @@ -288,6 +288,18 @@ void CPlotter::DrawOverlay() //DrawOverlay() painter0.drawLine(x1,17,x1,21); painter0.drawLine(x1,17,x2,17); painter0.drawLine(x2,17,x2,21); + + if(m_dialFreq>10.13 and m_dialFreq< 10.15) { + float f1=1.0e6*(10.1401 - m_dialFreq); + float f2=f1+200.0; + x1=XfromFreq(f1); + x2=XfromFreq(f2); + if(x1<=m_w and x2>=0) { + QPen pen1(QColor(255,165,0),3); //Mark WSPR sub-band orange + painter0.setPen(pen1); + painter0.drawLine(x1,9,x2,9); + } + } } void CPlotter::MakeFrequencyStrs() //MakeFrequencyStrs @@ -544,3 +556,10 @@ int CPlotter::getFmax() { return m_fMax; } + +void CPlotter::setDialFreq(double d) +{ + m_dialFreq=d; + DrawOverlay(); + update(); +} diff --git a/plotter.h b/plotter.h index aa4470230..b491cf9ee 100644 --- a/plotter.h +++ b/plotter.h @@ -70,6 +70,7 @@ public: double fGreen(); void SetPercent2DScreen(int percent){m_Percent2DScreen=percent;} int getFmax(); + void setDialFreq(double d); signals: void freezeDecode1(int n); @@ -105,6 +106,7 @@ private: double m_fGreen; double m_fftBinWidth; + double m_dialFreq; qint64 m_StartFreq; diff --git a/widegraph.cpp b/widegraph.cpp index 97fc5cb35..3efa1f299 100644 --- a/widegraph.cpp +++ b/widegraph.cpp @@ -306,3 +306,9 @@ void WideGraph::setFreq2(int rxFreq, int txFreq) m_txFreq=txFreq; emit setFreq3(rxFreq,txFreq); } + +void WideGraph::setDialFreq(double d) +{ + m_dialFreq=d; + ui->widePlot->setDialFreq(d); +} diff --git a/widegraph.h b/widegraph.h index 5e626a602..194998dfd 100644 --- a/widegraph.h +++ b/widegraph.h @@ -48,6 +48,7 @@ signals: public slots: void wideFreezeDecode(int n); void setFreq2(int rxFreq, int txFreq); + void setDialFreq(double d); protected: virtual void keyPressEvent( QKeyEvent *e ); @@ -63,6 +64,7 @@ private slots: private: double m_slope; + double m_dialFreq; qint32 m_waterfallAvg; qint32 m_fSample;