mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-21 19:55:20 -05:00
Add features Highlight DX Call / DX Grid and Clear DX Call / DX Grid after QSO
This commit is contained in:
parent
fb4eb56508
commit
947ab4eb25
@ -670,6 +670,10 @@ private:
|
||||
bool bLowSidelobes_;
|
||||
bool pwrBandTxMemory_;
|
||||
bool pwrBandTuneMemory_;
|
||||
bool highlight_DXcall_;
|
||||
bool clear_DXcall_;
|
||||
bool highlight_DXgrid_;
|
||||
bool clear_DXgrid_;
|
||||
|
||||
QAudioDeviceInfo audio_input_device_;
|
||||
QAudioDeviceInfo next_audio_input_device_;
|
||||
@ -787,6 +791,10 @@ DecodeHighlightingModel const& Configuration::decode_highlighting () const {retu
|
||||
bool Configuration::highlight_by_mode () const {return m_->highlight_by_mode_;}
|
||||
bool Configuration::highlight_only_fields () const {return m_->highlight_only_fields_;}
|
||||
bool Configuration::include_WAE_entities () const {return m_->include_WAE_entities_;}
|
||||
bool Configuration::highlight_DXcall () const {return m_->highlight_DXcall_;}
|
||||
bool Configuration::clear_DXcall () const {return m_->clear_DXcall_;}
|
||||
bool Configuration::highlight_DXgrid () const {return m_->highlight_DXgrid_;}
|
||||
bool Configuration::clear_DXgrid () const {return m_->clear_DXgrid_;}
|
||||
|
||||
void Configuration::set_calibration (CalibrationParams params)
|
||||
{
|
||||
@ -1422,6 +1430,10 @@ void Configuration::impl::initialize_models ()
|
||||
ui_->only_fields_check_box->setChecked (highlight_only_fields_);
|
||||
ui_->include_WAE_check_box->setChecked (include_WAE_entities_);
|
||||
ui_->LotW_days_since_upload_spin_box->setValue (LotW_days_since_upload_);
|
||||
ui_->cbHighlightDXcall->setChecked(highlight_DXcall_);
|
||||
ui_->cbClearDXcall->setChecked(clear_DXcall_);
|
||||
ui_->cbHighlightDXgrid->setChecked(highlight_DXgrid_);
|
||||
ui_->cbClearDXgrid->setChecked(clear_DXgrid_);
|
||||
|
||||
set_rig_invariants ();
|
||||
}
|
||||
@ -1578,6 +1590,10 @@ void Configuration::impl::read_settings ()
|
||||
calibration_.slope_ppm = settings_->value ("CalibrationSlopePPM", 0.).toDouble ();
|
||||
pwrBandTxMemory_ = settings_->value("pwrBandTxMemory",false).toBool ();
|
||||
pwrBandTuneMemory_ = settings_->value("pwrBandTuneMemory",false).toBool ();
|
||||
highlight_DXcall_ = settings_->value("highlight_DXcall",false).toBool ();
|
||||
clear_DXcall_ = settings_->value("clear_DXcall",false).toBool ();
|
||||
highlight_DXgrid_ = settings_->value("highlight_DXgrid",false).toBool ();
|
||||
clear_DXgrid_ = settings_->value("clear_DXgrid",false).toBool ();
|
||||
}
|
||||
|
||||
void Configuration::impl::find_audio_devices ()
|
||||
@ -1709,6 +1725,10 @@ void Configuration::impl::write_settings ()
|
||||
settings_->setValue ("pwrBandTuneMemory", pwrBandTuneMemory_);
|
||||
settings_->setValue ("Region", QVariant::fromValue (region_));
|
||||
settings_->setValue ("AutoGrid", use_dynamic_grid_);
|
||||
settings_->setValue ("highlight_DXcall", highlight_DXcall_);
|
||||
settings_->setValue ("clear_DXcall", clear_DXcall_);
|
||||
settings_->setValue ("highlight_DXgrid", highlight_DXgrid_);
|
||||
settings_->setValue ("clear_DXgrid", clear_DXgrid_);
|
||||
settings_->sync ();
|
||||
}
|
||||
|
||||
@ -2196,6 +2216,10 @@ void Configuration::impl::accept ()
|
||||
dynamic_grid_.clear ();
|
||||
}
|
||||
use_dynamic_grid_ = ui_->use_dynamic_grid->isChecked();
|
||||
highlight_DXcall_ = ui_->cbHighlightDXcall->isChecked();
|
||||
clear_DXcall_ = ui_->cbClearDXcall->isChecked();
|
||||
highlight_DXgrid_ = ui_->cbHighlightDXgrid->isChecked();
|
||||
clear_DXgrid_ = ui_->cbClearDXgrid->isChecked();
|
||||
|
||||
write_settings (); // make visible to all
|
||||
}
|
||||
|
@ -184,6 +184,10 @@ public:
|
||||
void setSpecial_Hound();
|
||||
void setSpecial_Fox();
|
||||
void setSpecial_None();
|
||||
bool highlight_DXcall () const;
|
||||
bool clear_DXcall () const;
|
||||
bool highlight_DXgrid () const;
|
||||
bool clear_DXgrid () const;
|
||||
|
||||
enum class SpecialOperatingActivity {NONE, NA_VHF, EU_VHF, FIELD_DAY, RTTY, WW_DIGI, FOX, HOUND};
|
||||
SpecialOperatingActivity special_op_id () const;
|
||||
|
@ -181,29 +181,6 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QCheckBox" name="DXCC_check_box">
|
||||
<property name="toolTip">
|
||||
<string>Show if decoded stations are new DXCC entities or worked before.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Show &DXCC, grid, and worked-before status</string>
|
||||
</property>
|
||||
<property name="checked">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0">
|
||||
<widget class="QCheckBox" name="decodes_from_top_check_box">
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>Check to have decodes for a new period start at the top of the Band Activity window and not scroll off the top when the window is full.</p><p>This is to aid selecting decodes to double-click while decoding is still in progress. Use the Band Activity vertical scroll bar to reveal decodes past the bottom of the window.</p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Start new period decodes at top</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1">
|
||||
<widget class="QCheckBox" name="ppfx_check_box">
|
||||
<property name="text">
|
||||
@ -265,13 +242,10 @@
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QCheckBox" name="insert_blank_check_box">
|
||||
<property name="toolTip">
|
||||
<string>Include a separator line between periods in the band activity window.</string>
|
||||
</property>
|
||||
<item row="5" column="0">
|
||||
<widget class="QCheckBox" name="cbHighlightDXcall">
|
||||
<property name="text">
|
||||
<string>&Blank line between decoding periods</string>
|
||||
<string>Highlight DX Call in message</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@ -285,6 +259,60 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QCheckBox" name="DXCC_check_box">
|
||||
<property name="toolTip">
|
||||
<string>Show if decoded stations are new DXCC entities or worked before.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Show &DXCC, grid, and worked-before status</string>
|
||||
</property>
|
||||
<property name="checked">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0">
|
||||
<widget class="QCheckBox" name="decodes_from_top_check_box">
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>Check to have decodes for a new period start at the top of the Band Activity window and not scroll off the top when the window is full.</p><p>This is to aid selecting decodes to double-click while decoding is still in progress. Use the Band Activity vertical scroll bar to reveal decodes past the bottom of the window.</p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Start new period decodes at top</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="1">
|
||||
<widget class="QCheckBox" name="cbClearDXgrid">
|
||||
<property name="text">
|
||||
<string>Clear DX Grid after QSO</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QCheckBox" name="insert_blank_check_box">
|
||||
<property name="toolTip">
|
||||
<string>Include a separator line between periods in the band activity window.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Blank line between decoding periods</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="1">
|
||||
<widget class="QCheckBox" name="cbHighlightDXgrid">
|
||||
<property name="text">
|
||||
<string>Highlight DX Grid in message</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="0">
|
||||
<widget class="QCheckBox" name="cbClearDXcall">
|
||||
<property name="text">
|
||||
<string>Clear DX Call after QSO</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
@ -3233,13 +3261,13 @@ Right click for insert and delete options.</string>
|
||||
</connection>
|
||||
</connections>
|
||||
<buttongroups>
|
||||
<buttongroup name="PTT_method_button_group"/>
|
||||
<buttongroup name="TX_mode_button_group"/>
|
||||
<buttongroup name="split_mode_button_group"/>
|
||||
<buttongroup name="CAT_handshake_button_group"/>
|
||||
<buttongroup name="TX_audio_source_button_group"/>
|
||||
<buttongroup name="CAT_stop_bits_button_group"/>
|
||||
<buttongroup name="CAT_handshake_button_group"/>
|
||||
<buttongroup name="CAT_data_bits_button_group"/>
|
||||
<buttongroup name="TX_mode_button_group"/>
|
||||
<buttongroup name="special_op_activity_button_group"/>
|
||||
<buttongroup name="PTT_method_button_group"/>
|
||||
<buttongroup name="split_mode_button_group"/>
|
||||
<buttongroup name="CAT_data_bits_button_group"/>
|
||||
</buttongroups>
|
||||
</ui>
|
||||
|
@ -3457,6 +3457,15 @@ void MainWindow::readFromStdout() //readFromStdout
|
||||
ui->cbCQonly->isVisible() && ui->cbCQonly->isChecked(),
|
||||
haveFSpread, fSpread);
|
||||
|
||||
if (m_config.highlight_DXcall () && (m_hisCall!="") && ((decodedtext.string().contains(QRegularExpression {"(\\w+) " + m_hisCall}))
|
||||
|| (decodedtext.string().contains(QRegularExpression {"(\\w+) <" + m_hisCall +">"}))
|
||||
|| (decodedtext.string().contains(QRegularExpression {"<(\\w+)> " + m_hisCall})))) {
|
||||
ui->decodedTextBrowser->highlight_callsign(m_hisCall, QColor(255,0,0), QColor(255,255,255), true); // highlight dxCallEntry
|
||||
}
|
||||
if (m_config.highlight_DXgrid () && (m_hisGrid!="") && (decodedtext.string().contains(m_hisGrid))) {
|
||||
ui->decodedTextBrowser->highlight_callsign(m_hisGrid, QColor(0,0,255), QColor(255,255,255), true); // highlight dxGridEntry
|
||||
}
|
||||
|
||||
if(m_bBestSPArmed && m_mode=="FT4" && CALLING == m_QSOProgress) {
|
||||
QString messagePriority=ui->decodedTextBrowser->CQPriority();
|
||||
if(messagePriority!="") {
|
||||
@ -6013,6 +6022,8 @@ void MainWindow::acceptQSO (QDateTime const& QSO_date_off, QString const& call,
|
||||
|
||||
m_xSent.clear ();
|
||||
m_xRcvd.clear ();
|
||||
if (m_config.clear_DXcall ()) ui->dxCallEntry->clear ();
|
||||
if (m_config.clear_DXgrid ()) ui->dxGridEntry->clear ();
|
||||
}
|
||||
|
||||
qint64 MainWindow::nWidgets(QString t)
|
||||
|
Loading…
Reference in New Issue
Block a user