diff options
| author | Christoph Berg <myon@debian.org> | 2019-06-02 22:20:23 +0200 |
|---|---|---|
| committer | Christoph Berg <myon@debian.org> | 2019-06-02 22:20:23 +0200 |
| commit | e6817de24bdd0a9f5677b07d6bff897a5db47794 (patch) | |
| tree | 1eba79fe1a06ab93d1025297cee39e95dfab98a4 /widgets/plotter.cpp | |
| parent | 58a14345036378f9040e269fa276ba0c97795037 (diff) | |
| parent | 851b658298afb9bafeda98ffbfa2ade612c656be (diff) | |
Update upstream source from tag 'upstream/2.1.0_rc6+repack'
Update to upstream version '2.1.0~rc6+repack'
with Debian dir 2aba196aec0548f1bb333214231be9cc9efe2d4c
Diffstat (limited to 'widgets/plotter.cpp')
| -rw-r--r-- | widgets/plotter.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/widgets/plotter.cpp b/widgets/plotter.cpp index 98c1af16..badeff57 100644 --- a/widgets/plotter.cpp +++ b/widgets/plotter.cpp @@ -241,9 +241,9 @@ void CPlotter::draw(float swide[], bool bScroll, bool bRed) painter1.setPen(Qt::white); QString t; qint64 ms = QDateTime::currentMSecsSinceEpoch() % 86400000; - int n=(ms/1000) % m_TRperiod; + int n = fmod(0.001*ms,m_TRperiod); QDateTime t1=QDateTime::currentDateTimeUtc().addSecs(-n); - if(m_TRperiod < 60 or m_mode=="FT4") { + if(m_TRperiod<60.0) { t=t1.toString("hh:mm:ss") + " " + m_rxBand; } else { t=t1.toString("hh:mm") + " " + m_rxBand; @@ -411,7 +411,7 @@ void CPlotter::DrawOverlay() //DrawOverlay() } float bw=9.0*12000.0/m_nsps; //JT9 - if(m_mode=="FT4") bw=3*12000.0/512.0; //FT4 ### (3x, or 4x???) ### + if(m_mode=="FT4") bw=3*12000.0/576.0; //FT4 ### (3x, or 4x???) ### if(m_mode=="FT8") bw=7*12000.0/1920.0; //FT8 if(m_mode=="JT4") { //JT4 @@ -721,9 +721,9 @@ void CPlotter::mouseDoubleClickEvent (QMouseEvent * event) } } -void CPlotter::setNsps(int ntrperiod, int nsps) //setNsps +void CPlotter::setNsps(double trperiod, int nsps) //setNsps { - m_TRperiod=ntrperiod; + m_TRperiod=trperiod; m_nsps=nsps; m_fftBinWidth=1500.0/2048.0; if(m_nsps==15360) m_fftBinWidth=1500.0/2048.0; |
