Merge pull request #6992 from symless/SYNERGY-936-UI-issues-and-use-cases

SYNERGY-936 UI issues and use cases
This commit is contained in:
Andrey Batyiev 2021-05-13 03:41:38 +03:00 committed by GitHub
commit fbf8331b25
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
14 changed files with 823 additions and 990 deletions

View file

@ -11,6 +11,7 @@ Bug fixes:
- #6976 Fix windows builds - #6976 Fix windows builds
- #6979 Manual config error in client mode - #6979 Manual config error in client mode
- #6983 Fix that mac client listens on ipv4 only - #6983 Fix that mac client listens on ipv4 only
- #6992 UI issues and use cases
Enhancements: Enhancements:
- #6954 Move language selection to advanced section - #6954 Move language selection to advanced section

View file

@ -9,7 +9,6 @@
<file>image/about.png</file> <file>image/about.png</file>
<file>image/about-dark.png</file> <file>image/about-dark.png</file>
<file>lang/Languages.xml</file> <file>lang/Languages.xml</file>
<file>icons/16x16/money.png</file>
<file>image/spinning-wheel.gif</file> <file>image/spinning-wheel.gif</file>
<file>icons/16x16/padlock.png</file> <file>icons/16x16/padlock.png</file>
<file>icons/16x16/synergy-transfering.png</file> <file>icons/16x16/synergy-transfering.png</file>
@ -21,5 +20,6 @@
<file>icons/64x64/synergy-light-connected.png</file> <file>icons/64x64/synergy-light-connected.png</file>
<file>image/welcome.png</file> <file>image/welcome.png</file>
<file>icons/64x64/folder.png</file> <file>icons/64x64/folder.png</file>
<file>fonts/Arial.ttf</file>
</qresource> </qresource>
</RCC> </RCC>

BIN
src/gui/res/fonts/Arial.ttf Normal file

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 738 B

View file

@ -30,7 +30,7 @@
<item> <item>
<widget class="QLabel" name="label_5"> <widget class="QLabel" name="label_5">
<property name="text"> <property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;This can be found on your &lt;a href=&quot;https://symless.com/account/?source=gui&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;account&lt;/span&gt;&lt;/a&gt; page.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string> <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;This can be found on your &lt;a href=&quot;https://symless.com/account/?source=gui&quot;&gt;&lt;span style=&quot; text-decoration: none; color: #4285F4;&quot;&gt;account&lt;/span&gt;&lt;/a&gt; page.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property> </property>
<property name="openExternalLinks"> <property name="openExternalLinks">
<bool>true</bool> <bool>true</bool>
@ -49,8 +49,8 @@
<string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt; <string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt; &lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; } p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Sans'; font-size:10pt; font-weight:400; font-style:normal;&quot;&gt; &lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'.AppleSystemUIFont'; font-size:13pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string> &lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Sans'; font-size:10pt;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property> </property>
<property name="acceptRichText"> <property name="acceptRichText">
<bool>false</bool> <bool>false</bool>
@ -73,20 +73,19 @@ p, li { white-space: pre-wrap; }
<number>8</number> <number>8</number>
</property> </property>
<item> <item>
<widget class="QLabel" name="label_3"> <widget class="QLabel" name="m_trialLabel">
<property name="styleSheet">
<string notr="true">font-size: 13px;
font-weight: 700;
padding: 3px 5px;
border-radius: 3px;
background-color: #EC4C47;
color: #ffffff;
top: 3px;</string>
</property>
<property name="text"> <property name="text">
<string/> <string/>
</property> </property>
<property name="pixmap">
<pixmap resource="Synergy.qrc">:/res/icons/16x16/money.png</pixmap>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="m_trialLabel">
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Your trial has expired. &lt;a href=&quot;http://symless.com/pricing?src=gui&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;Buy now!&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="openExternalLinks"> <property name="openExternalLinks">
<bool>true</bool> <bool>true</bool>
</property> </property>
@ -123,9 +122,7 @@ p, li { white-space: pre-wrap; }
<tabstops> <tabstops>
<tabstop>m_pTextEditSerialKey</tabstop> <tabstop>m_pTextEditSerialKey</tabstop>
</tabstops> </tabstops>
<resources> <resources/>
<include location="Synergy.qrc"/>
</resources>
<connections> <connections>
<connection> <connection>
<sender>buttonBox</sender> <sender>buttonBox</sender>

View file

@ -174,27 +174,19 @@ LicenseManager::getTrialNotice() const
QString Notice; QString Notice;
if (m_serialKey.isExpired(::time(0))){ if (m_serialKey.isExpired(::time(0))){
Notice = "<html><head/><body><p>Your %1 trial has expired. <a href=" Notice = "<html><head/><body><p>"
"\"https://members.symless.com/purchase\">" "Trial expired - "
"<span style=\"text-decoration: underline;color:#0000ff;\">" "<a href=\"https://members.symless.com/purchase\" style=\"color: #FFFFFF;\">Buy now</a>"
"Buy now!</span></a></p></body></html>"; "</p></body></html>";
Notice = Notice.arg(LicenseManager::getEditionName(activeEdition()));
} }
else{ else{
Notice = "<html><head/><body><p><span style=\"" Notice = "<html><head/><body><p>"
"font-weight:600;\">%1</span> day%3 of " "Trial expires in %1 day%2 - "
"your %2 trial remain%5. <a href=" "<a href=\"https://members.symless.com/purchase\" style=\"color: #FFFFFF;\">Buy now</a>"
"\"https://members.symless.com/purchase\">"
"<span style=\"text-decoration: underline;"
" color:#0000ff;\">Buy now!</span></a>"
"</p></body></html>"; "</p></body></html>";
time_t daysLeft = m_serialKey.daysLeft(::time(0)); time_t daysLeft = m_serialKey.daysLeft(::time(0));
Notice = Notice Notice = Notice.arg (daysLeft).arg ((daysLeft == 1) ? "" : "s");
.arg (daysLeft)
.arg (LicenseManager::getEditionName(activeEdition()))
.arg ((daysLeft == 1) ? "" : "s")
.arg ((daysLeft == 1) ? "s" : "");
} }
return Notice; return Notice;
@ -206,18 +198,15 @@ LicenseManager::getTemporaryNotice() const
QString Notice; QString Notice;
if (m_serialKey.isExpired(::time(0))) { if (m_serialKey.isExpired(::time(0))) {
Notice = "<html><head/><body><p>Your license has expired. <a href=" Notice = "<html><head/><body><p>"
"\"https://members.symless.com/purchase\">" "License expired - "
"<span style=\"text-decoration: underline;color:#0000ff;\">" "<a href=\"https://members.symless.com/purchase\" style=\"color: #FFFFFF;\">Renew now</a>"
"Renew now!</span></a></p></body></html>"; "</p></body></html>";
} }
else if (m_serialKey.isExpiring(::time(0))) { else if (m_serialKey.isExpiring(::time(0))) {
Notice = "<html><head/><body><p><span style=\"" Notice = "<html><head/><body><p>"
"font-weight:600;\">%1</span> day%2 " "License expires in %1 day%2 - "
"before your license expires.<a href=" "<a href=\"https://members.symless.com/purchase\" style=\"color: #FFFFFF;\">Renew now</a>"
"\"https://members.symless.com/purchase\">"
"<span style=\"text-decoration: underline;"
" color:#0000ff;\">Renew now!</span></a>"
"</p></body></html>"; "</p></body></html>";
time_t daysLeft = m_serialKey.daysLeft(::time(0)); time_t daysLeft = m_serialKey.daysLeft(::time(0));

View file

@ -130,9 +130,9 @@ MainWindow::MainWindow (AppConfig& appConfig,
m_pWidgetUpdate->hide(); m_pWidgetUpdate->hide();
m_VersionChecker.setApp(appPath(appConfig.synergycName())); m_VersionChecker.setApp(appPath(appConfig.synergycName()));
m_pLabelScreenName->setText(appConfig.screenName()); updateScreenName();
connect(m_AppConfig, SIGNAL(screenNameChanged()), this, SLOT(updateScreenName())); connect(m_AppConfig, SIGNAL(screenNameChanged()), this, SLOT(updateScreenName()));
m_pLabelIpAddresses->setText(getIPAddresses()); m_pLabelIpAddresses->setText(tr("This computers IP addresses: %1").arg(getIPAddresses()));
#if defined(Q_OS_WIN) #if defined(Q_OS_WIN)
// ipc must always be enabled, so that we can disable command when switching to desktop mode. // ipc must always be enabled, so that we can disable command when switching to desktop mode.
@ -151,7 +151,7 @@ MainWindow::MainWindow (AppConfig& appConfig,
setMinimumSize(size()); setMinimumSize(size());
#endif #endif
m_trialWidget->hide(); m_trialLabel->hide();
// hide padlock icon // hide padlock icon
secureSocket(false); secureSocket(false);
@ -1072,7 +1072,7 @@ QString MainWindow::getIPAddresses()
// usually 192.168.x.x is a useful ip for the user, so indicate // usually 192.168.x.x is a useful ip for the user, so indicate
// this by making it bold. // this by making it bold.
if (!hinted && address.isInSubnet(localnet)) { if (!hinted && address.isInSubnet(localnet)) {
QString format = "<b>%1</b>"; QString format = "<span style=\"color:#4285F4;\">%1</span>";
result.append(format.arg(address.toString())); result.append(format.arg(address.toString()));
hinted = true; hinted = true;
} }
@ -1143,11 +1143,11 @@ void MainWindow::InvalidLicense()
void MainWindow::showLicenseNotice(const QString& notice) void MainWindow::showLicenseNotice(const QString& notice)
{ {
this->m_trialWidget->hide(); this->m_trialLabel->hide();
if (!notice.isEmpty()) { if (!notice.isEmpty()) {
this->m_trialLabel->setText(notice); this->m_trialLabel->setText(notice);
this->m_trialWidget->show(); this->m_trialLabel->show();
} }
setWindowTitle (m_LicenseManager->activeEditionName()); setWindowTitle (m_LicenseManager->activeEditionName());
@ -1351,7 +1351,7 @@ void MainWindow::secureSocket(bool secureSocket)
} }
} }
void MainWindow::on_m_pSettingsLink_linkActivated(const QString&) void MainWindow::on_m_pLabelComputerName_linkActivated(const QString&)
{ {
m_pActionSettings->trigger(); m_pActionSettings->trigger();
} }
@ -1374,7 +1374,7 @@ void MainWindow::windowStateChanged()
void MainWindow::updateScreenName() void MainWindow::updateScreenName()
{ {
m_pLabelScreenName->setText(appConfig().screenName()); m_pLabelComputerName->setText(tr("This computers name: %1 (<a href=\"#\" style=\"text-decoration: none; color: #4285F4;\">Preferences</a>)").arg(appConfig().screenName()));
serverConfig().updateServerName(); serverConfig().updateServerName();
} }

View file

@ -252,7 +252,7 @@ private slots:
void on_m_pButtonApply_clicked(); void on_m_pButtonApply_clicked();
void on_windowShown(); void on_windowShown();
void on_m_pSettingsLink_linkActivated(const QString &link); void on_m_pLabelComputerName_linkActivated(const QString &link);
void on_m_pLabelFingerprint_linkActivated(const QString& link); void on_m_pLabelFingerprint_linkActivated(const QString& link);
void on_m_pComboServerList_currentIndexChanged(const QString &arg1); void on_m_pComboServerList_currentIndexChanged(const QString &arg1);

View file

@ -7,7 +7,7 @@
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>720</width> <width>720</width>
<height>797</height> <height>658</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy"> <property name="sizePolicy">
@ -19,7 +19,7 @@
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>720</width> <width>720</width>
<height>0</height> <height>552</height>
</size> </size>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -27,57 +27,12 @@
</property> </property>
<widget class="QWidget" name="centralwidget"> <widget class="QWidget" name="centralwidget">
<layout class="QVBoxLayout" name="verticalLayout_2"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <property name="spacing">
<widget class="QWidget" name="m_trialWidget" native="true"> <number>0</number>
<layout class="QHBoxLayout" name="horizontalLayout_5"> </property>
<property name="leftMargin"> <property name="topMargin">
<number>2</number> <number>20</number>
</property> </property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>8</number>
</property>
<item>
<widget class="QLabel" name="label_3">
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../res/Synergy.qrc">:/res/icons/16x16/warning.png</pixmap>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="m_trialLabel">
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-weight:600;&quot;&gt;%1&lt;/span&gt; days of your Synergy Pro trial remain. &lt;a href=&quot;http://symless.com/pricing?src=gui&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;Buy now!&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</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>
</layout>
</widget>
</item>
<item> <item>
<widget class="QWidget" name="m_pWidgetUpdate" native="true"> <widget class="QWidget" name="m_pWidgetUpdate" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_2"> <layout class="QHBoxLayout" name="horizontalLayout_2">
@ -133,192 +88,51 @@
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QWidget" name="m_pWidgetComputerName" native="true"> <widget class="QLabel" name="m_pLabelComputerName">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>582</width> <width>0</width>
<height>15</height> <height>0</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>16777215</width> <width>65535</width>
<height>20</height> <height>65535</height>
</size> </size>
</property> </property>
<layout class="QHBoxLayout" name="horizontalLayout_7"> <property name="font">
<property name="spacing"> <font>
<number>0</number> <family>Arial</family>
</property> <kerning>true</kerning>
<property name="leftMargin"> </font>
<number>0</number> </property>
</property> <property name="text">
<property name="topMargin"> <string notr="true">This computers name:</string>
<number>0</number> </property>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="m_pLabelComputerName">
<property name="minimumSize">
<size>
<width>135</width>
<height>15</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>135</width>
<height>20</height>
</size>
</property>
<property name="font">
<font>
<family>Arial</family>
<kerning>true</kerning>
</font>
</property>
<property name="text">
<string>This computers name:</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="m_pLabelScreenName">
<property name="sizePolicy">
<sizepolicy hsizetype="Maximum" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>15</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>20</height>
</size>
</property>
<property name="font">
<font>
<family>Arial</family>
</font>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="textFormat">
<enum>Qt::AutoText</enum>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="m_pSettingsLink">
<property name="minimumSize">
<size>
<width>0</width>
<height>15</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>20</height>
</size>
</property>
<property name="font">
<font>
<family>Arial</family>
<weight>50</weight>
<italic>false</italic>
<bold>false</bold>
</font>
</property>
<property name="styleSheet">
<string notr="true"/>
</property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p style=&quot;margin-left: 5px;&quot;&gt;(&lt;a href=&quot;#&quot;&gt;&lt;span style=&quot; text-decoration: none; font-size: 13px; color:#007af4;&quot;&gt;Settings&lt;/span&gt;&lt;/a&gt;)&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="margin">
<number>0</number>
</property>
</widget>
</item>
</layout>
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QWidget" name="m_pWidgetIPAddress" native="true"> <spacer name="verticalSpacer_5">
<property name="sizePolicy"> <property name="orientation">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <enum>Qt::Vertical</enum>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property> </property>
<property name="minimumSize"> <property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size> <size>
<width>0</width> <width>20</width>
<height>20</height> <height>14</height>
</size> </size>
</property> </property>
<layout class="QHBoxLayout" name="horizontalLayout_6"> </spacer>
<property name="spacing"> </item>
<number>0</number> <item>
</property> <widget class="QLabel" name="m_pLabelIpAddresses">
<property name="leftMargin"> <property name="text">
<number>0</number> <string notr="true">This computers IP addresses:</string>
</property> </property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="label_2">
<property name="minimumSize">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>190</width>
<height>16777215</height>
</size>
</property>
<property name="text">
<string>This computers IP addresses:</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="m_pLabelIpAddresses">
<property name="text">
<string notr="true"/>
</property>
</widget>
</item>
</layout>
</widget> </widget>
</item> </item>
<item> <item>
@ -332,13 +146,13 @@
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>0</width> <width>0</width>
<height>270</height> <height>0</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="maximumSize">
<size> <size>
<width>16777215</width> <width>16777215</width>
<height>270</height> <height>16777215</height>
</size> </size>
</property> </property>
<layout class="QHBoxLayout" name="horizontalLayout_8"> <layout class="QHBoxLayout" name="horizontalLayout_8">
@ -349,62 +163,45 @@
<number>0</number> <number>0</number>
</property> </property>
<property name="topMargin"> <property name="topMargin">
<number>22</number> <number>28</number>
</property> </property>
<property name="rightMargin"> <property name="rightMargin">
<number>0</number> <number>0</number>
</property> </property>
<property name="bottomMargin"> <property name="bottomMargin">
<number>0</number> <number>8</number>
</property> </property>
<item> <item>
<widget class="QGroupBox" name="m_pGroupServer"> <widget class="QFrame" name="m_pGroupServer">
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>340</width> <width>0</width>
<height>248</height> <height>250</height>
</size> </size>
</property> </property>
<property name="font"> <property name="maximumSize">
<font> <size>
<kerning>true</kerning> <width>16777215</width>
</font> <height>250</height>
</size>
</property> </property>
<property name="styleSheet"> <property name="styleSheet">
<string notr="true">QGroupBox::title { <string notr="true">.QFrame{
subcontrol-origin: padding; border: 1px solid rgba(192,192,192, 0.2);;
left: 7px; border-radius: 4px;
} background-color: rgba(192,192,192, 0.1);
</string> }</string>
</property> </property>
<property name="title"> <property name="frameShape">
<string/> <enum>QFrame::StyledPanel</enum>
</property> </property>
<property name="checkable"> <property name="frameShadow">
<bool>false</bool> <enum>QFrame::Raised</enum>
</property> </property>
<property name="checked"> <layout class="QVBoxLayout" name="verticalLayout">
<bool>false</bool>
</property>
<layout class="QVBoxLayout" name="ServerLayout">
<property name="spacing">
<number>9</number>
</property>
<property name="topMargin"> <property name="topMargin">
<number>11</number> <number>11</number>
</property> </property>
<property name="rightMargin">
<number>5</number>
</property>
<property name="bottomMargin">
<number>5</number>
</property>
<item> <item>
<widget class="QRadioButton" name="m_pRadioGroupServer"> <widget class="QRadioButton" name="m_pRadioGroupServer">
<property name="sizePolicy"> <property name="sizePolicy">
@ -463,36 +260,29 @@
</widget> </widget>
</item> </item>
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_3"> <widget class="QLabel" name="m_pLabelFingerprint">
<property name="spacing"> <property name="sizePolicy">
<number>6</number> <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property> </property>
<item> <property name="maximumSize">
<widget class="QLabel" name="m_pLabelFingerprint"> <size>
<property name="sizePolicy"> <width>16777215</width>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <height>20</height>
<horstretch>0</horstretch> </size>
<verstretch>0</verstretch> </property>
</sizepolicy> <property name="text">
</property> <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;TLS/SSL active - &lt;a href=&quot;#&quot; style=&quot;text-decoration:none; color: #4285F4;&quot;&gt;view&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
<property name="maximumSize"> </property>
<size> <property name="textFormat">
<width>16777215</width> <enum>Qt::RichText</enum>
<height>20</height> </property>
</size> <property name="indent">
</property> <number>20</number>
<property name="text"> </property>
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;TLS/SSL active - &lt;a href=&quot;#&quot;&gt;view&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string> </widget>
</property>
<property name="textFormat">
<enum>Qt::RichText</enum>
</property>
<property name="indent">
<number>20</number>
</property>
</widget>
</item>
</layout>
</item> </item>
<item> <item>
<spacer name="verticalSpacer_2"> <spacer name="verticalSpacer_2">
@ -547,53 +337,33 @@
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QGroupBox" name="m_pGroupClient"> <widget class="QFrame" name="m_pGroupClient">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize"> <property name="minimumSize">
<size>
<width>340</width>
<height>248</height>
</size>
</property>
<property name="baseSize">
<size> <size>
<width>0</width> <width>0</width>
<height>0</height> <height>250</height>
</size> </size>
</property> </property>
<property name="font"> <property name="maximumSize">
<font> <size>
<kerning>true</kerning> <width>16777215</width>
</font> <height>250</height>
</size>
</property> </property>
<property name="styleSheet"> <property name="styleSheet">
<string notr="true">QGroupBox::title { <string notr="true">.QFrame{
subcontrol-origin: padding; border: 1px solid rgba(192,192,192, 0.2);
left: 7px; border-radius: 4px;
} background-color: rgba(192,192,192, 0.1);
</string> }</string>
</property> </property>
<property name="title"> <property name="frameShape">
<string/> <enum>QFrame::StyledPanel</enum>
</property> </property>
<property name="checkable"> <property name="frameShadow">
<bool>false</bool> <enum>QFrame::Raised</enum>
</property> </property>
<property name="checked"> <layout class="QVBoxLayout" name="verticalLayout_5">
<bool>false</bool>
</property>
<layout class="QVBoxLayout" name="ClientLayout">
<property name="spacing">
<number>9</number>
</property>
<property name="leftMargin">
<number>9</number>
</property>
<property name="topMargin"> <property name="topMargin">
<number>11</number> <number>11</number>
</property> </property>
@ -772,16 +542,65 @@
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QGroupBox" name="m_pGroupLog"> <widget class="QLabel" name="m_pLabelLogs">
<property name="font"> <property name="styleSheet">
<font> <string notr="true"/>
<kerning>true</kerning>
</font>
</property> </property>
<property name="title"> <property name="text">
<string>Log</string> <string>Logs</string>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> </widget>
</item>
<item>
<spacer name="verticalSpacer_7">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>5</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QFrame" name="m_pGroupLog">
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">.QFrame{
border: 1px solid rgba(192,192,192, 0.2);;
border-radius: 4px;
background-color: rgba(192,192,192, 0.1);
}</string>
</property>
<property name="frameShape">
<enum>QFrame::StyledPanel</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Raised</enum>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<property name="leftMargin">
<number>8</number>
</property>
<property name="topMargin">
<number>8</number>
</property>
<property name="rightMargin">
<number>8</number>
</property>
<property name="bottomMargin">
<number>8</number>
</property>
<item> <item>
<widget class="QPlainTextEdit" name="m_pLogOutput"> <widget class="QPlainTextEdit" name="m_pLogOutput">
<property name="sizePolicy"> <property name="sizePolicy">
@ -818,9 +637,15 @@
</item> </item>
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout"> <layout class="QHBoxLayout" name="horizontalLayout">
<property name="spacing">
<number>6</number>
</property>
<property name="sizeConstraint"> <property name="sizeConstraint">
<enum>QLayout::SetDefaultConstraint</enum> <enum>QLayout::SetDefaultConstraint</enum>
</property> </property>
<property name="topMargin">
<number>16</number>
</property>
<item> <item>
<widget class="QLabel" name="m_pLabelPadlock"> <widget class="QLabel" name="m_pLabelPadlock">
<property name="enabled"> <property name="enabled">
@ -854,6 +679,58 @@
</property> </property>
</spacer> </spacer>
</item> </item>
<item>
<widget class="QLabel" name="m_trialLabel">
<property name="font">
<font>
<family>Arial</family>
<pointsize>-1</pointsize>
<weight>87</weight>
<bold>true</bold>
</font>
</property>
<property name="autoFillBackground">
<bool>false</bool>
</property>
<property name="styleSheet">
<string notr="true">font-size: 13px;
font-weight: 700;
padding: 3px 5px;
border-radius: 3px;
background-color: #EC4C47;
color: #ffffff;
top: 3px;</string>
</property>
<property name="text">
<string notr="true"/>
</property>
<property name="alignment">
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
</property>
<property name="margin">
<number>0</number>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item> <item>
<widget class="QPushButton" name="m_pButtonApply"> <widget class="QPushButton" name="m_pButtonApply">
<property name="enabled"> <property name="enabled">

View file

@ -29,6 +29,12 @@ QSynergyApplication::QSynergyApplication(int& argc, char** argv) :
m_Translator(NULL) m_Translator(NULL)
{ {
s_Instance = this; s_Instance = this;
QFontDatabase::addApplicationFont(":/res/fonts/Arial.ttf");
QFont Arial("Arial");
Arial.setPixelSize(13);
Arial.setStyleHint(QFont::SansSerif);
setFont(Arial);
} }
QSynergyApplication::~QSynergyApplication() QSynergyApplication::~QSynergyApplication()

View file

@ -57,8 +57,6 @@ ScreenSettingsDialog::ScreenSettingsDialog(QWidget* parent, Screen* pScreen,cons
m_pCheckBoxNumLock->setChecked(m_pScreen->fix(Screen::NumLock)); m_pCheckBoxNumLock->setChecked(m_pScreen->fix(Screen::NumLock));
m_pCheckBoxScrollLock->setChecked(m_pScreen->fix(Screen::ScrollLock)); m_pCheckBoxScrollLock->setChecked(m_pScreen->fix(Screen::ScrollLock));
m_pCheckBoxXTest->setChecked(m_pScreen->fix(Screen::XTest)); m_pCheckBoxXTest->setChecked(m_pScreen->fix(Screen::XTest));
resize(400, 625);
} }
void ScreenSettingsDialog::accept() void ScreenSettingsDialog::accept()

File diff suppressed because it is too large Load diff

View file

@ -55,6 +55,7 @@ int main(int argc, char* argv[])
/* Workaround for QTBUG-40332 - "High ping when QNetworkAccessManager is instantiated" */ /* Workaround for QTBUG-40332 - "High ping when QNetworkAccessManager is instantiated" */
::setenv ("QT_BEARER_POLL_TIMEOUT", "-1", 1); ::setenv ("QT_BEARER_POLL_TIMEOUT", "-1", 1);
#endif #endif
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
QCoreApplication::setOrganizationName("Synergy"); QCoreApplication::setOrganizationName("Synergy");
QCoreApplication::setOrganizationDomain("http://symless.com/"); QCoreApplication::setOrganizationDomain("http://symless.com/");
QCoreApplication::setApplicationName("Synergy"); QCoreApplication::setApplicationName("Synergy");

View file

@ -29,7 +29,7 @@ namespace validators
ScreenNameValidator::ScreenNameValidator(QLineEdit* parent, QLabel* errors, const ScreenList* pScreens) : ScreenNameValidator::ScreenNameValidator(QLineEdit* parent, QLabel* errors, const ScreenList* pScreens) :
LineEditValidator(parent, errors) LineEditValidator(parent, errors)
{ {
addValidator(std::make_unique<EmptyStringValidator>("Computer name can't be empty")); addValidator(std::make_unique<EmptyStringValidator>("Computer name is required"));
addValidator(std::make_unique<SpacesValidator>("Remove spaces")); addValidator(std::make_unique<SpacesValidator>("Remove spaces"));
addValidator(std::make_unique<RegExpValidator>("Remove unsupported characters", QRegExp("[a-z0-9\\._-]{,255}", Qt::CaseInsensitive))); addValidator(std::make_unique<RegExpValidator>("Remove unsupported characters", QRegExp("[a-z0-9\\._-]{,255}", Qt::CaseInsensitive)));
addValidator(std::make_unique<ScreenDuplicationsValidator>("A computer with this name already exists", parent ? parent->text() : "", pScreens)); addValidator(std::make_unique<ScreenDuplicationsValidator>("A computer with this name already exists", parent ? parent->text() : "", pScreens));