mirror of https://github.com/saitohirga/WSJT-X.git
Start implememntation of database based Fox log model and a new Fox log window widget
This change incorporates a reorganization of the GUI code with widgets, validators, models, and item delegates being moved to sub-directories. Relax the requirements of the ForeignKeyDelegate and related CandidateKeyFilter classes to allow them to work with constant model pointers for both referenced and referencing models.
This commit is contained in:
parent
48017c5827
commit
947b429723
116
CMakeLists.txt
116
CMakeLists.txt
|
@ -215,22 +215,22 @@ set (WSJT_QT_CONF_DESTINATION ${QT_CONF_DESTINATION} CACHE PATH "Path for the qt
|
||||||
#
|
#
|
||||||
set (wsjt_qt_CXXSRCS
|
set (wsjt_qt_CXXSRCS
|
||||||
qt_helpers.cpp
|
qt_helpers.cpp
|
||||||
MessageBox.cpp
|
widgets/MessageBox.cpp
|
||||||
MetaDataRegistry.cpp
|
MetaDataRegistry.cpp
|
||||||
NetworkServerLookup.cpp
|
NetworkServerLookup.cpp
|
||||||
revision_utils.cpp
|
revision_utils.cpp
|
||||||
WFPalette.cpp
|
WFPalette.cpp
|
||||||
Radio.cpp
|
Radio.cpp
|
||||||
RadioMetaType.cpp
|
RadioMetaType.cpp
|
||||||
IARURegions.cpp
|
models/IARURegions.cpp
|
||||||
Bands.cpp
|
models/Bands.cpp
|
||||||
Modes.cpp
|
models/Modes.cpp
|
||||||
FrequencyList.cpp
|
models/FrequencyList.cpp
|
||||||
StationList.cpp
|
models/StationList.cpp
|
||||||
FrequencyLineEdit.cpp
|
widgets/FrequencyLineEdit.cpp
|
||||||
CandidateKeyFilter.cpp
|
item_delegates/CandidateKeyFilter.cpp
|
||||||
ForeignKeyDelegate.cpp
|
item_delegates/ForeignKeyDelegate.cpp
|
||||||
LiveFrequencyValidator.cpp
|
validators/LiveFrequencyValidator.cpp
|
||||||
GetUserId.cpp
|
GetUserId.cpp
|
||||||
TraceFile.cpp
|
TraceFile.cpp
|
||||||
AudioDevice.cpp
|
AudioDevice.cpp
|
||||||
|
@ -244,10 +244,10 @@ set (wsjt_qt_CXXSRCS
|
||||||
DXLabSuiteCommanderTransceiver.cpp
|
DXLabSuiteCommanderTransceiver.cpp
|
||||||
NetworkMessage.cpp
|
NetworkMessage.cpp
|
||||||
MessageClient.cpp
|
MessageClient.cpp
|
||||||
LettersSpinBox.cpp
|
widgets/LettersSpinBox.cpp
|
||||||
HintedSpinBox.cpp
|
widgets/HintedSpinBox.cpp
|
||||||
RestrictedSpinBox.cpp
|
widgets/RestrictedSpinBox.cpp
|
||||||
HelpTextWindow.cpp
|
widgets/HelpTextWindow.cpp
|
||||||
SampleDownloader.cpp
|
SampleDownloader.cpp
|
||||||
SampleDownloader/DirectoryDelegate.cpp
|
SampleDownloader/DirectoryDelegate.cpp
|
||||||
SampleDownloader/Directory.cpp
|
SampleDownloader/Directory.cpp
|
||||||
|
@ -255,15 +255,17 @@ set (wsjt_qt_CXXSRCS
|
||||||
SampleDownloader/RemoteFile.cpp
|
SampleDownloader/RemoteFile.cpp
|
||||||
DisplayManual.cpp
|
DisplayManual.cpp
|
||||||
MultiSettings.cpp
|
MultiSettings.cpp
|
||||||
MaidenheadLocatorValidator.cpp
|
validators/MaidenheadLocatorValidator.cpp
|
||||||
CallsignValidator.cpp
|
validators/CallsignValidator.cpp
|
||||||
SplashScreen.cpp
|
widgets/SplashScreen.cpp
|
||||||
EqualizationToolsDialog.cpp
|
EqualizationToolsDialog.cpp
|
||||||
DoubleClickablePushButton.cpp
|
widgets/DoubleClickablePushButton.cpp
|
||||||
DoubleClickableRadioButton.cpp
|
widgets/DoubleClickableRadioButton.cpp
|
||||||
LotWUsers.cpp
|
LotWUsers.cpp
|
||||||
DecodeHighlightingModel.cpp
|
models/DecodeHighlightingModel.cpp
|
||||||
DecodeHighlightingListView.cpp
|
widgets/DecodeHighlightingListView.cpp
|
||||||
|
models/FoxLog.cpp
|
||||||
|
widgets/FoxLogWindow.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
set (wsjt_qtmm_CXXSRCS
|
set (wsjt_qtmm_CXXSRCS
|
||||||
|
@ -286,31 +288,31 @@ set (wsjtx_CXXSRCS
|
||||||
psk_reporter.cpp
|
psk_reporter.cpp
|
||||||
Modulator.cpp
|
Modulator.cpp
|
||||||
Detector.cpp
|
Detector.cpp
|
||||||
logqso.cpp
|
widgets/logqso.cpp
|
||||||
displaytext.cpp
|
widgets/displaytext.cpp
|
||||||
decodedtext.cpp
|
decodedtext.cpp
|
||||||
getfile.cpp
|
getfile.cpp
|
||||||
soundout.cpp
|
soundout.cpp
|
||||||
soundin.cpp
|
soundin.cpp
|
||||||
meterwidget.cpp
|
widgets/meterwidget.cpp
|
||||||
signalmeter.cpp
|
widgets/signalmeter.cpp
|
||||||
plotter.cpp
|
widgets/plotter.cpp
|
||||||
widegraph.cpp
|
widgets/widegraph.cpp
|
||||||
echograph.cpp
|
widgets/echograph.cpp
|
||||||
echoplot.cpp
|
widgets/echoplot.cpp
|
||||||
fastgraph.cpp
|
widgets/fastgraph.cpp
|
||||||
fastplot.cpp
|
widgets/fastplot.cpp
|
||||||
about.cpp
|
widgets/about.cpp
|
||||||
astro.cpp
|
widgets/astro.cpp
|
||||||
messageaveraging.cpp
|
widgets/messageaveraging.cpp
|
||||||
colorhighlighting.cpp
|
widgets/colorhighlighting.cpp
|
||||||
WsprTxScheduler.cpp
|
WsprTxScheduler.cpp
|
||||||
mainwindow.cpp
|
widgets/mainwindow.cpp
|
||||||
Configuration.cpp
|
Configuration.cpp
|
||||||
main.cpp
|
main.cpp
|
||||||
wsprnet.cpp
|
wsprnet.cpp
|
||||||
WSPRBandHopping.cpp
|
WSPRBandHopping.cpp
|
||||||
ExportCabrillo.cpp
|
widgets/ExportCabrillo.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
set (wsjt_CXXSRCS
|
set (wsjt_CXXSRCS
|
||||||
|
@ -612,6 +614,7 @@ set (wsjt_CSRCS
|
||||||
|
|
||||||
set (wsjt_qt_UISRCS
|
set (wsjt_qt_UISRCS
|
||||||
wf_palette_design_dialog.ui
|
wf_palette_design_dialog.ui
|
||||||
|
widgets/FoxLogWindow.ui
|
||||||
)
|
)
|
||||||
|
|
||||||
set (wsprsim_CSRCS
|
set (wsprsim_CSRCS
|
||||||
|
@ -635,17 +638,17 @@ set (wsprd_CSRCS
|
||||||
)
|
)
|
||||||
|
|
||||||
set (wsjtx_UISRCS
|
set (wsjtx_UISRCS
|
||||||
mainwindow.ui
|
widgets/mainwindow.ui
|
||||||
about.ui
|
widgets/about.ui
|
||||||
astro.ui
|
widgets/astro.ui
|
||||||
colorhighlighting.ui
|
widgets/colorhighlighting.ui
|
||||||
echograph.ui
|
widgets/echograph.ui
|
||||||
fastgraph.ui
|
widgets/fastgraph.ui
|
||||||
messageaveraging.ui
|
widgets/messageaveraging.ui
|
||||||
widegraph.ui
|
widgets/widegraph.ui
|
||||||
logqso.ui
|
widgets/logqso.ui
|
||||||
Configuration.ui
|
Configuration.ui
|
||||||
ExportCabrillo.ui
|
widgets/ExportCabrillo.ui
|
||||||
)
|
)
|
||||||
|
|
||||||
set (UDP_library_CXXSRCS
|
set (UDP_library_CXXSRCS
|
||||||
|
@ -667,7 +670,7 @@ set (message_aggregator_CXXSRCS
|
||||||
UDPExamples/DecodesModel.cpp
|
UDPExamples/DecodesModel.cpp
|
||||||
UDPExamples/BeaconsModel.cpp
|
UDPExamples/BeaconsModel.cpp
|
||||||
UDPExamples/ClientWidget.cpp
|
UDPExamples/ClientWidget.cpp
|
||||||
MaidenheadLocatorValidator.cpp
|
validators/MaidenheadLocatorValidator.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
set (message_aggregator_STYLESHEETS
|
set (message_aggregator_STYLESHEETS
|
||||||
|
@ -859,6 +862,7 @@ message (STATUS "hamlib_LIBRARY_DIRS: ${hamlib_LIBRARY_DIRS}")
|
||||||
find_package (Qt5Widgets 5 REQUIRED)
|
find_package (Qt5Widgets 5 REQUIRED)
|
||||||
find_package (Qt5Multimedia 5 REQUIRED)
|
find_package (Qt5Multimedia 5 REQUIRED)
|
||||||
find_package (Qt5PrintSupport 5 REQUIRED)
|
find_package (Qt5PrintSupport 5 REQUIRED)
|
||||||
|
find_package (Qt5Sql 5 REQUIRED)
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
add_definitions (-DQT_NEEDS_QTMAIN)
|
add_definitions (-DQT_NEEDS_QTMAIN)
|
||||||
|
@ -1139,7 +1143,7 @@ target_link_libraries (qcp Qt5::Widgets Qt5::PrintSupport)
|
||||||
add_library (wsjt_qt STATIC ${wsjt_qt_CXXSRCS} ${wsjt_qt_GENUISRCS} ${GENAXSRCS})
|
add_library (wsjt_qt STATIC ${wsjt_qt_CXXSRCS} ${wsjt_qt_GENUISRCS} ${GENAXSRCS})
|
||||||
# set wsjtx_udp exports to static variants
|
# set wsjtx_udp exports to static variants
|
||||||
target_compile_definitions (wsjt_qt PUBLIC UDP_STATIC_DEFINE)
|
target_compile_definitions (wsjt_qt PUBLIC UDP_STATIC_DEFINE)
|
||||||
target_link_libraries (wsjt_qt qcp Qt5::Widgets Qt5::Network)
|
target_link_libraries (wsjt_qt qcp Qt5::Widgets Qt5::Network Qt5::Sql)
|
||||||
target_include_directories (wsjt_qt BEFORE PRIVATE ${hamlib_INCLUDE_DIRS})
|
target_include_directories (wsjt_qt BEFORE PRIVATE ${hamlib_INCLUDE_DIRS})
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
target_link_libraries (wsjt_qt Qt5::AxContainer Qt5::AxBase)
|
target_link_libraries (wsjt_qt Qt5::AxContainer Qt5::AxBase)
|
||||||
|
@ -1547,6 +1551,13 @@ if (NOT is_debug_build)
|
||||||
PATTERN "*quick*${CMAKE_SHARED_LIBRARY_SUFFIX}" EXCLUDE
|
PATTERN "*quick*${CMAKE_SHARED_LIBRARY_SUFFIX}" EXCLUDE
|
||||||
PATTERN "*_debug${CMAKE_SHARED_LIBRARY_SUFFIX}" EXCLUDE
|
PATTERN "*_debug${CMAKE_SHARED_LIBRARY_SUFFIX}" EXCLUDE
|
||||||
)
|
)
|
||||||
|
install (
|
||||||
|
FILES
|
||||||
|
${QT_PLUGINS_DIR}/sqldrivers/libqsqlite${CMAKE_SHARED_LIBRARY_SUFFIX}
|
||||||
|
DESTINATION ${WSJT_PLUGIN_DESTINATION}/sqldrivers
|
||||||
|
CONFIGURATIONS Release MinSizeRel
|
||||||
|
#COMPONENT runtime
|
||||||
|
)
|
||||||
# install (
|
# install (
|
||||||
# DIRECTORY
|
# DIRECTORY
|
||||||
# ${QT_PLUGINS_DIR}/platforms
|
# ${QT_PLUGINS_DIR}/platforms
|
||||||
|
@ -1595,6 +1606,13 @@ if (NOT is_debug_build)
|
||||||
PATTERN "*quick*${CMAKE_SHARED_LIBRARY_SUFFIX}" EXCLUDE
|
PATTERN "*quick*${CMAKE_SHARED_LIBRARY_SUFFIX}" EXCLUDE
|
||||||
PATTERN "*d${CMAKE_SHARED_LIBRARY_SUFFIX}" EXCLUDE
|
PATTERN "*d${CMAKE_SHARED_LIBRARY_SUFFIX}" EXCLUDE
|
||||||
)
|
)
|
||||||
|
install (
|
||||||
|
FILES
|
||||||
|
${QT_PLUGINS_DIR}/sqldrivers/qsqlite${CMAKE_SHARED_LIBRARY_SUFFIX}
|
||||||
|
DESTINATION ${WSJT_PLUGIN_DESTINATION}/sqldrivers
|
||||||
|
CONFIGURATIONS Release MinSizeRel
|
||||||
|
#COMPONENT runtime
|
||||||
|
)
|
||||||
# install (
|
# install (
|
||||||
# DIRECTORY
|
# DIRECTORY
|
||||||
# ${QT_PLUGINS_DIR}/platforms
|
# ${QT_PLUGINS_DIR}/platforms
|
||||||
|
|
|
@ -160,28 +160,30 @@
|
||||||
#include <QFontDialog>
|
#include <QFontDialog>
|
||||||
#include <QSerialPortInfo>
|
#include <QSerialPortInfo>
|
||||||
#include <QScopedPointer>
|
#include <QScopedPointer>
|
||||||
|
#include <QSqlDatabase>
|
||||||
|
#include <QSqlError>
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
#include "pimpl_impl.hpp"
|
#include "pimpl_impl.hpp"
|
||||||
#include "qt_helpers.hpp"
|
#include "qt_helpers.hpp"
|
||||||
#include "MetaDataRegistry.hpp"
|
#include "MetaDataRegistry.hpp"
|
||||||
#include "SettingsGroup.hpp"
|
#include "SettingsGroup.hpp"
|
||||||
#include "FrequencyLineEdit.hpp"
|
#include "widgets/FrequencyLineEdit.hpp"
|
||||||
#include "CandidateKeyFilter.hpp"
|
#include "item_delegates/CandidateKeyFilter.hpp"
|
||||||
#include "ForeignKeyDelegate.hpp"
|
#include "item_delegates/ForeignKeyDelegate.hpp"
|
||||||
#include "TransceiverFactory.hpp"
|
#include "TransceiverFactory.hpp"
|
||||||
#include "Transceiver.hpp"
|
#include "Transceiver.hpp"
|
||||||
#include "Bands.hpp"
|
#include "models/Bands.hpp"
|
||||||
#include "IARURegions.hpp"
|
#include "models/IARURegions.hpp"
|
||||||
#include "Modes.hpp"
|
#include "models/Modes.hpp"
|
||||||
#include "FrequencyList.hpp"
|
#include "models/FrequencyList.hpp"
|
||||||
#include "StationList.hpp"
|
#include "models/StationList.hpp"
|
||||||
#include "NetworkServerLookup.hpp"
|
#include "NetworkServerLookup.hpp"
|
||||||
#include "MessageBox.hpp"
|
#include "widgets/MessageBox.hpp"
|
||||||
#include "MaidenheadLocatorValidator.hpp"
|
#include "validators/MaidenheadLocatorValidator.hpp"
|
||||||
#include "CallsignValidator.hpp"
|
#include "validators/CallsignValidator.hpp"
|
||||||
#include "LotWUsers.hpp"
|
#include "LotWUsers.hpp"
|
||||||
#include "DecodeHighlightingModel.hpp"
|
#include "models/DecodeHighlightingModel.hpp"
|
||||||
|
|
||||||
#include "ui_Configuration.h"
|
#include "ui_Configuration.h"
|
||||||
#include "moc_Configuration.cpp"
|
#include "moc_Configuration.cpp"
|
||||||
|
@ -1000,6 +1002,18 @@ Configuration::impl::impl (Configuration * self, QNetworkAccessManager * network
|
||||||
// this must be done after the default paths above are set
|
// this must be done after the default paths above are set
|
||||||
read_settings ();
|
read_settings ();
|
||||||
|
|
||||||
|
// set up SQLite database
|
||||||
|
if (!QSqlDatabase::drivers ().contains ("QSQLITE"))
|
||||||
|
{
|
||||||
|
throw std::runtime_error {"Failed to find SQLite Qt driver"};
|
||||||
|
}
|
||||||
|
auto db = QSqlDatabase::addDatabase ("QSQLITE");
|
||||||
|
db.setDatabaseName (writeable_data_dir_.absoluteFilePath ("db.sqlite"));
|
||||||
|
if (!db.open ())
|
||||||
|
{
|
||||||
|
throw std::runtime_error {("Database Error: " + db.lastError ().text ()).toStdString ()};
|
||||||
|
}
|
||||||
|
|
||||||
// conditionally load LotW users data
|
// conditionally load LotW users data
|
||||||
ui_->LotW_CSV_fetch_push_button->setEnabled (false);
|
ui_->LotW_CSV_fetch_push_button->setEnabled (false);
|
||||||
connect (&lotw_users_, &LotWUsers::load_finished, [this] () {
|
connect (&lotw_users_, &LotWUsers::load_finished, [this] () {
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
#include <QFont>
|
#include <QFont>
|
||||||
|
|
||||||
#include "Radio.hpp"
|
#include "Radio.hpp"
|
||||||
#include "IARURegions.hpp"
|
#include "models/IARURegions.hpp"
|
||||||
#include "AudioDevice.hpp"
|
#include "AudioDevice.hpp"
|
||||||
#include "Transceiver.hpp"
|
#include "Transceiver.hpp"
|
||||||
|
|
||||||
|
|
|
@ -2,14 +2,6 @@
|
||||||
<ui version="4.0">
|
<ui version="4.0">
|
||||||
<class>configuration_dialog</class>
|
<class>configuration_dialog</class>
|
||||||
<widget class="QDialog" name="configuration_dialog">
|
<widget class="QDialog" name="configuration_dialog">
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>0</x>
|
|
||||||
<y>0</y>
|
|
||||||
<width>679</width>
|
|
||||||
<height>619</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>Settings</string>
|
<string>Settings</string>
|
||||||
</property>
|
</property>
|
||||||
|
@ -2832,7 +2824,7 @@ Right click for insert and delete options.</string>
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>DecodeHighlightingListView</class>
|
<class>DecodeHighlightingListView</class>
|
||||||
<extends>QListView</extends>
|
<extends>QListView</extends>
|
||||||
<header>DecodeHighlightingListView.hpp</header>
|
<header>widgets/DecodeHighlightingListView.hpp</header>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
</customwidgets>
|
</customwidgets>
|
||||||
<tabstops>
|
<tabstops>
|
||||||
|
|
|
@ -5,16 +5,16 @@
|
||||||
#include <QStandardItemEditorCreator>
|
#include <QStandardItemEditorCreator>
|
||||||
|
|
||||||
#include "Radio.hpp"
|
#include "Radio.hpp"
|
||||||
#include "FrequencyList.hpp"
|
#include "models/FrequencyList.hpp"
|
||||||
#include "AudioDevice.hpp"
|
#include "AudioDevice.hpp"
|
||||||
#include "Configuration.hpp"
|
#include "Configuration.hpp"
|
||||||
#include "StationList.hpp"
|
#include "models/StationList.hpp"
|
||||||
#include "Transceiver.hpp"
|
#include "Transceiver.hpp"
|
||||||
#include "TransceiverFactory.hpp"
|
#include "TransceiverFactory.hpp"
|
||||||
#include "WFPalette.hpp"
|
#include "WFPalette.hpp"
|
||||||
#include "IARURegions.hpp"
|
#include "models/IARURegions.hpp"
|
||||||
#include "DecodeHighlightingModel.hpp"
|
#include "models/DecodeHighlightingModel.hpp"
|
||||||
#include "FrequencyLineEdit.hpp"
|
#include "widgets/FrequencyLineEdit.hpp"
|
||||||
|
|
||||||
QItemEditorFactory * item_editor_factory ()
|
QItemEditorFactory * item_editor_factory ()
|
||||||
{
|
{
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
#include <qmath.h>
|
#include <qmath.h>
|
||||||
#include <QDateTime>
|
#include <QDateTime>
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
#include "mainwindow.h"
|
#include "widgets/mainwindow.h" // TODO: G4WJS - break this dependency
|
||||||
#include "soundout.h"
|
#include "soundout.h"
|
||||||
#include "commons.h"
|
#include "commons.h"
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,7 @@
|
||||||
#include "SettingsGroup.hpp"
|
#include "SettingsGroup.hpp"
|
||||||
#include "qt_helpers.hpp"
|
#include "qt_helpers.hpp"
|
||||||
#include "SettingsGroup.hpp"
|
#include "SettingsGroup.hpp"
|
||||||
#include "MessageBox.hpp"
|
#include "widgets/MessageBox.hpp"
|
||||||
|
|
||||||
#include "pimpl_impl.hpp"
|
#include "pimpl_impl.hpp"
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
#include <QNetworkReply>
|
#include <QNetworkReply>
|
||||||
#include <QString>
|
#include <QString>
|
||||||
|
|
||||||
#include "MessageBox.hpp"
|
#include "widgets/MessageBox.hpp"
|
||||||
|
|
||||||
class QNetworkRequest;
|
class QNetworkRequest;
|
||||||
class QIODevice;
|
class QIODevice;
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
#include "pimpl_impl.hpp"
|
#include "pimpl_impl.hpp"
|
||||||
#include "SettingsGroup.hpp"
|
#include "SettingsGroup.hpp"
|
||||||
#include "SampleDownloader/Directory.hpp"
|
#include "SampleDownloader/Directory.hpp"
|
||||||
#include "MessageBox.hpp"
|
#include "widgets/MessageBox.hpp"
|
||||||
|
|
||||||
#include "moc_SampleDownloader.cpp"
|
#include "moc_SampleDownloader.cpp"
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,7 @@
|
||||||
#include "DirectoryNode.hpp"
|
#include "DirectoryNode.hpp"
|
||||||
#include "FileNode.hpp"
|
#include "FileNode.hpp"
|
||||||
#include "revision_utils.hpp"
|
#include "revision_utils.hpp"
|
||||||
#include "MessageBox.hpp"
|
#include "widgets/MessageBox.hpp"
|
||||||
|
|
||||||
#include "moc_Directory.cpp"
|
#include "moc_Directory.cpp"
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
#include <QFileInfo>
|
#include <QFileInfo>
|
||||||
|
|
||||||
#include "Directory.hpp"
|
#include "Directory.hpp"
|
||||||
#include "MessageBox.hpp"
|
#include "widgets/MessageBox.hpp"
|
||||||
|
|
||||||
FileNode::FileNode (QTreeWidgetItem * parent
|
FileNode::FileNode (QTreeWidgetItem * parent
|
||||||
, QNetworkAccessManager * network_manager
|
, QNetworkAccessManager * network_manager
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
#include <QRegExp>
|
#include <QRegExp>
|
||||||
#include <QColor>
|
#include <QColor>
|
||||||
|
|
||||||
#include "MaidenheadLocatorValidator.hpp"
|
#include "validators/MaidenheadLocatorValidator.hpp"
|
||||||
|
|
||||||
namespace
|
namespace
|
||||||
{
|
{
|
||||||
|
|
|
@ -11,8 +11,8 @@
|
||||||
|
|
||||||
#include "SettingsGroup.hpp"
|
#include "SettingsGroup.hpp"
|
||||||
#include "Configuration.hpp"
|
#include "Configuration.hpp"
|
||||||
#include "Bands.hpp"
|
#include "models/Bands.hpp"
|
||||||
#include "FrequencyList.hpp"
|
#include "models/FrequencyList.hpp"
|
||||||
#include "WsprTxScheduler.h"
|
#include "WsprTxScheduler.h"
|
||||||
#include "pimpl_impl.hpp"
|
#include "pimpl_impl.hpp"
|
||||||
#include "moc_WSPRBandHopping.cpp"
|
#include "moc_WSPRBandHopping.cpp"
|
||||||
|
|
|
@ -29,17 +29,17 @@ public:
|
||||||
QModelIndex active_key_;
|
QModelIndex active_key_;
|
||||||
};
|
};
|
||||||
|
|
||||||
CandidateKeyFilter::CandidateKeyFilter (QAbstractItemModel * referenced_model
|
CandidateKeyFilter::CandidateKeyFilter (QAbstractItemModel const * referenced_model
|
||||||
, int referenced_key_column
|
, int referenced_key_column
|
||||||
, QObject * parent
|
, QObject * parent
|
||||||
, int referenced_key_role)
|
, int referenced_key_role)
|
||||||
: QSortFilterProxyModel {parent}
|
: QSortFilterProxyModel {parent}
|
||||||
, m_ {referenced_key_column, referenced_key_role, nullptr, 0, Qt::EditRole}
|
, m_ {referenced_key_column, referenced_key_role, nullptr, 0, Qt::EditRole}
|
||||||
{
|
{
|
||||||
setSourceModel (referenced_model);
|
setSourceModel (const_cast<QAbstractItemModel *> (referenced_model));
|
||||||
}
|
}
|
||||||
|
|
||||||
CandidateKeyFilter::CandidateKeyFilter (QAbstractItemModel * referenced_model
|
CandidateKeyFilter::CandidateKeyFilter (QAbstractItemModel const * referenced_model
|
||||||
, QAbstractItemModel const * referencing_model
|
, QAbstractItemModel const * referencing_model
|
||||||
, int referenced_key_column
|
, int referenced_key_column
|
||||||
, int referencing_key_column
|
, int referencing_key_column
|
||||||
|
@ -49,7 +49,7 @@ CandidateKeyFilter::CandidateKeyFilter (QAbstractItemModel * referenced_model
|
||||||
: QSortFilterProxyModel {parent}
|
: QSortFilterProxyModel {parent}
|
||||||
, m_ {referenced_key_column, referenced_key_role, referencing_model, referencing_key_column, referencing_key_role}
|
, m_ {referenced_key_column, referenced_key_role, referencing_model, referencing_key_column, referencing_key_role}
|
||||||
{
|
{
|
||||||
setSourceModel (referenced_model);
|
setSourceModel (const_cast<QAbstractItemModel *> (referenced_model));
|
||||||
}
|
}
|
||||||
|
|
||||||
CandidateKeyFilter::~CandidateKeyFilter ()
|
CandidateKeyFilter::~CandidateKeyFilter ()
|
|
@ -12,11 +12,11 @@ class CandidateKeyFilter final
|
||||||
: public QSortFilterProxyModel
|
: public QSortFilterProxyModel
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
explicit CandidateKeyFilter (QAbstractItemModel * referenced_model
|
explicit CandidateKeyFilter (QAbstractItemModel const * referenced_model
|
||||||
, int referenced_key_column
|
, int referenced_key_column
|
||||||
, QObject * parent = nullptr
|
, QObject * parent = nullptr
|
||||||
, int referenced_key_role = Qt::EditRole);
|
, int referenced_key_role = Qt::EditRole);
|
||||||
explicit CandidateKeyFilter (QAbstractItemModel * referenced_model
|
explicit CandidateKeyFilter (QAbstractItemModel const * referenced_model
|
||||||
, QAbstractItemModel const * referencing_model
|
, QAbstractItemModel const * referencing_model
|
||||||
, int referenced_key_column
|
, int referenced_key_column
|
||||||
, int referencing_key_column
|
, int referencing_key_column
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
#include "CandidateKeyFilter.hpp"
|
#include "CandidateKeyFilter.hpp"
|
||||||
|
|
||||||
ForeignKeyDelegate::ForeignKeyDelegate (QAbstractItemModel * referenced_model
|
ForeignKeyDelegate::ForeignKeyDelegate (QAbstractItemModel const * referenced_model
|
||||||
, int referenced_key_column
|
, int referenced_key_column
|
||||||
, QObject * parent
|
, QObject * parent
|
||||||
, int referenced_key_role)
|
, int referenced_key_role)
|
||||||
|
@ -13,7 +13,7 @@ ForeignKeyDelegate::ForeignKeyDelegate (QAbstractItemModel * referenced_model
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
ForeignKeyDelegate::ForeignKeyDelegate (QAbstractItemModel * referenced_model
|
ForeignKeyDelegate::ForeignKeyDelegate (QAbstractItemModel const * referenced_model
|
||||||
, QAbstractItemModel const * referencing_model
|
, QAbstractItemModel const * referencing_model
|
||||||
, int referenced_key_column
|
, int referenced_key_column
|
||||||
, int referencing_key_column
|
, int referencing_key_column
|
|
@ -18,13 +18,13 @@ class ForeignKeyDelegate final
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
// many to many relationship
|
// many to many relationship
|
||||||
explicit ForeignKeyDelegate (QAbstractItemModel * referenced_model
|
explicit ForeignKeyDelegate (QAbstractItemModel const * referenced_model
|
||||||
, int referenced_key_column
|
, int referenced_key_column
|
||||||
, QObject * parent = nullptr
|
, QObject * parent = nullptr
|
||||||
, int referenced_key_role = Qt::EditRole);
|
, int referenced_key_role = Qt::EditRole);
|
||||||
|
|
||||||
// one to many (referenced to referencing) relationship
|
// one to many (referenced to referencing) relationship
|
||||||
explicit ForeignKeyDelegate (QAbstractItemModel * referenced_model
|
explicit ForeignKeyDelegate (QAbstractItemModel const * referenced_model
|
||||||
, QAbstractItemModel const * referencing_model
|
, QAbstractItemModel const * referencing_model
|
||||||
, int referenced_key_column
|
, int referenced_key_column
|
||||||
, int referencing_key_column
|
, int referencing_key_column
|
9
main.cpp
9
main.cpp
|
@ -18,7 +18,6 @@
|
||||||
#include <QStringList>
|
#include <QStringList>
|
||||||
#include <QLockFile>
|
#include <QLockFile>
|
||||||
#include <QSplashScreen>
|
#include <QSplashScreen>
|
||||||
|
|
||||||
#include <QCommandLineParser>
|
#include <QCommandLineParser>
|
||||||
#include <QCommandLineOption>
|
#include <QCommandLineOption>
|
||||||
|
|
||||||
|
@ -27,13 +26,13 @@
|
||||||
#include "SettingsGroup.hpp"
|
#include "SettingsGroup.hpp"
|
||||||
#include "TraceFile.hpp"
|
#include "TraceFile.hpp"
|
||||||
#include "MultiSettings.hpp"
|
#include "MultiSettings.hpp"
|
||||||
#include "mainwindow.h"
|
#include "widgets/mainwindow.h"
|
||||||
#include "commons.h"
|
#include "commons.h"
|
||||||
#include "lib/init_random_seed.h"
|
#include "lib/init_random_seed.h"
|
||||||
#include "Radio.hpp"
|
#include "Radio.hpp"
|
||||||
#include "FrequencyList.hpp"
|
#include "models/FrequencyList.hpp"
|
||||||
#include "SplashScreen.hpp"
|
#include "widgets/SplashScreen.hpp"
|
||||||
#include "MessageBox.hpp" // last to avoid nasty MS macro definitions
|
#include "widgets/MessageBox.hpp" // last to avoid nasty MS macro definitions
|
||||||
|
|
||||||
extern "C" {
|
extern "C" {
|
||||||
// Fortran procedures we need
|
// Fortran procedures we need
|
||||||
|
|
|
@ -0,0 +1,94 @@
|
||||||
|
#include "FoxLog.hpp"
|
||||||
|
|
||||||
|
#include <String>
|
||||||
|
#include <QDateTime>
|
||||||
|
#include <QSqlDatabase>
|
||||||
|
#include <QSqlTableModel>
|
||||||
|
#include <QSqlRecord>
|
||||||
|
#include <QSqlError>
|
||||||
|
#include <QSqlQuery>
|
||||||
|
#include <QDebug>
|
||||||
|
#include "pimpl_impl.hpp"
|
||||||
|
|
||||||
|
class FoxLog::impl final
|
||||||
|
: public QSqlTableModel
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
impl ();
|
||||||
|
QSqlQuery insert_;
|
||||||
|
};
|
||||||
|
|
||||||
|
FoxLog::impl::impl ()
|
||||||
|
{
|
||||||
|
if (!database ().tables ().contains ("fox_log"))
|
||||||
|
{
|
||||||
|
QSqlQuery query;
|
||||||
|
if (!query.exec ("CREATE TABLE fox_log ("
|
||||||
|
" id INTEGER PRIMARY KEY AUTOINCREMENT,"
|
||||||
|
" \"when\" DATETIME NOT NULL,"
|
||||||
|
" call VARCHAR(20) NOT NULL,"
|
||||||
|
" grid VARCHAR(4),"
|
||||||
|
" report_sent VARCHAR(3),"
|
||||||
|
" report_rcvd VARCHAR(3),"
|
||||||
|
" band VARCHAR(6) NOT NULL,"
|
||||||
|
" CONSTRAINT no_dupes UNIQUE (call, band)"
|
||||||
|
")"))
|
||||||
|
{
|
||||||
|
throw std::runtime_error {("SQL Error: " + query.lastError ().text ()).toStdString ()};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
setEditStrategy (QSqlTableModel::OnRowChange);
|
||||||
|
setTable ("fox_log");
|
||||||
|
setHeaderData (fieldIndex ("when"), Qt::Horizontal, tr ("Date and Time"));
|
||||||
|
setHeaderData (fieldIndex ("call"), Qt::Horizontal, tr ("Call"));
|
||||||
|
setHeaderData (fieldIndex ("grid"), Qt::Horizontal, tr ("Grid"));
|
||||||
|
setHeaderData (fieldIndex ("report_sent"), Qt::Horizontal, tr ("Sent"));
|
||||||
|
setHeaderData (fieldIndex ("report_rcvd"), Qt::Horizontal, tr ("Rcvd"));
|
||||||
|
setHeaderData (fieldIndex ("band"), Qt::Horizontal, tr ("Band"));
|
||||||
|
if (!select ())
|
||||||
|
{
|
||||||
|
throw std::runtime_error {("SQL Error: " + lastError ().text ()).toStdString ()};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
FoxLog::FoxLog ()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
FoxLog::~FoxLog ()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
QAbstractItemModel * FoxLog::model ()
|
||||||
|
{
|
||||||
|
return &*m_;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool FoxLog::add_QSO (QDateTime const& when, QString const& call, QString const& grid
|
||||||
|
, QString const& report_received, QString const& report_sent
|
||||||
|
, QString const& band)
|
||||||
|
{
|
||||||
|
auto db = m_->database ();
|
||||||
|
auto record = m_->record ();
|
||||||
|
record.setValue ("when", when.toMSecsSinceEpoch () / 1000);
|
||||||
|
record.setValue ("call", call);
|
||||||
|
record.setValue ("grid", grid);
|
||||||
|
record.setValue ("report_sent", report_sent);
|
||||||
|
record.setValue ("report_rcvd", report_received);
|
||||||
|
record.setValue ("band", band);
|
||||||
|
if (!m_->insertRecord (-1, record))
|
||||||
|
{
|
||||||
|
throw std::runtime_error {("SQL Error: " + m_->lastError ().text ()).toStdString ()};
|
||||||
|
}
|
||||||
|
if (!m_->submitAll ())
|
||||||
|
{
|
||||||
|
qDebug () << "type:" << m_->lastError ().type ();
|
||||||
|
if (QSqlError::TransactionError == m_->lastError ().type ())
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
throw std::runtime_error {("SQL Error: " + m_->lastError ().text ()).toStdString ()};
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
|
@ -0,0 +1,30 @@
|
||||||
|
#ifndef FOX_LOG_HPP_
|
||||||
|
#define FOX_LOG_HPP_
|
||||||
|
|
||||||
|
#include <boost/core/noncopyable.hpp>
|
||||||
|
#include "pimpl_h.hpp"
|
||||||
|
|
||||||
|
class QDateTime;
|
||||||
|
class QString;
|
||||||
|
class QAbstractItemModel;
|
||||||
|
|
||||||
|
class FoxLog final
|
||||||
|
: private boost::noncopyable
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
explicit FoxLog ();
|
||||||
|
~FoxLog ();
|
||||||
|
|
||||||
|
// returns false if insert fails, dupe call+band
|
||||||
|
bool add_QSO (QDateTime const&, QString const& call, QString const& grid
|
||||||
|
, QString const& report_received, QString const& report_sent
|
||||||
|
, QString const& band);
|
||||||
|
|
||||||
|
QAbstractItemModel * model ();
|
||||||
|
|
||||||
|
private:
|
||||||
|
class impl;
|
||||||
|
pimpl<impl> m_;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif
|
|
@ -1,4 +1,4 @@
|
||||||
#include "IARURegions.hpp"
|
#include "models/IARURegions.hpp"
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
|
|
@ -5,8 +5,8 @@
|
||||||
#include <QComboBox>
|
#include <QComboBox>
|
||||||
#include <QLineEdit>
|
#include <QLineEdit>
|
||||||
|
|
||||||
#include "Bands.hpp"
|
#include "models/Bands.hpp"
|
||||||
#include "FrequencyList.hpp"
|
#include "models/FrequencyList.hpp"
|
||||||
|
|
||||||
#include "moc_LiveFrequencyValidator.cpp"
|
#include "moc_LiveFrequencyValidator.cpp"
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
#include <QColorDialog>
|
#include <QColorDialog>
|
||||||
|
|
||||||
#include "DecodeHighlightingModel.hpp"
|
#include "models/DecodeHighlightingModel.hpp"
|
||||||
#include "MessageBox.hpp"
|
#include "MessageBox.hpp"
|
||||||
|
|
||||||
#include "pimpl_impl.hpp"
|
#include "pimpl_impl.hpp"
|
|
@ -0,0 +1,148 @@
|
||||||
|
#include "FoxLogWindow.hpp"
|
||||||
|
|
||||||
|
#include <QSettings>
|
||||||
|
#include <QApplication>
|
||||||
|
#include <QDateTime>
|
||||||
|
#include <QDir>
|
||||||
|
#include <QStyledItemDelegate>
|
||||||
|
#include <QDateTimeEdit>
|
||||||
|
#include <QPainter>
|
||||||
|
|
||||||
|
#include "SettingsGroup.hpp"
|
||||||
|
#include "Configuration.hpp"
|
||||||
|
#include "models/Bands.hpp"
|
||||||
|
#include "item_delegates/ForeignKeyDelegate.hpp"
|
||||||
|
#include "widgets/MessageBox.hpp"
|
||||||
|
#include "qt_helpers.hpp"
|
||||||
|
|
||||||
|
#include "ui_FoxLogWindow.h"
|
||||||
|
|
||||||
|
namespace
|
||||||
|
{
|
||||||
|
class DateTimeAsSecsSinceEpochItemDelegate final
|
||||||
|
: public QStyledItemDelegate
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
DateTimeAsSecsSinceEpochItemDelegate (QObject * parent = nullptr)
|
||||||
|
: QStyledItemDelegate {parent}
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
static QVariant to_secs_since_epoch (QDateTime const& date_time)
|
||||||
|
{
|
||||||
|
return date_time.toMSecsSinceEpoch () / 1000;
|
||||||
|
}
|
||||||
|
|
||||||
|
static QDateTime to_date_time (QModelIndex const& index, int role = Qt::DisplayRole)
|
||||||
|
{
|
||||||
|
return to_date_time (index.model ()->data (index, role));
|
||||||
|
}
|
||||||
|
|
||||||
|
static QDateTime to_date_time (QVariant const& value)
|
||||||
|
{
|
||||||
|
return QDateTime::fromMSecsSinceEpoch (value.toULongLong () * 1000);
|
||||||
|
}
|
||||||
|
|
||||||
|
QString displayText (QVariant const& value, QLocale const& locale) const override
|
||||||
|
{
|
||||||
|
return locale.toString (to_date_time (value), QLocale::ShortFormat);
|
||||||
|
}
|
||||||
|
|
||||||
|
QWidget * createEditor (QWidget * parent, QStyleOptionViewItem const& /*option*/, QModelIndex const& /*index*/) const override
|
||||||
|
{
|
||||||
|
return new QDateTimeEdit {parent};
|
||||||
|
}
|
||||||
|
|
||||||
|
void setEditorData (QWidget * editor, QModelIndex const& index) const override
|
||||||
|
{
|
||||||
|
static_cast<QDateTimeEdit *> (editor)->setDateTime (to_date_time (index, Qt::EditRole));
|
||||||
|
}
|
||||||
|
|
||||||
|
void setModelData (QWidget * editor, QAbstractItemModel * model, QModelIndex const& index) const override
|
||||||
|
{
|
||||||
|
model->setData (index, to_secs_since_epoch (static_cast<QDateTimeEdit *> (editor)->dateTime ()));
|
||||||
|
}
|
||||||
|
|
||||||
|
void updateEditorGeometry (QWidget * editor, QStyleOptionViewItem const& option, QModelIndex const& /*index*/) const override
|
||||||
|
{
|
||||||
|
editor->setGeometry (option.rect);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
FoxLogWindow::FoxLogWindow (QSettings * settings, Configuration const * configuration
|
||||||
|
, QAbstractItemModel * fox_log_model, QWidget * parent)
|
||||||
|
: QWidget {parent}
|
||||||
|
, settings_ {settings}
|
||||||
|
, configuration_ {configuration}
|
||||||
|
, ui_ {new Ui::FoxLogWindow}
|
||||||
|
{
|
||||||
|
fox_log_model_.setSourceModel (fox_log_model);
|
||||||
|
setWindowTitle (QApplication::applicationName () + " - Fox Log");
|
||||||
|
ui_->setupUi (this);
|
||||||
|
read_settings ();
|
||||||
|
change_font (configuration_->decoded_text_font ());
|
||||||
|
ui_->log_table_view->setModel (&fox_log_model_);
|
||||||
|
ui_->log_table_view->setColumnHidden (0, true);
|
||||||
|
ui_->log_table_view->setItemDelegateForColumn (1, new DateTimeAsSecsSinceEpochItemDelegate {this});
|
||||||
|
ui_->log_table_view->setItemDelegateForColumn (6, new ForeignKeyDelegate {configuration_->bands (), &fox_log_model_, 0, 6, this});
|
||||||
|
ui_->log_table_view->setSelectionMode (QTableView::SingleSelection);
|
||||||
|
ui_->log_table_view->resizeColumnsToContents ();
|
||||||
|
ui_->rate_label->setNum (0);
|
||||||
|
ui_->queued_label->setNum (0);
|
||||||
|
ui_->callers_label->setNum (0);
|
||||||
|
connect (&fox_log_model_, &QAbstractItemModel::rowsInserted, [this] (QModelIndex const& parent, int first, int /*last*/) {
|
||||||
|
ui_->log_table_view->scrollTo (fox_log_model_.index (first, 0, parent));
|
||||||
|
ui_->log_table_view->resizeColumnsToContents ();
|
||||||
|
// ui_->log_table_view->scrollToBottom ();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
FoxLogWindow::~FoxLogWindow ()
|
||||||
|
{
|
||||||
|
if (isVisible ())
|
||||||
|
{
|
||||||
|
write_settings ();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void FoxLogWindow::closeEvent (QCloseEvent * e)
|
||||||
|
{
|
||||||
|
write_settings ();
|
||||||
|
QWidget::closeEvent (e);
|
||||||
|
}
|
||||||
|
|
||||||
|
void FoxLogWindow::read_settings ()
|
||||||
|
{
|
||||||
|
SettingsGroup g {settings_, "Fox Log Window"};
|
||||||
|
restoreGeometry (settings_->value ("window/geometery").toByteArray ());
|
||||||
|
}
|
||||||
|
|
||||||
|
void FoxLogWindow::write_settings () const
|
||||||
|
{
|
||||||
|
SettingsGroup g {settings_, "Fox Log Window"};
|
||||||
|
settings_->setValue ("window/geometery", saveGeometry ());
|
||||||
|
}
|
||||||
|
|
||||||
|
void FoxLogWindow::change_font (QFont const& font)
|
||||||
|
{
|
||||||
|
// ui_->log_table_view->setFont (font);
|
||||||
|
// ui_->log_table_view->horizontalHeader ()->setFont (font);
|
||||||
|
// ui_->log_table_view->verticalHeader ()->setFont (font);
|
||||||
|
fox_log_model_.set_font (font);
|
||||||
|
}
|
||||||
|
|
||||||
|
void FoxLogWindow::callers (int n)
|
||||||
|
{
|
||||||
|
ui_->callers_label->setNum (n);
|
||||||
|
}
|
||||||
|
|
||||||
|
void FoxLogWindow::queued (int n)
|
||||||
|
{
|
||||||
|
ui_->queued_label->setNum (n);
|
||||||
|
}
|
||||||
|
|
||||||
|
void FoxLogWindow::rate (int n)
|
||||||
|
{
|
||||||
|
ui_->rate_label->setNum (n);
|
||||||
|
}
|
|
@ -0,0 +1,65 @@
|
||||||
|
#ifndef FOX_LOG_WINDOW_HPP_
|
||||||
|
#define FOX_LOG_WINDOW_HPP_
|
||||||
|
|
||||||
|
#include <QWidget>
|
||||||
|
#include <QScopedPointer>
|
||||||
|
#include <QIdentityProxyModel>
|
||||||
|
|
||||||
|
class QSettings;
|
||||||
|
class Configuration;
|
||||||
|
class QFont;
|
||||||
|
class QDateTime;
|
||||||
|
class QAbstractItemModel;
|
||||||
|
namespace Ui
|
||||||
|
{
|
||||||
|
class FoxLogWindow;
|
||||||
|
}
|
||||||
|
|
||||||
|
// fix up font display as header font changes don't currently work
|
||||||
|
// from views (I think fixed in Qt 5.11.1)
|
||||||
|
class FontOverrideModel final
|
||||||
|
: public QIdentityProxyModel
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
FontOverrideModel (QObject * parent = nullptr) : QIdentityProxyModel {parent} {}
|
||||||
|
void set_font (QFont const& font) {font_ = font;}
|
||||||
|
QVariant data (QModelIndex const& index, int role) const override
|
||||||
|
{
|
||||||
|
if (Qt::FontRole == role) return font_;
|
||||||
|
return QIdentityProxyModel::data (index, role);
|
||||||
|
}
|
||||||
|
QVariant headerData (int section, Qt::Orientation orientation, int role) const override
|
||||||
|
{
|
||||||
|
if (Qt::FontRole == role) return font_;
|
||||||
|
return QIdentityProxyModel::headerData (section, orientation, role);
|
||||||
|
}
|
||||||
|
private:
|
||||||
|
QFont font_;
|
||||||
|
};
|
||||||
|
|
||||||
|
class FoxLogWindow final
|
||||||
|
: public QWidget
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
explicit FoxLogWindow (QSettings *, Configuration const *, QAbstractItemModel * fox_log_model
|
||||||
|
, QWidget * parent = nullptr);
|
||||||
|
~FoxLogWindow ();
|
||||||
|
|
||||||
|
void change_font (QFont const&);
|
||||||
|
void callers (int);
|
||||||
|
void queued (int);
|
||||||
|
void rate (int);
|
||||||
|
|
||||||
|
private:
|
||||||
|
void closeEvent (QCloseEvent *) override;
|
||||||
|
|
||||||
|
void read_settings ();
|
||||||
|
void write_settings () const;
|
||||||
|
|
||||||
|
QSettings * settings_;
|
||||||
|
Configuration const * configuration_;
|
||||||
|
FontOverrideModel fox_log_model_;
|
||||||
|
QScopedPointer<Ui::FoxLogWindow> ui_;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif
|
|
@ -0,0 +1,109 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ui version="4.0">
|
||||||
|
<class>FoxLogWindow</class>
|
||||||
|
<widget class="QWidget" name="FoxLogWindow">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>400</width>
|
||||||
|
<height>300</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>Fox Log</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
|
<item>
|
||||||
|
<widget class="QTableView" name="log_table_view"/>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||||
|
<item>
|
||||||
|
<spacer name="horizontalSpacer_2">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>40</width>
|
||||||
|
<height>20</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label">
|
||||||
|
<property name="text">
|
||||||
|
<string>Callers:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="callers_label">
|
||||||
|
<property name="text">
|
||||||
|
<string>N</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_2">
|
||||||
|
<property name="text">
|
||||||
|
<string>In progress:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="queued_label">
|
||||||
|
<property name="text">
|
||||||
|
<string>N</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<spacer name="horizontalSpacer">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>40</width>
|
||||||
|
<height>20</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_4">
|
||||||
|
<property name="text">
|
||||||
|
<string>Rate:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="rate_label">
|
||||||
|
<property name="text">
|
||||||
|
<string>N</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<spacer name="horizontalSpacer_3">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>40</width>
|
||||||
|
<height>20</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
<resources/>
|
||||||
|
<connections/>
|
||||||
|
</ui>
|
|
@ -1,45 +1,45 @@
|
||||||
#ifndef FREQUENCY_LINE_EDIT_HPP_
|
#ifndef FREQUENCY_LINE_EDIT_HPP_
|
||||||
#define FREQUENCY_LINE_EDIT_HPP_
|
#define FREQUENCY_LINE_EDIT_HPP_
|
||||||
|
|
||||||
#include <QLineEdit>
|
#include <QLineEdit>
|
||||||
|
|
||||||
#include "Radio.hpp"
|
#include "Radio.hpp"
|
||||||
|
|
||||||
class QWidget;
|
class QWidget;
|
||||||
|
|
||||||
//
|
//
|
||||||
// MHz frequency line edits with validation
|
// MHz frequency line edits with validation
|
||||||
//
|
//
|
||||||
class FrequencyLineEdit final
|
class FrequencyLineEdit final
|
||||||
: public QLineEdit
|
: public QLineEdit
|
||||||
{
|
{
|
||||||
Q_OBJECT;
|
Q_OBJECT;
|
||||||
Q_PROPERTY (Frequency frequency READ frequency WRITE frequency USER true);
|
Q_PROPERTY (Frequency frequency READ frequency WRITE frequency USER true);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
using Frequency = Radio::Frequency;
|
using Frequency = Radio::Frequency;
|
||||||
|
|
||||||
explicit FrequencyLineEdit (QWidget * parent = nullptr);
|
explicit FrequencyLineEdit (QWidget * parent = nullptr);
|
||||||
|
|
||||||
// Property frequency implementation
|
// Property frequency implementation
|
||||||
Frequency frequency () const;
|
Frequency frequency () const;
|
||||||
void frequency (Frequency);
|
void frequency (Frequency);
|
||||||
};
|
};
|
||||||
|
|
||||||
class FrequencyDeltaLineEdit final
|
class FrequencyDeltaLineEdit final
|
||||||
: public QLineEdit
|
: public QLineEdit
|
||||||
{
|
{
|
||||||
Q_OBJECT;
|
Q_OBJECT;
|
||||||
Q_PROPERTY (FrequencyDelta frequency_delta READ frequency_delta WRITE frequency_delta USER true);
|
Q_PROPERTY (FrequencyDelta frequency_delta READ frequency_delta WRITE frequency_delta USER true);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
using FrequencyDelta = Radio::FrequencyDelta;
|
using FrequencyDelta = Radio::FrequencyDelta;
|
||||||
|
|
||||||
explicit FrequencyDeltaLineEdit (QWidget * parent = nullptr);
|
explicit FrequencyDeltaLineEdit (QWidget * parent = nullptr);
|
||||||
|
|
||||||
// Property frequency_delta implementation
|
// Property frequency_delta implementation
|
||||||
FrequencyDelta frequency_delta () const;
|
FrequencyDelta frequency_delta () const;
|
||||||
void frequency_delta (FrequencyDelta);
|
void frequency_delta (FrequencyDelta);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
|
@ -7,7 +7,7 @@
|
||||||
#include <QTextStream>
|
#include <QTextStream>
|
||||||
|
|
||||||
#include "qt_helpers.hpp"
|
#include "qt_helpers.hpp"
|
||||||
#include <MessageBox.hpp>
|
#include "widgets/MessageBox.hpp"
|
||||||
|
|
||||||
HelpTextWindow::HelpTextWindow (QString const& title, QString const& file_name, QFont const& font, QWidget * parent)
|
HelpTextWindow::HelpTextWindow (QString const& title, QString const& file_name, QFont const& font, QWidget * parent)
|
||||||
: QLabel {parent, Qt::WindowCloseButtonHint | Qt::WindowMinimizeButtonHint}
|
: QLabel {parent, Qt::WindowCloseButtonHint | Qt::WindowMinimizeButtonHint}
|
|
@ -1,100 +1,100 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<ui version="4.0">
|
<ui version="4.0">
|
||||||
<class>CAboutDlg</class>
|
<class>CAboutDlg</class>
|
||||||
<widget class="QDialog" name="CAboutDlg">
|
<widget class="QDialog" name="CAboutDlg">
|
||||||
<property name="windowModality">
|
<property name="windowModality">
|
||||||
<enum>Qt::NonModal</enum>
|
<enum>Qt::NonModal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>About WSJT-X</string>
|
<string>About WSJT-X</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="labelTxt">
|
<widget class="QLabel" name="labelTxt">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string/>
|
<string/>
|
||||||
</property>
|
</property>
|
||||||
<property name="alignment">
|
<property name="alignment">
|
||||||
<set>Qt::AlignCenter</set>
|
<set>Qt::AlignCenter</set>
|
||||||
</property>
|
</property>
|
||||||
<property name="openExternalLinks">
|
<property name="openExternalLinks">
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="verticalSpacer">
|
<spacer name="verticalSpacer">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Vertical</enum>
|
<enum>Qt::Vertical</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>20</width>
|
||||||
<height>40</height>
|
<height>40</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer">
|
<spacer name="horizontalSpacer">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>40</width>
|
<width>40</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="okButton">
|
<widget class="QPushButton" name="okButton">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>OK</string>
|
<string>OK</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer_2">
|
<spacer name="horizontalSpacer_2">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>40</width>
|
<width>40</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
<resources/>
|
<resources/>
|
||||||
<connections>
|
<connections>
|
||||||
<connection>
|
<connection>
|
||||||
<sender>okButton</sender>
|
<sender>okButton</sender>
|
||||||
<signal>clicked()</signal>
|
<signal>clicked()</signal>
|
||||||
<receiver>CAboutDlg</receiver>
|
<receiver>CAboutDlg</receiver>
|
||||||
<slot>accept()</slot>
|
<slot>accept()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>321</x>
|
<x>321</x>
|
||||||
<y>120</y>
|
<y>120</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>186</x>
|
<x>186</x>
|
||||||
<y>71</y>
|
<y>71</y>
|
||||||
</hint>
|
</hint>
|
||||||
</hints>
|
</hints>
|
||||||
</connection>
|
</connection>
|
||||||
</connections>
|
</connections>
|
||||||
</ui>
|
</ui>
|
|
@ -4,7 +4,7 @@
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
#include "SettingsGroup.hpp"
|
#include "SettingsGroup.hpp"
|
||||||
#include "DecodeHighlightingModel.hpp"
|
#include "models/DecodeHighlightingModel.hpp"
|
||||||
|
|
||||||
#include "ui_colorhighlighting.h"
|
#include "ui_colorhighlighting.h"
|
||||||
#include "moc_colorhighlighting.cpp"
|
#include "moc_colorhighlighting.cpp"
|
|
@ -15,7 +15,7 @@
|
||||||
|
|
||||||
#include "Configuration.hpp"
|
#include "Configuration.hpp"
|
||||||
#include "LotWUsers.hpp"
|
#include "LotWUsers.hpp"
|
||||||
#include "DecodeHighlightingModel.hpp"
|
#include "models/DecodeHighlightingModel.hpp"
|
||||||
#include "logbook/logbook.h"
|
#include "logbook/logbook.h"
|
||||||
|
|
||||||
#include "qt_helpers.hpp"
|
#include "qt_helpers.hpp"
|
|
@ -1,294 +1,294 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<ui version="4.0">
|
<ui version="4.0">
|
||||||
<class>EchoGraph</class>
|
<class>EchoGraph</class>
|
||||||
<widget class="QDialog" name="EchoGraph">
|
<widget class="QDialog" name="EchoGraph">
|
||||||
<property name="geometry">
|
<property name="geometry">
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>625</width>
|
<width>625</width>
|
||||||
<height>336</height>
|
<height>336</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
<verstretch>0</verstretch>
|
<verstretch>0</verstretch>
|
||||||
</sizepolicy>
|
</sizepolicy>
|
||||||
</property>
|
</property>
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>570</width>
|
<width>570</width>
|
||||||
<height>0</height>
|
<height>0</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>Echo Graph</string>
|
<string>Echo Graph</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||||
<property name="spacing">
|
<property name="spacing">
|
||||||
<number>2</number>
|
<number>2</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="topMargin">
|
<property name="topMargin">
|
||||||
<number>2</number>
|
<number>2</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="bottomMargin">
|
<property name="bottomMargin">
|
||||||
<number>2</number>
|
<number>2</number>
|
||||||
</property>
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
<property name="spacing">
|
<property name="spacing">
|
||||||
<number>2</number>
|
<number>2</number>
|
||||||
</property>
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<widget class="EPlotter" name="echoPlot">
|
<widget class="EPlotter" name="echoPlot">
|
||||||
<property name="enabled">
|
<property name="enabled">
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
|
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
<verstretch>0</verstretch>
|
<verstretch>0</verstretch>
|
||||||
</sizepolicy>
|
</sizepolicy>
|
||||||
</property>
|
</property>
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>273</width>
|
<width>273</width>
|
||||||
<height>200</height>
|
<height>200</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="frameShape">
|
<property name="frameShape">
|
||||||
<enum>QFrame::StyledPanel</enum>
|
<enum>QFrame::StyledPanel</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="frameShadow">
|
<property name="frameShadow">
|
||||||
<enum>QFrame::Sunken</enum>
|
<enum>QFrame::Sunken</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="lineWidth">
|
<property name="lineWidth">
|
||||||
<number>1</number>
|
<number>1</number>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||||
<property name="spacing">
|
<property name="spacing">
|
||||||
<number>6</number>
|
<number>6</number>
|
||||||
</property>
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer_2">
|
<spacer name="horizontalSpacer_2">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeType">
|
<property name="sizeType">
|
||||||
<enum>QSizePolicy::Expanding</enum>
|
<enum>QSizePolicy::Expanding</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>20</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QSpinBox" name="binsPerPixelSpinBox">
|
<widget class="QSpinBox" name="binsPerPixelSpinBox">
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>60</width>
|
<width>60</width>
|
||||||
<height>0</height>
|
<height>0</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string><html><head/><body><p>Compression factor for frequency scale</p></body></html></string>
|
<string><html><head/><body><p>Compression factor for frequency scale</p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
<property name="prefix">
|
<property name="prefix">
|
||||||
<string>Bins/Pixel </string>
|
<string>Bins/Pixel </string>
|
||||||
</property>
|
</property>
|
||||||
<property name="minimum">
|
<property name="minimum">
|
||||||
<number>1</number>
|
<number>1</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="maximum">
|
<property name="maximum">
|
||||||
<number>10</number>
|
<number>10</number>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="label_4">
|
<widget class="QLabel" name="label_4">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Gain</string>
|
<string>Gain</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QSlider" name="gainSlider">
|
<widget class="QSlider" name="gainSlider">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string><html><head/><body><p>Echo spectrum gain</p></body></html></string>
|
<string><html><head/><body><p>Echo spectrum gain</p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
<property name="minimum">
|
<property name="minimum">
|
||||||
<number>-30</number>
|
<number>-30</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="maximum">
|
<property name="maximum">
|
||||||
<number>30</number>
|
<number>30</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer_7">
|
<spacer name="horizontalSpacer_7">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeType">
|
<property name="sizeType">
|
||||||
<enum>QSizePolicy::Preferred</enum>
|
<enum>QSizePolicy::Preferred</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>20</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="label">
|
<widget class="QLabel" name="label">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Zero</string>
|
<string>Zero</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QSlider" name="zeroSlider">
|
<widget class="QSlider" name="zeroSlider">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string><html><head/><body><p>Echo spectrum zero</p></body></html></string>
|
<string><html><head/><body><p>Echo spectrum zero</p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
<property name="minimum">
|
<property name="minimum">
|
||||||
<number>-150</number>
|
<number>-150</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="maximum">
|
<property name="maximum">
|
||||||
<number>150</number>
|
<number>150</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer">
|
<spacer name="horizontalSpacer">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeType">
|
<property name="sizeType">
|
||||||
<enum>QSizePolicy::Preferred</enum>
|
<enum>QSizePolicy::Preferred</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>20</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QSpinBox" name="smoothSpinBox">
|
<widget class="QSpinBox" name="smoothSpinBox">
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>60</width>
|
<width>60</width>
|
||||||
<height>0</height>
|
<height>0</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string><html><head/><body><p>Smoothing of echo spectrum</p></body></html></string>
|
<string><html><head/><body><p>Smoothing of echo spectrum</p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
<property name="prefix">
|
<property name="prefix">
|
||||||
<string>Smooth </string>
|
<string>Smooth </string>
|
||||||
</property>
|
</property>
|
||||||
<property name="maximum">
|
<property name="maximum">
|
||||||
<number>20</number>
|
<number>20</number>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer_3">
|
<spacer name="horizontalSpacer_3">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeType">
|
<property name="sizeType">
|
||||||
<enum>QSizePolicy::Preferred</enum>
|
<enum>QSizePolicy::Preferred</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>20</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="nsum_label">
|
<widget class="QLabel" name="nsum_label">
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>30</width>
|
<width>30</width>
|
||||||
<height>0</height>
|
<height>0</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string><html><head/><body><p>Number of echo transmissions averaged</p></body></html></string>
|
<string><html><head/><body><p>Number of echo transmissions averaged</p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>N: 0</string>
|
<string>N: 0</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="alignment">
|
<property name="alignment">
|
||||||
<set>Qt::AlignCenter</set>
|
<set>Qt::AlignCenter</set>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pbColors">
|
<widget class="QPushButton" name="pbColors">
|
||||||
<property name="maximumSize">
|
<property name="maximumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>50</width>
|
<width>50</width>
|
||||||
<height>16777215</height>
|
<height>16777215</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string><html><head/><body><p>Click to cycle through a sequence of colors and line widths.</p></body></html></string>
|
<string><html><head/><body><p>Click to cycle through a sequence of colors and line widths.</p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Colors</string>
|
<string>Colors</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer_5">
|
<spacer name="horizontalSpacer_5">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeType">
|
<property name="sizeType">
|
||||||
<enum>QSizePolicy::Expanding</enum>
|
<enum>QSizePolicy::Expanding</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>20</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
<customwidgets>
|
<customwidgets>
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>EPlotter</class>
|
<class>EPlotter</class>
|
||||||
<extends>QFrame</extends>
|
<extends>QFrame</extends>
|
||||||
<header>plotter.h</header>
|
<header>widgets/plotter.h</header>
|
||||||
<container>1</container>
|
<container>1</container>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
</customwidgets>
|
</customwidgets>
|
||||||
<resources/>
|
<resources/>
|
||||||
<connections/>
|
<connections/>
|
||||||
</ui>
|
</ui>
|
|
@ -2,6 +2,14 @@
|
||||||
<ui version="4.0">
|
<ui version="4.0">
|
||||||
<class>FastGraph</class>
|
<class>FastGraph</class>
|
||||||
<widget class="QDialog" name="FastGraph">
|
<widget class="QDialog" name="FastGraph">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>707</width>
|
||||||
|
<height>253</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>Fast Graph</string>
|
<string>Fast Graph</string>
|
||||||
</property>
|
</property>
|
||||||
|
@ -229,7 +237,7 @@
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>FPlotter</class>
|
<class>FPlotter</class>
|
||||||
<extends>QFrame</extends>
|
<extends>QFrame</extends>
|
||||||
<header>fastplot.h</header>
|
<header>widgets/fastplot.h</header>
|
||||||
<container>1</container>
|
<container>1</container>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
</customwidgets>
|
</customwidgets>
|
|
@ -9,8 +9,8 @@
|
||||||
#include "logbook/logbook.h"
|
#include "logbook/logbook.h"
|
||||||
#include "MessageBox.hpp"
|
#include "MessageBox.hpp"
|
||||||
#include "Configuration.hpp"
|
#include "Configuration.hpp"
|
||||||
#include "Bands.hpp"
|
#include "models/Bands.hpp"
|
||||||
#include "MaidenheadLocatorValidator.hpp"
|
#include "validators/MaidenheadLocatorValidator.hpp"
|
||||||
|
|
||||||
#include "ui_logqso.h"
|
#include "ui_logqso.h"
|
||||||
#include "moc_logqso.cpp"
|
#include "moc_logqso.cpp"
|
|
@ -46,10 +46,10 @@
|
||||||
#include "logqso.h"
|
#include "logqso.h"
|
||||||
#include "decodedtext.h"
|
#include "decodedtext.h"
|
||||||
#include "Radio.hpp"
|
#include "Radio.hpp"
|
||||||
#include "Bands.hpp"
|
#include "models/Bands.hpp"
|
||||||
#include "TransceiverFactory.hpp"
|
#include "TransceiverFactory.hpp"
|
||||||
#include "StationList.hpp"
|
#include "models/StationList.hpp"
|
||||||
#include "LiveFrequencyValidator.hpp"
|
#include "validators/LiveFrequencyValidator.hpp"
|
||||||
#include "MessageClient.hpp"
|
#include "MessageClient.hpp"
|
||||||
#include "wsprnet.h"
|
#include "wsprnet.h"
|
||||||
#include "signalmeter.h"
|
#include "signalmeter.h"
|
||||||
|
@ -57,12 +57,14 @@
|
||||||
#include "SampleDownloader.hpp"
|
#include "SampleDownloader.hpp"
|
||||||
#include "Audio/BWFFile.hpp"
|
#include "Audio/BWFFile.hpp"
|
||||||
#include "MultiSettings.hpp"
|
#include "MultiSettings.hpp"
|
||||||
#include "MaidenheadLocatorValidator.hpp"
|
#include "validators/MaidenheadLocatorValidator.hpp"
|
||||||
#include "CallsignValidator.hpp"
|
#include "validators/CallsignValidator.hpp"
|
||||||
#include "ExchangeValidator.hpp"
|
#include "validators/ExchangeValidator.hpp"
|
||||||
#include "EqualizationToolsDialog.hpp"
|
#include "EqualizationToolsDialog.hpp"
|
||||||
#include "LotWUsers.hpp"
|
#include "LotWUsers.hpp"
|
||||||
#include "logbook/AD1CCty.hpp"
|
#include "logbook/AD1CCty.hpp"
|
||||||
|
#include "models/FoxLog.hpp"
|
||||||
|
#include "FoXLogWindow.hpp"
|
||||||
|
|
||||||
#include "ui_mainwindow.h"
|
#include "ui_mainwindow.h"
|
||||||
#include "moc_mainwindow.cpp"
|
#include "moc_mainwindow.cpp"
|
||||||
|
@ -1032,7 +1034,8 @@ void MainWindow::writeSettings()
|
||||||
m_settings->setValue("DXcall",ui->dxCallEntry->text());
|
m_settings->setValue("DXcall",ui->dxCallEntry->text());
|
||||||
m_settings->setValue("DXgrid",ui->dxGridEntry->text());
|
m_settings->setValue("DXgrid",ui->dxGridEntry->text());
|
||||||
m_settings->setValue ("AstroDisplayed", m_astroWidget && m_astroWidget->isVisible());
|
m_settings->setValue ("AstroDisplayed", m_astroWidget && m_astroWidget->isVisible());
|
||||||
m_settings->setValue ("MsgAvgDisplayed", m_msgAvgWidget && m_msgAvgWidget->isVisible());
|
m_settings->setValue ("MsgAvgDisplayed", m_msgAvgWidget && m_msgAvgWidget->isVisible ());
|
||||||
|
m_settings->setValue ("FoxLogDisplayed", m_foxLogWindow && m_foxLogWindow->isVisible ());
|
||||||
m_settings->setValue ("FreeText", ui->freeTextMsg->currentText ());
|
m_settings->setValue ("FreeText", ui->freeTextMsg->currentText ());
|
||||||
m_settings->setValue("ShowMenus",ui->cbMenus->isChecked());
|
m_settings->setValue("ShowMenus",ui->cbMenus->isChecked());
|
||||||
m_settings->setValue("CallFirst",ui->cbFirst->isChecked());
|
m_settings->setValue("CallFirst",ui->cbFirst->isChecked());
|
||||||
|
@ -1107,6 +1110,7 @@ void MainWindow::readSettings()
|
||||||
m_txFirst = m_settings->value("TxFirst",false).toBool();
|
m_txFirst = m_settings->value("TxFirst",false).toBool();
|
||||||
auto displayAstro = m_settings->value ("AstroDisplayed", false).toBool ();
|
auto displayAstro = m_settings->value ("AstroDisplayed", false).toBool ();
|
||||||
auto displayMsgAvg = m_settings->value ("MsgAvgDisplayed", false).toBool ();
|
auto displayMsgAvg = m_settings->value ("MsgAvgDisplayed", false).toBool ();
|
||||||
|
auto displayFoxLog = m_settings->value ("FoxLogDisplayed", false).toBool ();
|
||||||
if (m_settings->contains ("FreeText")) ui->freeTextMsg->setCurrentText (
|
if (m_settings->contains ("FreeText")) ui->freeTextMsg->setCurrentText (
|
||||||
m_settings->value ("FreeText").toString ());
|
m_settings->value ("FreeText").toString ());
|
||||||
ui->cbMenus->setChecked(m_settings->value("ShowMenus",true).toBool());
|
ui->cbMenus->setChecked(m_settings->value("ShowMenus",true).toBool());
|
||||||
|
@ -1196,6 +1200,7 @@ void MainWindow::readSettings()
|
||||||
|
|
||||||
checkMSK144ContestType();
|
checkMSK144ContestType();
|
||||||
if(displayMsgAvg) on_actionMessage_averaging_triggered();
|
if(displayMsgAvg) on_actionMessage_averaging_triggered();
|
||||||
|
if (displayFoxLog) on_actionFox_Log_triggered ();
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::checkMSK144ContestType()
|
void MainWindow::checkMSK144ContestType()
|
||||||
|
@ -1236,6 +1241,9 @@ void MainWindow::setDecodedTextFont (QFont const& font)
|
||||||
if (m_msgAvgWidget) {
|
if (m_msgAvgWidget) {
|
||||||
m_msgAvgWidget->changeFont (font);
|
m_msgAvgWidget->changeFont (font);
|
||||||
}
|
}
|
||||||
|
if (m_foxLogWindow) {
|
||||||
|
m_foxLogWindow->change_font (font);
|
||||||
|
}
|
||||||
updateGeometry ();
|
updateGeometry ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2416,8 +2424,20 @@ void MainWindow::on_actionAstronomical_data_toggled (bool checked)
|
||||||
|
|
||||||
void MainWindow::on_actionFox_Log_triggered()
|
void MainWindow::on_actionFox_Log_triggered()
|
||||||
{
|
{
|
||||||
on_actionMessage_averaging_triggered();
|
if (!m_foxLog)
|
||||||
m_msgAvgWidget->foxLogSetup( static_cast<int> (m_config.special_op_id()) );
|
{
|
||||||
|
m_foxLog.reset (new FoxLog);
|
||||||
|
}
|
||||||
|
if (!m_foxLogWindow)
|
||||||
|
{
|
||||||
|
m_foxLogWindow.reset (new FoxLogWindow {m_settings, &m_config, m_foxLog->model ()});
|
||||||
|
|
||||||
|
// Connect signals from fox log window
|
||||||
|
connect (this, &MainWindow::finished, m_foxLogWindow.data (), &FoxLogWindow::close);
|
||||||
|
}
|
||||||
|
m_foxLogWindow->showNormal ();
|
||||||
|
m_foxLogWindow->raise ();
|
||||||
|
m_foxLogWindow->activateWindow ();
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::on_actionColors_triggered()
|
void MainWindow::on_actionColors_triggered()
|
||||||
|
@ -3766,8 +3786,12 @@ void MainWindow::guiUpdate()
|
||||||
|
|
||||||
//Once per second:
|
//Once per second:
|
||||||
if(nsec != m_sec0) {
|
if(nsec != m_sec0) {
|
||||||
if((!m_msgAvgWidget or (m_msgAvgWidget and !m_msgAvgWidget->isVisible()))
|
// if((!m_msgAvgWidget or (m_msgAvgWidget and !m_msgAvgWidget->isVisible()))
|
||||||
and (SpecOp::NONE < m_config.special_op_id()) and (SpecOp::HOUND > m_config.special_op_id())) on_actionFox_Log_triggered();
|
// and (SpecOp::NONE < m_config.special_op_id()) and (SpecOp::HOUND > m_config.special_op_id())) on_actionFox_Log_triggered();
|
||||||
|
if (SpecOp::FOX == m_config.special_op_id() && (!m_foxLogWindow || !m_foxLogWindow->isVisible ()))
|
||||||
|
{
|
||||||
|
on_actionFox_Log_triggered();
|
||||||
|
}
|
||||||
if(m_freqNominal!=0 and m_freqNominal<50000000 and m_config.enable_VHF_features()) {
|
if(m_freqNominal!=0 and m_freqNominal<50000000 and m_config.enable_VHF_features()) {
|
||||||
if(!m_bVHFwarned) vhfWarning();
|
if(!m_bVHFwarned) vhfWarning();
|
||||||
} else {
|
} else {
|
||||||
|
@ -8021,9 +8045,10 @@ void MainWindow::houndCallers()
|
||||||
m_nHoundsCalling++; // Number of accepted Hounds to be sorted
|
m_nHoundsCalling++; // Number of accepted Hounds to be sorted
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(m_msgAvgWidget != NULL and m_msgAvgWidget->isVisible()) {
|
if(m_foxLogWindow && m_foxLogWindow->isVisible ())
|
||||||
m_msgAvgWidget->foxLabCallers(nTotal);
|
{
|
||||||
}
|
m_foxLogWindow->callers (nTotal);
|
||||||
|
}
|
||||||
|
|
||||||
// Sort and display accumulated list of Hound callers
|
// Sort and display accumulated list of Hound callers
|
||||||
if(t.length()>30) {
|
if(t.length()>30) {
|
||||||
|
@ -8179,21 +8204,23 @@ list2Done:
|
||||||
|
|
||||||
if(hc1!="") {
|
if(hc1!="") {
|
||||||
// Log this QSO!
|
// Log this QSO!
|
||||||
|
auto QSO_time = QDateTime::currentDateTimeUtc ();
|
||||||
m_hisCall=hc1;
|
m_hisCall=hc1;
|
||||||
m_hisGrid=m_foxQSO[hc1].grid;
|
m_hisGrid=m_foxQSO[hc1].grid;
|
||||||
m_rptSent=m_foxQSO[hc1].sent;
|
m_rptSent=m_foxQSO[hc1].sent;
|
||||||
m_rptRcvd=m_foxQSO[hc1].rcvd;
|
m_rptRcvd=m_foxQSO[hc1].rcvd;
|
||||||
QDateTime logTime {QDateTime::currentDateTimeUtc ()};
|
if (!m_foxLogWindow)
|
||||||
QString thc1=(m_hisCall + " ").mid(0,6);
|
{
|
||||||
if(m_hisCall.contains("/")) thc1=m_hisCall;
|
on_actionFox_Log_triggered ();
|
||||||
QString logLine=logTime.toString("yyyy-MM-dd hh:mm") + " " + thc1 + " " +
|
}
|
||||||
m_hisGrid + " " + m_rptSent + " " + m_rptRcvd + " " + m_lastBand;
|
if (m_foxLog->add_QSO (QSO_time, m_hisCall, m_hisGrid, m_rptSent, m_rptRcvd, m_lastBand))
|
||||||
if(m_msgAvgWidget != NULL and m_msgAvgWidget->isVisible()) {
|
{
|
||||||
m_msgAvgWidget->foxAddLog(logLine);
|
writeFoxQSO (QString {" Log: %1 %2 %3 %4 %5"}.arg (m_hisCall).arg (m_hisGrid)
|
||||||
}
|
.arg (m_rptSent).arg (m_rptRcvd).arg (m_lastBand));
|
||||||
on_logQSOButton_clicked();
|
on_logQSOButton_clicked();
|
||||||
writeFoxQSO(" Log: " + logLine.mid(17));
|
m_foxRateQueue.enqueue (now); //Add present time in seconds
|
||||||
m_foxRateQueue.enqueue(now); //Add present time in seconds to Rate queue.
|
//to Rate queue.
|
||||||
|
}
|
||||||
m_loggedByFox[hc1] += (m_lastBand + " ");
|
m_loggedByFox[hc1] += (m_lastBand + " ");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -8249,10 +8276,11 @@ Transmit:
|
||||||
if(age < 3600) break;
|
if(age < 3600) break;
|
||||||
m_foxRateQueue.dequeue();
|
m_foxRateQueue.dequeue();
|
||||||
}
|
}
|
||||||
if(m_msgAvgWidget != NULL and m_msgAvgWidget->isVisible()) {
|
if (m_foxLogWindow && m_foxLogWindow->isVisible ())
|
||||||
m_msgAvgWidget->foxLabRate(m_foxRateQueue.size());
|
{
|
||||||
m_msgAvgWidget->foxLabQueued(m_foxQSOinProgress.count());
|
m_foxLogWindow->rate (m_foxRateQueue.size ());
|
||||||
}
|
m_foxLogWindow->queued (m_foxQSOinProgress.count ());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::rm_tb4(QString houndCall)
|
void MainWindow::rm_tb4(QString houndCall)
|
||||||
|
@ -8312,7 +8340,7 @@ void MainWindow::foxGenWaveform(int i,QString fm)
|
||||||
writeFoxQSO(t + fm.trimmed());
|
writeFoxQSO(t + fm.trimmed());
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::writeFoxQSO(QString msg)
|
void MainWindow::writeFoxQSO(QString const& msg)
|
||||||
{
|
{
|
||||||
QString t;
|
QString t;
|
||||||
t.sprintf("%3d%3d%3d",m_houndQueue.count(),m_foxQSOinProgress.count(),m_foxQSO.count());
|
t.sprintf("%3d%3d%3d",m_houndQueue.count(),m_foxQSOinProgress.count(),m_foxQSO.count());
|
|
@ -25,8 +25,8 @@
|
||||||
#include "AudioDevice.hpp"
|
#include "AudioDevice.hpp"
|
||||||
#include "commons.h"
|
#include "commons.h"
|
||||||
#include "Radio.hpp"
|
#include "Radio.hpp"
|
||||||
#include "Modes.hpp"
|
#include "models/Modes.hpp"
|
||||||
#include "FrequencyList.hpp"
|
#include "models/FrequencyList.hpp"
|
||||||
#include "Configuration.hpp"
|
#include "Configuration.hpp"
|
||||||
#include "WSPRBandHopping.hpp"
|
#include "WSPRBandHopping.hpp"
|
||||||
#include "Transceiver.hpp"
|
#include "Transceiver.hpp"
|
||||||
|
@ -69,6 +69,8 @@ class WideGraph;
|
||||||
class LogQSO;
|
class LogQSO;
|
||||||
class Transceiver;
|
class Transceiver;
|
||||||
class MessageAveraging;
|
class MessageAveraging;
|
||||||
|
class FoxLogWindow;
|
||||||
|
class FoxLog;
|
||||||
class ColorHighlighting;
|
class ColorHighlighting;
|
||||||
class MessageClient;
|
class MessageClient;
|
||||||
class QTime;
|
class QTime;
|
||||||
|
@ -360,6 +362,8 @@ private:
|
||||||
QScopedPointer<HelpTextWindow> m_prefixes;
|
QScopedPointer<HelpTextWindow> m_prefixes;
|
||||||
QScopedPointer<HelpTextWindow> m_mouseCmnds;
|
QScopedPointer<HelpTextWindow> m_mouseCmnds;
|
||||||
QScopedPointer<MessageAveraging> m_msgAvgWidget;
|
QScopedPointer<MessageAveraging> m_msgAvgWidget;
|
||||||
|
QScopedPointer<FoxLog> m_foxLog;
|
||||||
|
QScopedPointer<FoxLogWindow> m_foxLogWindow;
|
||||||
QScopedPointer<ColorHighlighting> m_colorHighlighting;
|
QScopedPointer<ColorHighlighting> m_colorHighlighting;
|
||||||
QScopedPointer<ExportCabrillo> m_exportCabrillo;
|
QScopedPointer<ExportCabrillo> m_exportCabrillo;
|
||||||
Transceiver::TransceiverState m_rigState;
|
Transceiver::TransceiverState m_rigState;
|
||||||
|
@ -733,7 +737,7 @@ private:
|
||||||
void foxRxSequencer(QString msg, QString houndCall, QString rptRcvd);
|
void foxRxSequencer(QString msg, QString houndCall, QString rptRcvd);
|
||||||
void foxTxSequencer();
|
void foxTxSequencer();
|
||||||
void foxGenWaveform(int i,QString fm);
|
void foxGenWaveform(int i,QString fm);
|
||||||
void writeFoxQSO(QString msg);
|
void writeFoxQSO (QString const& msg);
|
||||||
};
|
};
|
||||||
|
|
||||||
extern int killbyname(const char* progName);
|
extern int killbyname(const char* progName);
|
|
@ -3353,38 +3353,38 @@ QPushButton[state="ok"] {
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>DisplayText</class>
|
<class>DisplayText</class>
|
||||||
<extends>QTextEdit</extends>
|
<extends>QTextEdit</extends>
|
||||||
<header>displaytext.h</header>
|
<header>widgets/displaytext.h</header>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>LettersSpinBox</class>
|
<class>LettersSpinBox</class>
|
||||||
<extends>QSpinBox</extends>
|
<extends>QSpinBox</extends>
|
||||||
<header>LettersSpinBox.hpp</header>
|
<header>widgets/LettersSpinBox.hpp</header>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>SignalMeter</class>
|
<class>SignalMeter</class>
|
||||||
<extends>QFrame</extends>
|
<extends>QFrame</extends>
|
||||||
<header>signalmeter.h</header>
|
<header>widgets/signalmeter.h</header>
|
||||||
<container>1</container>
|
<container>1</container>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>HintedSpinBox</class>
|
<class>HintedSpinBox</class>
|
||||||
<extends>QSpinBox</extends>
|
<extends>QSpinBox</extends>
|
||||||
<header>HintedSpinBox.hpp</header>
|
<header>widgets/HintedSpinBox.hpp</header>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>RestrictedSpinBox</class>
|
<class>RestrictedSpinBox</class>
|
||||||
<extends>QSpinBox</extends>
|
<extends>QSpinBox</extends>
|
||||||
<header>RestrictedSpinBox.hpp</header>
|
<header>widgets/RestrictedSpinBox.hpp</header>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>DoubleClickableRadioButton</class>
|
<class>DoubleClickableRadioButton</class>
|
||||||
<extends>QRadioButton</extends>
|
<extends>QRadioButton</extends>
|
||||||
<header>DoubleClickableRadioButton.hpp</header>
|
<header>widgets/DoubleClickableRadioButton.hpp</header>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>DoubleClickablePushButton</class>
|
<class>DoubleClickablePushButton</class>
|
||||||
<extends>QPushButton</extends>
|
<extends>QPushButton</extends>
|
||||||
<header>DoubleClickablePushButton.hpp</header>
|
<header>widgets/DoubleClickablePushButton.hpp</header>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
</customwidgets>
|
</customwidgets>
|
||||||
<tabstops>
|
<tabstops>
|
|
@ -1,130 +1,130 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<ui version="4.0">
|
<ui version="4.0">
|
||||||
<class>MessageAveraging</class>
|
<class>MessageAveraging</class>
|
||||||
<widget class="QWidget" name="MessageAveraging">
|
<widget class="QWidget" name="MessageAveraging">
|
||||||
<property name="geometry">
|
<property name="geometry">
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>354</width>
|
<width>354</width>
|
||||||
<height>268</height>
|
<height>268</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>Message Averaging</string>
|
<string>Message Averaging</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
<item>
|
<item>
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
<widget class="QLabel" name="header_label">
|
<widget class="QLabel" name="header_label">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string> UTC Sync DT Freq </string>
|
<string> UTC Sync DT Freq </string>
|
||||||
</property>
|
</property>
|
||||||
<property name="margin">
|
<property name="margin">
|
||||||
<number>3</number>
|
<number>3</number>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="0">
|
<item row="1" column="0">
|
||||||
<widget class="QPlainTextEdit" name="msgAvgPlainTextEdit">
|
<widget class="QPlainTextEdit" name="msgAvgPlainTextEdit">
|
||||||
<property name="lineWrapMode">
|
<property name="lineWrapMode">
|
||||||
<enum>QPlainTextEdit::NoWrap</enum>
|
<enum>QPlainTextEdit::NoWrap</enum>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="0">
|
<item row="2" column="0">
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer">
|
<spacer name="horizontalSpacer">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeType">
|
<property name="sizeType">
|
||||||
<enum>QSizePolicy::Fixed</enum>
|
<enum>QSizePolicy::Fixed</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>20</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="lab1">
|
<widget class="QLabel" name="lab1">
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>77</width>
|
<width>77</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Callers: 0</string>
|
<string>Callers: 0</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="lab2">
|
<widget class="QLabel" name="lab2">
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>77</width>
|
<width>77</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>In progress: 0</string>
|
<string>In progress: 0</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<spacer name="horizontalSpacer_2">
|
<spacer name="horizontalSpacer_2">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeType">
|
<property name="sizeType">
|
||||||
<enum>QSizePolicy::Fixed</enum>
|
<enum>QSizePolicy::Fixed</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>25</width>
|
<width>25</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="lab3">
|
<widget class="QLabel" name="lab3">
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>77</width>
|
<width>77</width>
|
||||||
<height>0</height>
|
<height>0</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Logged: 0</string>
|
<string>Logged: 0</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="lab4">
|
<widget class="QLabel" name="lab4">
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>77</width>
|
<width>77</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Rate: 0</string>
|
<string>Rate: 0</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
<resources/>
|
<resources/>
|
||||||
<connections/>
|
<connections/>
|
||||||
</ui>
|
</ui>
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue