From 1d3e676063c1db2427bfeabaeb78fd9cd24fcd49 Mon Sep 17 00:00:00 2001 From: "Edson W. R. Pereira" Date: Sun, 24 Mar 2013 14:05:31 +0000 Subject: [PATCH] Syncing updates git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@3079 ab8295b8-cf94-4d9e-aec4-7959e3be5d79 --- mainwindow.cpp | 39 +- mainwindow.h | 2 +- mainwindow.ui | 2234 +++++++++++++++++++++++++++--------------------- soundin.cpp | 1 + 4 files changed, 1280 insertions(+), 996 deletions(-) diff --git a/mainwindow.cpp b/mainwindow.cpp index c6e566e9a..8bf6622b6 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -35,10 +35,10 @@ MainWindow::MainWindow(QWidget *parent) : on_EraseButton_clicked(); ui->labUTC->setStyleSheet( \ "QLabel { background-color : black; color : yellow; }"); - ui->labTol1->setStyleSheet( \ - "QLabel { background-color : white; color : black; }"); - ui->labTol1->setFrameStyle(QFrame::Panel | QFrame::Sunken); - ui->dxStationGroupBox->setStyleSheet("QFrame{border: 5px groove red}"); + //ui->labTol1->setStyleSheet( \ + // "QLabel { background-color : white; color : black; }"); + //ui->labTol1->setFrameStyle(QFrame::Panel | QFrame::Sunken); + //ui->dxStationGroupBox->setStyleSheet("QFrame{border: 5px groove red}"); QActionGroup* paletteGroup = new QActionGroup(this); ui->actionCuteSDR->setActionGroup(paletteGroup); @@ -133,7 +133,7 @@ MainWindow::MainWindow(QWidget *parent) : decodeBusy(false); ui->xThermo->setFillBrush(Qt::green); - ui->labAzDist->setStyleSheet("border: 0px;"); + //ui->labAzDist->setStyleSheet("border: 0px;"); #ifdef WIN32 while(true) { @@ -164,8 +164,8 @@ MainWindow::MainWindow(QWidget *parent) : readSettings(); //Restore user's setup params QFile lockFile(m_appDir + "/.lock"); //Create .lock so jt9 will wait lockFile.open(QIODevice::ReadWrite); - QFile quitFile(m_appDir + "/.lock"); - quitFile.remove(); + //QFile quitFile(m_appDir + "/.lock"); + //quitFile.remove(); proc_jt9.start(QDir::toNativeSeparators('"' + m_appDir + '"' + "/jt9 -s")); m_pbdecoding_style1="QPushButton{background-color: cyan; \ @@ -205,7 +205,7 @@ MainWindow::MainWindow(QWidget *parent) : g_pWideGraph->setTol(m_tol); static int ntol[] = {1,2,5,10,20,50,100,200,500}; for (int i=0; i<10; i++) { - if(ntol[i]==m_tol) ui->tolSpinBox->setValue(i); + if(ntol[i]==m_tol) ui->tolSlider->setValue(i); } // Create "m_worked", a dictionary of all calls in wsjtx.log @@ -226,6 +226,10 @@ MainWindow::MainWindow(QWidget *parent) : if(ui->actionAFMHot->isChecked()) on_actionAFMHot_triggered(); if(ui->actionBlue->isChecked()) on_actionBlue_triggered(); + ui->decodedTextLabel->setFont(ui->decodedTextBrowser->font()); + // 2241 10 -8 0.2 1184. 0 VK7XX N1ISA FN41 + ui->decodedTextLabel->setText("UTC Sync dB DT Freq Dr Msg"); + #ifdef WIN32 if(m_pskReporter) { rc=ReporterInitialize(NULL,NULL); @@ -747,12 +751,12 @@ void MainWindow::createStatusBar() //createStatusBar statusBar()->addWidget(lab5); } -void MainWindow::on_tolSpinBox_valueChanged(int i) //tolSpinBox +void MainWindow::on_tolSlider_valueChanged(int i) //tolSlider { static int ntol[] = {1,2,5,10,20,50,100,200,500}; m_tol=ntol[i]; g_pWideGraph->setTol(m_tol); - ui->labTol1->setText(QString::number(ntol[i])); + ui->labTol1->setText("Tolerance: " + QString::number(ntol[i])); } void MainWindow::on_actionExit_triggered() //Exit() @@ -1000,7 +1004,7 @@ void MainWindow::freezeDecode(int n) //freezeDecode() if(m_mode=="JT9-30") i=1; m_tol=ntol[i]; g_pWideGraph->setTol(m_tol); - ui->tolSpinBox->setValue(i); + ui->tolSlider->setValue(i); decode(); } } @@ -1109,9 +1113,11 @@ void MainWindow::readFromStdout() //readFromStdout QString bg="white"; if(t.indexOf(" CQ ")>0) bg="#66ff66"; //Light green if(t.indexOf(" "+m_myCall+" ")>0) bg="#ff6666"; //Light red - ui->decodedTextBrowser->setTextBackgroundColor(bg); - t=t.mid(0,n-2) + " "; - ui->decodedTextBrowser->append(t); + //ui->decodedTextBrowser->setTextBackgroundColor(bg); + //t=t.mid(0,n-2) + " "; + ui->decodedTextBrowser->append("" + "" + "
"+ t + "
"); QString msg=t.mid(34,22); bool b=stdmsg_(msg.toAscii().constData()); QStringList w=msg.split(" ",QString::SkipEmptyParts); @@ -1800,9 +1806,9 @@ void MainWindow::on_dxGridEntry_textChanged(const QString &t) //dxGrid changed &nAz,&nEl,&nDmiles,&nDkm,&nHotAz,&nHotABetter,6,6); QString t; t.sprintf("Az: %d %d km",nAz,nDkm); - ui->labAzDist->setText(t); + //ui->labAzDist->setText(t); } else { - ui->labAzDist->setText(""); + //ui->labAzDist->setText(""); } } @@ -1925,6 +1931,7 @@ void MainWindow::on_NBcheckBox_toggled(bool checked) void MainWindow::on_NBslider_valueChanged(int n) { m_NBslider=n; + ui->NBcheckBox->setText("NB: " + QString::number(n)); } void MainWindow::on_TxFreqSpinBox_valueChanged(int n) diff --git a/mainwindow.h b/mainwindow.h index 986161243..7d8ef2dc1 100644 --- a/mainwindow.h +++ b/mainwindow.h @@ -58,7 +58,7 @@ private slots: void on_actionCuteSDR_triggered(); void on_autoButton_clicked(); void on_stopTxButton_clicked(); - void on_tolSpinBox_valueChanged(int arg1); + void on_tolSlider_valueChanged(int arg1); void on_stopButton_clicked(); void on_actionOnline_Users_Guide_triggered(); void on_actionWide_Waterfall_triggered(); diff --git a/mainwindow.ui b/mainwindow.ui index ddd2df56f..173baf8f6 100644 --- a/mainwindow.ui +++ b/mainwindow.ui @@ -6,26 +6,26 @@ 0 0 - 643 + 686 527 - + 0 0 - 0 + 686 475 - 2048 - 800 + 686 + 1028 @@ -35,82 +35,148 @@ - - + + - - - - 0 - 0 - - - - - 453 - 170 - - - - - 620 - 16777215 - - - - UTC Sync dB DT Freq Drift - - - - - - - 0 - 0 - - - - - 421 - 100 - - - - - 610 - 400 - - - - - Courier New - 10 - - - - QFrame::Panel - - - Qt::ScrollBarAlwaysOn - - - Qt::ScrollBarAsNeeded - - - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> + + + + + + 0 + 20 + + + + + 16777215 + 20 + + + + + + + + + 252 + 252 + 252 + + + + + + + 170 + 170 + 170 + + + + + + + + + 252 + 252 + 252 + + + + + + + 170 + 170 + 170 + + + + + + + + + 170 + 170 + 170 + + + + + + + 170 + 170 + 170 + + + + + + + + true + + + UTC Sync dB DT Freq Dr + + + 5 + + + + + + + + 0 + 0 + + + + + 421 + 100 + + + + + 1000 + 1000 + + + + + Courier New + 10 + + + + QFrame::Panel + + + Qt::ScrollBarAlwaysOn + + + Qt::ScrollBarAsNeeded + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } </style></head><body style=" font-family:'Courier New'; font-size:10pt; font-weight:400; font-style:normal;"> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p></body></html> - - - false - - - - - +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><br /></p></body></html> + + + false + + + + @@ -232,63 +298,330 @@ p, li { white-space: pre-wrap; } - - - + + + - - 0 + + 160 0 + + + 180 + 24 + + + + + + + + Qt::Horizontal + + + QSizePolicy::Fixed + + + + 15 + 20 + + + + + + - 16777215 - 26 + 40 + 16777215 - dB + Tx 3 - - + + + + + 40 + 16777215 + + + + Tx 2 + + + + + - - 0 + + 16 0 - + - 43 - 180 + 0 + 20 - - 1 + + + 20 + 16777215 + - - 60.000000000000000 + + - - 0.000000000000000 + + buttonGroup + + + + + + + + 16 + 0 + - - 8 + + + 0 + 20 + - - 0.000000000000000 + + + 20 + 16777215 + + + + + + + true + + + buttonGroup + + + + + + + + 150 + 16777215 + + + + Add - + + + + + + + + + 252 + 252 + 252 + + + + + + + 172 + 191 + 166 + + + + + + + + + 252 + 252 + 252 + + + + + + + 172 + 191 + 166 + + + + + + + + + 172 + 191 + 166 + + + + + + + 172 + 191 + 166 + + + + + + + + true + + + QFrame::NoFrame + + + QFrame::Raised + + + + 0 + + + 0 + + + + + 6 + + + + + + 120 + 16777215 + + + + NB + + + + + + + + 120 + 16777215 + + + + Qt::Horizontal + + + + + + + + + + + + + 16 + 0 + + + + + 0 + 20 + + + + + 20 + 16777215 + + + + + + + buttonGroup + + + + + + + + 40 + 16777215 + + + + Tx 1 + + + + + + + + 16 + 0 + + + + + 0 + 20 + + + + + 20 + 16777215 + + + + + + + buttonGroup + + + + 16777215 - 170 + 180 @@ -302,231 +635,162 @@ p, li { white-space: pre-wrap; } - - - - - - - 0 - 0 - - - - - 143 - 40 - - - - - 290 - 135 - - - - - - - DX Call Grid - - - - - 231 - 13 - 50 - 23 - - - - - 50 - 16777215 - - - - SetMsgs - - - - - - 8 - 14 - 128 - 113 - - - - - - - - - - 0 - 0 - - - - - 0 - 23 - - - - - 70 - 16777215 - - - - - - - - - - - - 0 - 0 - - - - - 0 - 23 - - - - - 48 - 16777215 - - - - - - - - - - - - - - - - 50 - 16777215 - - - - &Lookup - - - - - - - Qt::Horizontal - - - - 40 - 20 - - - - - - - - - 50 - 16777215 - - - - Add - - - - - - - - - - 0 - 20 - - - - - - - Qt::AlignCenter - - - - - - - - 70 - 16777215 - - - - &GenStdMsgs - - - - - - - - - - - - 150 - 52 - - - - - 16 - - - - QFrame::StyledPanel - - - QFrame::Sunken - - - 2 - - - 0 - - - 2013 Mar 23 - 01:23:45 - - - Qt::AlignCenter - - - - + + + + + 160 + 0 + + + + + 180 + 24 + + + - - + + + + + 16 + 0 + + + + + 0 + 20 + + + + + 20 + 16777215 + + + + + + + buttonGroup + + + + + + + + 16 + 0 + + + + + 0 + 20 + + + + + 20 + 16777215 + + + + + + + buttonGroup + + + + + + + + 0 + 0 + + + + + 16777215 + 16777215 + + + + dB + + + + + + + + 0 + 23 + + + + + 150 + 16777215 + + + + Tx first + + + + + + + + 0 + 0 + + + + + 100 + 0 + + + + Hz + + + Tx + + + + 500 + + + 20000 + + + 1500 + + + + + + + + 40 + 16777215 + + + + Tx 6 + + + + + Qt::Horizontal @@ -535,654 +799,674 @@ p, li { white-space: pre-wrap; } - 13 + 15 20 - - - - - - Qt::Vertical - - - QSizePolicy::Fixed - - - - 20 - 20 - - - - - - - - - 0 - 23 - - - - - 70 - 16777215 - - - - Tx first - - - - - - - - 0 - 0 - - - - - 100 - 0 - - - - Hz - - - Tx + - - - 500 - - - 20000 - - - 1500 - - - - - - - - 0 - 0 - - - - - 100 - 0 - - - - Tx = QSO Freq - - - - - - - Qt::Vertical - - - QSizePolicy::Fixed - - - - 20 - 20 - - - - - - - - - 120 - 16777215 - - - - NB - - - - - - - - 120 - 16777215 - - - - Qt::Horizontal - - - - - - - - - - 0 - 0 - - - - - 30 - 0 - - - - - 25 - 18 - - - - 50 - - - Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter - - - - - - - true - - - - 0 - 0 - - - - - 0 - 23 - - - - - 18 - 16777215 - - - - 0 - - - 8 - - - 5 - - - - - - - - 0 - 0 - - - - - 20 - 16777215 - - - - Tol - - - - - - + + + + Qt::Horizontal + + + QSizePolicy::Fixed + + + + 15 + 20 + + + - - - - - - - - - 160 - 0 - - - - - 180 - 24 - - - - - MS Shell Dlg 2 - - - - - - - - - - - - 160 - 0 - - - - - 180 - 24 - - - - - - - - - 160 - 0 - - - - - 180 - 24 - - - - - - - - - 160 - 0 - - - - - 180 - 24 - - - - - - - - - 160 - 0 - - - - - 180 - 24 - - - - - - - - - 160 - 0 - - - - - 180 - 24 - - - - - - - - - - Qt::Horizontal - - - QSizePolicy::Fixed - - - - 1 - 20 - - - - - - - - - - - 16 - 0 - - - - - 0 - 20 - - - - - 20 - 16777215 - - - - - - - true - - - buttonGroup - - - - - - - - 16 - 0 - - - - - 0 - 20 - - - - - 20 - 16777215 - - - - - - - buttonGroup - - - - - - - - 16 - 0 - - - - - 0 - 20 - - - - - 20 - 16777215 - - - - - - - buttonGroup - - - - - - - - 16 - 0 - - - - - 0 - 20 - - - - - 20 - 16777215 - - - - - - - buttonGroup - - - - - - - - 16 - 0 - - - - - 0 - 20 - - - - - 20 - 16777215 - - - - - - - buttonGroup - - - - - - - - 16 - 0 - - - - - 0 - 20 - - - - - 20 - 16777215 - - - - - - - buttonGroup - - - - - - - - - - - - 50 - 20 - - - - - 0 - 16 - - - - - 29 - 20 - - - - Tx1 - - - - - - - - 0 - 16 - - - - - 29 - 20 - - - - Tx2 - - - - - - - - 0 - 16 - - - - - 29 - 20 - - - - Tx3 - - - - - - - - 0 - 16 - - - - - 29 - 20 - - - - Tx4 - - - - - - - - 0 - 16 - - - - - 29 - 20 - - - - Tx5 - - - - - - - - 0 - 16 - - - - - 29 - 20 - - - - Tx6 - - - - - - + + + + + 160 + 0 + + + + + 180 + 24 + + + + + Droid Sans + 50 + false + + + + + + + + + + + + 0 + 0 + + + + + 43 + 180 + + + + 1 + + + 60.000000000000000 + + + 0.000000000000000 + + + 8 + + + 0.000000000000000 + + + + + + + + 40 + 16777215 + + + + Tx 5 + + + + + + + + 0 + 0 + + + + + 100 + 0 + + + + Tx = QSO Freq + + + + + + + + 0 + 0 + + + + + 150 + 16777215 + + + + &GenStdMsgs + + + + + + + + 0 + 0 + + + + + 130 + 60 + + + + + 150 + 60 + + + + + 16 + + + + QFrame::StyledPanel + + + QFrame::Sunken + + + 2 + + + 0 + + + 01:23:45 + + + Qt::AlignCenter + + + + + + + + 150 + 16777215 + + + + &Lookup + + + + + + + + 160 + 0 + + + + + 180 + 24 + + + + + + + + + 160 + 0 + + + + + 180 + 24 + + + + + + + + + + + + + 252 + 252 + 252 + + + + + + + 172 + 191 + 166 + + + + + + + + + 252 + 252 + 252 + + + + + + + 172 + 191 + 166 + + + + + + + + + 172 + 191 + 166 + + + + + + + 172 + 191 + 166 + + + + + + + + true + + + QFrame::StyledPanel + + + QFrame::Plain + + + 1 + + + + 0 + + + 0 + + + + + 6 + + + + + + 0 + 0 + + + + + 30 + 22 + + + + + 130 + 18 + + + + Tolerance: 50 + + + Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter + + + 5 + + + + + + + + 120 + 16777215 + + + + 8 + + + Qt::Horizontal + + + + + + + + + + + + + 40 + 16777215 + + + + Tx 4 + + + + + + + + 160 + 0 + + + + + 180 + 24 + + + + + + + + + + + + + 252 + 252 + 252 + + + + + + + 170 + 190 + 200 + + + + + + + + + 252 + 252 + 252 + + + + + + + 170 + 190 + 200 + + + + + + + + + 170 + 190 + 200 + + + + + + + 170 + 190 + 200 + + + + + + + + true + + + QFrame::NoFrame + + + QFrame::Raised + + + + 0 + + + 0 + + + + + 5 + + + + + + 0 + 23 + + + + DX Call + + + Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter + + + 2 + + + + + + + + 0 + 0 + + + + + 0 + 27 + + + + + 70 + 16777215 + + + + + + + + + + + + + + + + + 60 + 16777215 + + + + + + + + + 252 + 252 + 252 + + + + + + + 170 + 190 + 200 + + + + + + + + + 252 + 252 + 252 + + + + + + + 170 + 190 + 200 + + + + + + + + + 170 + 190 + 200 + + + + + + + 170 + 190 + 200 + + + + + + + + true + + + QFrame::NoFrame + + + QFrame::Raised + + + + 0 + + + 0 + + + + + 5 + + + + + + 0 + 23 + + + + DX Grid + + + Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter + + + 2 + + + + + + + + 0 + 0 + + + + + 0 + 24 + + + + + 80 + 16777215 + + + + + + + + + + + @@ -1195,8 +1479,8 @@ p, li { white-space: pre-wrap; } 0 0 - 643 - 21 + 686 + 25 @@ -1288,14 +1572,6 @@ p, li { white-space: pre-wrap; } - - - TopToolBarArea - - - false - - diff --git a/soundin.cpp b/soundin.cpp index a7ecbc003..552407c64 100644 --- a/soundin.cpp +++ b/soundin.cpp @@ -103,6 +103,7 @@ void SoundInThread::run() //SoundInThread::run() emit error("PortAudio says requested soundcard format not supported."); // return; } + qDebug() << ""; paerr=Pa_OpenStream(&inStream, //Input stream &inParam, //Input parameters NULL, //No output parameters