Merge pull request #962 from srcejon/fix_961

Increase widget minimum width when scope is visible
pull/966/head
Edouard Griffiths 2021-07-15 16:48:19 +02:00 zatwierdzone przez GitHub
commit fe923a5813
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
9 zmienionych plików z 43 dodań i 590 usunięć

Wyświetl plik

@ -347,8 +347,18 @@ void AISDemodGUI::filter()
void AISDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
{
(void) widget;
(void) rollDown;
if (widget == ui->scopeContainer)
{
if (rollDown)
{
// Make wide enough for scope controls
setMinimumWidth(716);
}
else
{
setMinimumWidth(352);
}
}
}
void AISDemodGUI::onMenuDialogCalled(const QPoint &p)

Wyświetl plik

@ -31,8 +31,6 @@
#include "aisdemod.h"
#include "aisdemodsink.h"
#define AISDEMOD_MINS_MAXS 5
AISDemodSink::AISDemodSink(AISDemod *aisDemod) :
m_scopeSink(nullptr),
m_aisDemod(aisDemod),

Wyświetl plik

@ -125,7 +125,6 @@ private:
Real *m_train; // Training sequence to look for
int m_correlationLength;
int m_symbolPrev;
unsigned char m_bytes[AISDEMOD_MAX_BYTES];
crc16x25 m_crc;

Wyświetl plik

@ -390,8 +390,18 @@ void PagerDemodGUI::filter()
void PagerDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
{
(void) widget;
(void) rollDown;
if (widget == ui->scopeContainer)
{
if (rollDown)
{
// Make wide enough for scope controls
setMinimumWidth(716);
}
else
{
setMinimumWidth(352);
}
}
}
void PagerDemodGUI::onMenuDialogCalled(const QPoint &p)

Wyświetl plik

@ -178,8 +178,18 @@ void RadioClockGUI::on_timezone_currentIndexChanged(int index)
void RadioClockGUI::onWidgetRolled(QWidget* widget, bool rollDown)
{
(void) widget;
(void) rollDown;
if (widget == ui->scopeContainer)
{
if (rollDown)
{
// Make wide enough for scope controls
setMinimumWidth(716);
}
else
{
setMinimumWidth(352);
}
}
}
void RadioClockGUI::onMenuDialogCalled(const QPoint &p)

Wyświetl plik

@ -615,13 +615,13 @@ void PacketMod::webapiUpdateChannelSettings(
settings.m_reverseAPIChannelIndex = response.getPacketModSettings()->getReverseApiChannelIndex();
}
if (channelSettingsKeys.contains("udpEnabled")) {
settings.m_udpEnabled = response.getPacketDemodSettings()->getUdpEnabled();
settings.m_udpEnabled = response.getPacketModSettings()->getUdpEnabled();
}
if (channelSettingsKeys.contains("udpAddress")) {
settings.m_udpAddress = *response.getPacketDemodSettings()->getUdpAddress();
settings.m_udpAddress = *response.getPacketModSettings()->getUdpAddress();
}
if (channelSettingsKeys.contains("udpPort")) {
settings.m_udpPort = response.getPacketDemodSettings()->getUdpPort();
settings.m_udpPort = response.getPacketModSettings()->getUdpPort();
}
}
@ -930,7 +930,7 @@ void PacketMod::webapiFormatChannelSettings(
swgPacketModSettings->setData(new QString(settings.m_data));
}
if (channelSettingsKeys.contains("bpf") || force) {
swgPacketModSettings->setBpf(settings.m_preEmphasis ? 1 : 0);
swgPacketModSettings->setBpf(settings.m_bpf ? 1 : 0);
}
if (channelSettingsKeys.contains("bpfLowCutoff") || force) {
swgPacketModSettings->setBpfLowCutoff(settings.m_bpfLowCutoff);

Wyświetl plik

@ -476,6 +476,8 @@ PacketModGUI::PacketModGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseb
ui->spectrumGUI->setBuddies(m_spectrumVis, ui->glSpectrum);
ui->spectrumContainer->setVisible(false);
displaySettings();
applySettings();
}

Wyświetl plik

@ -35,7 +35,7 @@
</font>
</property>
<property name="windowTitle">
<string>GS-232 Rotator Controller</string>
<string>AIS</string>
</property>
<widget class="QWidget" name="tableContainer" native="true">
<property name="geometry">

Wyświetl plik

@ -1,576 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>PERTesterGUI</class>
<widget class="RollupWidget" name="PERTesterGUI">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>350</width>
<height>430</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>320</width>
<height>100</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>350</width>
<height>16777215</height>
</size>
</property>
<property name="font">
<font>
<family>Liberation Sans</family>
<pointsize>9</pointsize>
</font>
</property>
<property name="windowTitle">
<string>GS-232 Rotator Controller</string>
</property>
<widget class="QWidget" name="settingsContainer" native="true">
<property name="geometry">
<rect>
<x>10</x>
<y>10</y>
<width>331</width>
<height>291</height>
</rect>
</property>
<property name="windowTitle">
<string>Settings</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>3</number>
</property>
<property name="leftMargin">
<number>2</number>
</property>
<property name="topMargin">
<number>2</number>
</property>
<property name="rightMargin">
<number>2</number>
</property>
<property name="bottomMargin">
<number>2</number>
</property>
<item>
<layout class="QHBoxLayout" name="controlLayout">
<item>
<widget class="ButtonSwitch" name="startStop">
<property name="toolTip">
<string>Start/stop PER Test</string>
</property>
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../../../sdrgui/resources/res.qrc">
<normaloff>:/play.png</normaloff>
<normalon>:/stop.png</normalon>:/play.png</iconset>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="resetStats">
<property name="toolTip">
<string>Reset statistics</string>
</property>
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../../../sdrgui/resources/res.qrc">
<normaloff>:/recycle.png</normaloff>:/recycle.png</iconset>
</property>
</widget>
</item>
<item>
<spacer name="buttonsHorizontalSpacer">
<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>
<item>
<layout class="QGridLayout" name="gridLayout">
<item row="2" column="0">
<widget class="QLabel" name="startLabel">
<property name="text">
<string>Start test</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QSpinBox" name="packetCount">
<property name="toolTip">
<string>Number of packets to transmit</string>
</property>
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>2000000000</number>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="start">
<property name="toolTip">
<string>When to start the test, after the start button is pressed</string>
</property>
<item>
<property name="text">
<string>Immediately</string>
</property>
</item>
<item>
<property name="text">
<string>On satellite AOS</string>
</property>
</item>
<item>
<property name="text">
<string>On satellite mid pass</string>
</property>
</item>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="packetCountLabel">
<property name="text">
<string>Packets</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QDoubleSpinBox" name="interval">
<property name="toolTip">
<string>Interval in seconds between packets</string>
</property>
<property name="decimals">
<number>3</number>
</property>
<property name="maximum">
<double>1000000.000000000000000</double>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="intervalLabel">
<property name="text">
<string>Interval (s)</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="satellitesLabel">
<property name="text">
<string>Satellites</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QLineEdit" name="satellites">
<property name="toolTip">
<string>Space separated list of satellite names to start the PER test on</string>
</property>
<property name="text">
<string>ISS</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLabel" name="packetLabel">
<property name="text">
<string>Packet</string>
</property>
</widget>
</item>
<item>
<widget class="QPlainTextEdit" name="packet">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="toolTip">
<string>Hex encoded packet to transmit.
Substitutions:
%{ax25.src=CALLSIGN}
%{ax25.dst=CALLSIGN}
%{num}
%{data=min,max}</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="ignoreLayout">
<item>
<widget class="QLabel" name="ignoreLabel">
<property name="text">
<string>Ignore</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="leadingLabel">
<property name="text">
<string>Leading</string>
</property>
</widget>
</item>
<item>
<widget class="QSpinBox" name="leading">
<property name="maximum">
<number>10000</number>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="trailingLabel">
<property name="text">
<string>Trailing</string>
</property>
</widget>
</item>
<item>
<widget class="QSpinBox" name="trailing">
<property name="maximum">
<number>10000</number>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="bytesLabel">
<property name="text">
<string>bytes</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="txLayout">
<item>
<widget class="QLabel" name="txUDPLabel">
<property name="text">
<string>TX UDP</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="txUDPAddress">
<property name="minimumSize">
<size>
<width>120</width>
<height>0</height>
</size>
</property>
<property name="focusPolicy">
<enum>Qt::ClickFocus</enum>
</property>
<property name="toolTip">
<string>Destination UDP address</string>
</property>
<property name="inputMask">
<string>000.000.000.000</string>
</property>
<property name="text">
<string>127.0.0.1</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="txUDPSeparator">
<property name="text">
<string>:</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="txUDPPort">
<property name="minimumSize">
<size>
<width>50</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>50</width>
<height>16777215</height>
</size>
</property>
<property name="focusPolicy">
<enum>Qt::ClickFocus</enum>
</property>
<property name="toolTip">
<string>Destination UDP port</string>
</property>
<property name="inputMask">
<string>00000</string>
</property>
<property name="text">
<string>9997</string>
</property>
</widget>
</item>
<item>
<spacer name="txHorizontalSpacer">
<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>
<item>
<layout class="QHBoxLayout" name="channelLayout">
<item>
<widget class="QLabel" name="rxUDPLabel">
<property name="text">
<string>RX UDP</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="rxUDPAddress">
<property name="minimumSize">
<size>
<width>120</width>
<height>0</height>
</size>
</property>
<property name="focusPolicy">
<enum>Qt::ClickFocus</enum>
</property>
<property name="toolTip">
<string>Destination UDP address</string>
</property>
<property name="inputMask">
<string>000.000.000.000</string>
</property>
<property name="text">
<string>127.0.0.1</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="rxUDPSeparator">
<property name="text">
<string>:</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="rxUDPPort">
<property name="minimumSize">
<size>
<width>50</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>50</width>
<height>16777215</height>
</size>
</property>
<property name="focusPolicy">
<enum>Qt::ClickFocus</enum>
</property>
<property name="toolTip">
<string>Destination UDP port</string>
</property>
<property name="inputMask">
<string>00000</string>
</property>
<property name="text">
<string>9998</string>
</property>
</widget>
</item>
<item>
<spacer name="rxHorizontalSpacer">
<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>
<widget class="QWidget" name="statsContainer" native="true">
<property name="geometry">
<rect>
<x>10</x>
<y>310</y>
<width>331</width>
<height>91</height>
</rect>
</property>
<property name="windowTitle">
<string>Statistics</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<property name="spacing">
<number>3</number>
</property>
<property name="leftMargin">
<number>2</number>
</property>
<property name="topMargin">
<number>2</number>
</property>
<property name="rightMargin">
<number>2</number>
</property>
<property name="bottomMargin">
<number>2</number>
</property>
<item>
<layout class="QGridLayout" name="statsLayout">
<item row="2" column="1">
<widget class="QLabel" name="receivedMatchedText">
<property name="toolTip">
<string>Number of packets received that match a transmitted packet</string>
</property>
<property name="text">
<string>0</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="receivedMatchedLabel">
<property name="text">
<string>Received and Matched</string>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="perLabel">
<property name="text">
<string>PER</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QLabel" name="perText">
<property name="text">
<string>0%</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="transmittedText">
<property name="toolTip">
<string>Number of packets that have been transmitted</string>
</property>
<property name="text">
<string>0</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="transmittedLabel">
<property name="text">
<string>Transmitted</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="receivedUnmatchedLabel">
<property name="text">
<string>Received and Unmatched</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QLabel" name="receivedUnmatchedText">
<property name="toolTip">
<string>Number of packets received that do not match a transmitted packet</string>
</property>
<property name="text">
<string>0</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
</widget>
<customwidgets>
<customwidget>
<class>RollupWidget</class>
<extends>QWidget</extends>
<header>gui/rollupwidget.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>ButtonSwitch</class>
<extends>QToolButton</extends>
<header>gui/buttonswitch.h</header>
</customwidget>
</customwidgets>
<tabstops>
<tabstop>startStop</tabstop>
</tabstops>
<resources>
<include location="../../../sdrgui/resources/res.qrc"/>
</resources>
<connections/>
</ui>