Skip to content

Commit 35eea22

Browse files
committedSep 12, 2017
Rework QgsNewHttpConnection layout so that both WFS and WMS settings
can be shown simultaneously
1 parent 6134950 commit 35eea22

File tree

4 files changed

+309
-233
lines changed

4 files changed

+309
-233
lines changed
 

‎python/gui/qgsnewhttpconnection.sip‎

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,28 +32,40 @@ class QgsNewHttpConnection : QDialog
3232
typedef QFlags<QgsNewHttpConnection::ConnectionType> ConnectionTypes;
3333

3434

35+
enum Flag
36+
{
37+
FlagShowTestConnection,
38+
};
39+
typedef QFlags<QgsNewHttpConnection::Flag> Flags;
40+
41+
3542
QgsNewHttpConnection( QWidget *parent /TransferThis/ = 0,
3643
QgsNewHttpConnection::ConnectionTypes types = ConnectionWms,
3744
const QString &baseKey = "qgis/connections-wms/",
3845
const QString &connectionName = QString(),
46+
QgsNewHttpConnection::Flags flags = 0,
3947
Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags );
4048
%Docstring
4149
Constructor for QgsNewHttpConnection.
4250

4351
The ``types`` argument dictates which connection type settings should be
4452
shown in the dialog.
53+
54+
The ``flags`` argument allows specifying flags which control the dialog behavior
55+
and appearance.
4556
%End
4657

4758
public slots:
59+
4860
virtual void accept();
4961

50-
void on_txtName_textChanged( const QString & );
51-
void on_txtUrl_textChanged( const QString & );
5262

5363
};
5464

5565
QFlags<QgsNewHttpConnection::ConnectionType> operator|(QgsNewHttpConnection::ConnectionType f1, QFlags<QgsNewHttpConnection::ConnectionType> f2);
5666

67+
QFlags<QgsNewHttpConnection::Flag> operator|(QgsNewHttpConnection::Flag f1, QFlags<QgsNewHttpConnection::Flag> f2);
68+
5769

5870
/************************************************************************
5971
* This file has been generated automatically from *

‎src/gui/qgsnewhttpconnection.cpp‎

Lines changed: 69 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
#include <QRegExp>
2626
#include <QRegExpValidator>
2727

28-
QgsNewHttpConnection::QgsNewHttpConnection( QWidget *parent, ConnectionTypes types, const QString &baseKey, const QString &connectionName, Qt::WindowFlags fl )
28+
QgsNewHttpConnection::QgsNewHttpConnection( QWidget *parent, ConnectionTypes types, const QString &baseKey, const QString &connectionName, QgsNewHttpConnection::Flags flags, Qt::WindowFlags fl )
2929
: QDialog( parent, fl )
3030
, mTypes( types )
3131
, mBaseKey( baseKey )
@@ -76,8 +76,23 @@ QgsNewHttpConnection::QgsNewHttpConnection( QWidget *parent, ConnectionTypes typ
7676
txtUrl->setText( settings.value( key + "/url" ).toString() );
7777

7878
cbxIgnoreGetMapURI->setChecked( settings.value( key + "/ignoreGetMapURI", false ).toBool() );
79-
cbxIgnoreAxisOrientation->setChecked( settings.value( key + "/ignoreAxisOrientation", false ).toBool() );
80-
cbxInvertAxisOrientation->setChecked( settings.value( key + "/invertAxisOrientation", false ).toBool() );
79+
if ( mTypes & ConnectionWfs && mTypes & ConnectionWms )
80+
{
81+
cbxWfsIgnoreAxisOrientation->setChecked( settings.value( key + "/wfs/ignoreAxisOrientation", false ).toBool() );
82+
cbxWfsInvertAxisOrientation->setChecked( settings.value( key + "/wfs/invertAxisOrientation", false ).toBool() );
83+
cbxWmsIgnoreAxisOrientation->setChecked( settings.value( key + "/wms/ignoreAxisOrientation", false ).toBool() );
84+
cbxWmsInvertAxisOrientation->setChecked( settings.value( key + "/wms/invertAxisOrientation", false ).toBool() );
85+
}
86+
else if ( mTypes & ConnectionWfs )
87+
{
88+
cbxWfsIgnoreAxisOrientation->setChecked( settings.value( key + "/ignoreAxisOrientation", false ).toBool() );
89+
cbxWfsInvertAxisOrientation->setChecked( settings.value( key + "/invertAxisOrientation", false ).toBool() );
90+
}
91+
else
92+
{
93+
cbxWmsIgnoreAxisOrientation->setChecked( settings.value( key + "/ignoreAxisOrientation", false ).toBool() );
94+
cbxWmsInvertAxisOrientation->setChecked( settings.value( key + "/invertAxisOrientation", false ).toBool() );
95+
}
8196
cbxIgnoreGetFeatureInfoURI->setChecked( settings.value( key + "/ignoreGetFeatureInfoURI", false ).toBool() );
8297
cbxSmoothPixmapTransform->setChecked( settings.value( key + "/smoothPixmapTransform", false ).toBool() );
8398

@@ -126,75 +141,65 @@ QgsNewHttpConnection::QgsNewHttpConnection( QWidget *parent, ConnectionTypes typ
126141
}
127142
}
128143

129-
if ( !( mTypes & ConnectionWms ) )
144+
if ( !( mTypes & ConnectionWms ) && !( mTypes & ConnectionWcs ) )
130145
{
131-
if ( !( mTypes & ConnectionWcs ) &&
132-
!( mTypes & ConnectionWfs ) )
133-
{
134-
cbxIgnoreAxisOrientation->setVisible( false );
135-
cbxInvertAxisOrientation->setVisible( false );
136-
mGroupBox->layout()->removeWidget( cbxIgnoreAxisOrientation );
137-
mGroupBox->layout()->removeWidget( cbxInvertAxisOrientation );
138-
}
139-
140-
if ( mTypes & ConnectionWfs )
141-
{
142-
cbxIgnoreAxisOrientation->setText( tr( "Ignore axis orientation (WFS 1.1/WFS 2.0)" ) );
143-
}
146+
mWmsOptionsGroupBox->setVisible( false );
147+
mGroupBox->layout()->removeWidget( mWmsOptionsGroupBox );
148+
}
149+
if ( !( mTypes & ConnectionWfs ) )
150+
{
151+
mWfsOptionsGroupBox->setVisible( false );
152+
mGroupBox->layout()->removeWidget( mWfsOptionsGroupBox );
153+
}
144154

145-
if ( mTypes & ConnectionWcs )
146-
{
147-
cbxIgnoreGetMapURI->setText( tr( "Ignore GetCoverage URI reported in capabilities" ) );
148-
cbxIgnoreAxisOrientation->setText( tr( "Ignore axis orientation" ) );
149-
}
150-
else
155+
if ( mTypes & ConnectionWcs )
156+
{
157+
cbxIgnoreGetMapURI->setText( tr( "Ignore GetCoverage URI reported in capabilities" ) );
158+
cbxWmsIgnoreAxisOrientation->setText( tr( "Ignore axis orientation" ) );
159+
if ( !( mTypes & ConnectionWms ) )
151160
{
152-
cbxIgnoreGetMapURI->setVisible( false );
153-
cbxSmoothPixmapTransform->setVisible( false );
154-
mGroupBox->layout()->removeWidget( cbxIgnoreGetMapURI );
155-
mGroupBox->layout()->removeWidget( cbxSmoothPixmapTransform );
156-
}
161+
mWmsOptionsGroupBox->setTitle( tr( "WCS Options" ) );
157162

158-
cbxIgnoreGetFeatureInfoURI->setVisible( false );
159-
mGroupBox->layout()->removeWidget( cbxIgnoreGetFeatureInfoURI );
163+
cbxIgnoreGetFeatureInfoURI->setVisible( false );
164+
mGroupBox->layout()->removeWidget( cbxIgnoreGetFeatureInfoURI );
160165

161-
cmbDpiMode->setVisible( false );
162-
mGroupBox->layout()->removeWidget( cmbDpiMode );
163-
lblDpiMode->setVisible( false );
164-
mGroupBox->layout()->removeWidget( lblDpiMode );
166+
cmbDpiMode->setVisible( false );
167+
mGroupBox->layout()->removeWidget( cmbDpiMode );
168+
lblDpiMode->setVisible( false );
169+
mGroupBox->layout()->removeWidget( lblDpiMode );
165170

166-
txtReferer->setVisible( false );
167-
mGroupBox->layout()->removeWidget( txtReferer );
168-
lblReferer->setVisible( false );
169-
mGroupBox->layout()->removeWidget( lblReferer );
171+
txtReferer->setVisible( false );
172+
mGroupBox->layout()->removeWidget( txtReferer );
173+
lblReferer->setVisible( false );
174+
mGroupBox->layout()->removeWidget( lblReferer );
175+
}
170176
}
171177

172-
if ( !( mTypes & ConnectionWfs ) )
178+
179+
if ( !( flags & FlagShowTestConnection ) )
173180
{
174-
lblVersion->setVisible( false );
175-
cmbVersion->setVisible( false );
176-
mGroupBox->layout()->removeWidget( cmbVersion );
177-
lblMaxNumFeatures->setVisible( false );
178-
mGroupBox->layout()->removeWidget( lblMaxNumFeatures );
179-
txtMaxNumFeatures->setVisible( false );
180-
mGroupBox->layout()->removeWidget( txtMaxNumFeatures );
181+
mTestConnectionButton->hide();
182+
mGroupBox->layout()->removeWidget( mTestConnectionButton );
181183
}
182184

183185
// Adjust height
184186
int w = width();
185187
adjustSize();
186188
resize( w, height() );
187189

188-
on_txtName_textChanged( connectionName );
190+
connect( txtName, &QLineEdit::textChanged, this, &QgsNewHttpConnection::nameChanged );
191+
connect( txtUrl, &QLineEdit::textChanged, this, &QgsNewHttpConnection::urlChanged );
192+
193+
nameChanged( connectionName );
189194
}
190195

191-
void QgsNewHttpConnection::on_txtName_textChanged( const QString &text )
196+
void QgsNewHttpConnection::nameChanged( const QString &text )
192197
{
193198
Q_UNUSED( text );
194199
buttonBox->button( QDialogButtonBox::Ok )->setDisabled( txtName->text().isEmpty() || txtUrl->text().isEmpty() );
195200
}
196201

197-
void QgsNewHttpConnection::on_txtUrl_textChanged( const QString &text )
202+
void QgsNewHttpConnection::urlChanged( const QString &text )
198203
{
199204
Q_UNUSED( text );
200205
buttonBox->button( QDialogButtonBox::Ok )->setDisabled( txtName->text().isEmpty() || txtUrl->text().isEmpty() );
@@ -258,12 +263,22 @@ void QgsNewHttpConnection::accept()
258263

259264
settings.setValue( key + "/url", url.toString() );
260265

261-
if ( mBaseKey == QLatin1String( "qgis/connections-wms/" ) ||
262-
mBaseKey == QLatin1String( "qgis/connections-wcs/" ) ||
263-
mBaseKey == QLatin1String( "qgis/connections-wfs/" ) )
266+
if ( mTypes & ConnectionWfs && mTypes & ConnectionWms )
267+
{
268+
settings.setValue( key + "/wfs/ignoreAxisOrientation", cbxWfsIgnoreAxisOrientation->isChecked() );
269+
settings.setValue( key + "/wms/ignoreAxisOrientation", cbxWmsIgnoreAxisOrientation->isChecked() );
270+
settings.setValue( key + "/wfs/invertAxisOrientation", cbxWfsInvertAxisOrientation->isChecked() );
271+
settings.setValue( key + "/wms/invertAxisOrientation", cbxWmsInvertAxisOrientation->isChecked() );
272+
}
273+
else if ( mTypes & ConnectionWfs )
274+
{
275+
settings.setValue( key + "/ignoreAxisOrientation", cbxWfsIgnoreAxisOrientation->isChecked() );
276+
settings.setValue( key + "/invertAxisOrientation", cbxWfsInvertAxisOrientation->isChecked() );
277+
}
278+
else
264279
{
265-
settings.setValue( key + "/ignoreAxisOrientation", cbxIgnoreAxisOrientation->isChecked() );
266-
settings.setValue( key + "/invertAxisOrientation", cbxInvertAxisOrientation->isChecked() );
280+
settings.setValue( key + "/ignoreAxisOrientation", cbxWmsIgnoreAxisOrientation->isChecked() );
281+
settings.setValue( key + "/invertAxisOrientation", cbxWmsInvertAxisOrientation->isChecked() );
267282
}
268283

269284
if ( mBaseKey == QLatin1String( "qgis/connections-wms/" ) || mBaseKey == QLatin1String( "qgis/connections-wcs/" ) )

‎src/gui/qgsnewhttpconnection.h‎

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,24 +48,40 @@ class GUI_EXPORT QgsNewHttpConnection : public QDialog, private Ui::QgsNewHttpCo
4848
};
4949
Q_DECLARE_FLAGS( ConnectionTypes, ConnectionType )
5050

51+
/**
52+
* Flags controlling dialog behavior.
53+
* \since QGIS 3.0
54+
*/
55+
enum Flag
56+
{
57+
FlagShowTestConnection = 1 << 1, //!< Display the 'test connection' button
58+
};
59+
Q_DECLARE_FLAGS( Flags, Flag )
60+
5161
/**
5262
* Constructor for QgsNewHttpConnection.
5363
*
5464
* The \a types argument dictates which connection type settings should be
5565
* shown in the dialog.
5666
*
67+
* The \a flags argument allows specifying flags which control the dialog behavior
68+
* and appearance.
5769
*/
5870
QgsNewHttpConnection( QWidget *parent SIP_TRANSFERTHIS = nullptr,
5971
QgsNewHttpConnection::ConnectionTypes types = ConnectionWms,
6072
const QString &baseKey = "qgis/connections-wms/",
6173
const QString &connectionName = QString(),
74+
QgsNewHttpConnection::Flags flags = 0,
6275
Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags );
6376

6477
public slots:
65-
// Saves the connection to ~/.qt/qgisrc
78+
6679
void accept() override;
67-
void on_txtName_textChanged( const QString & );
68-
void on_txtUrl_textChanged( const QString & );
80+
81+
private slots:
82+
83+
void nameChanged( const QString & );
84+
void urlChanged( const QString & );
6985

7086
private:
7187

@@ -80,5 +96,6 @@ class GUI_EXPORT QgsNewHttpConnection : public QDialog, private Ui::QgsNewHttpCo
8096
};
8197

8298
Q_DECLARE_OPERATORS_FOR_FLAGS( QgsNewHttpConnection::ConnectionTypes )
99+
Q_DECLARE_OPERATORS_FOR_FLAGS( QgsNewHttpConnection::Flags )
83100

84101
#endif // QGSNEWHTTPCONNECTION_H

‎src/ui/qgsnewhttpconnectionbase.ui‎

Lines changed: 206 additions & 174 deletions
Original file line numberDiff line numberDiff line change
@@ -6,34 +6,85 @@
66
<rect>
77
<x>0</x>
88
<y>0</y>
9-
<width>526</width>
10-
<height>721</height>
9+
<width>448</width>
10+
<height>828</height>
1111
</rect>
1212
</property>
1313
<property name="windowTitle">
14-
<string>Create a New WMS Connection</string>
14+
<string>Create a new connection</string>
1515
</property>
1616
<property name="sizeGripEnabled">
1717
<bool>true</bool>
1818
</property>
1919
<property name="modal">
2020
<bool>true</bool>
2121
</property>
22-
<layout class="QGridLayout" name="gridLayout">
23-
<item row="2" column="0">
24-
<widget class="QDialogButtonBox" name="buttonBox">
25-
<property name="standardButtons">
26-
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Help|QDialogButtonBox::Ok</set>
27-
</property>
28-
</widget>
29-
</item>
30-
<item row="1" column="0">
22+
<layout class="QGridLayout" name="gridLayout_4">
23+
<item row="0" column="0">
3124
<widget class="QGroupBox" name="mGroupBox">
3225
<property name="title">
3326
<string>Connection details</string>
3427
</property>
3528
<layout class="QGridLayout">
36-
<item row="4" column="0" colspan="3">
29+
<item row="8" column="0" colspan="2">
30+
<widget class="QGroupBox" name="mWfsOptionsGroupBox">
31+
<property name="title">
32+
<string>WFS Options</string>
33+
</property>
34+
<layout class="QGridLayout" name="gridLayout1">
35+
<item row="2" column="0" colspan="2">
36+
<widget class="QCheckBox" name="cbxWfsIgnoreAxisOrientation">
37+
<property name="text">
38+
<string>Ignore axis orientation (WFS 1.1/WFS 2.0)</string>
39+
</property>
40+
</widget>
41+
</item>
42+
<item row="3" column="0" colspan="2">
43+
<widget class="QCheckBox" name="cbxWfsInvertAxisOrientation">
44+
<property name="text">
45+
<string>Invert axis orientation</string>
46+
</property>
47+
</widget>
48+
</item>
49+
<item row="1" column="0">
50+
<widget class="QLabel" name="lblMaxNumFeatures">
51+
<property name="text">
52+
<string>Max. number of features</string>
53+
</property>
54+
</widget>
55+
</item>
56+
<item row="0" column="0">
57+
<widget class="QLabel" name="lblVersion">
58+
<property name="text">
59+
<string>Version</string>
60+
</property>
61+
</widget>
62+
</item>
63+
<item row="0" column="1">
64+
<widget class="QComboBox" name="cmbVersion">
65+
<property name="toolTip">
66+
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Select protocol version&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
67+
</property>
68+
</widget>
69+
</item>
70+
<item row="1" column="1">
71+
<widget class="QLineEdit" name="txtMaxNumFeatures">
72+
<property name="toolTip">
73+
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Enter a number to limit the maximum number of features retrieved in a single GetFeature request. If let to empty, server default will apply.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
74+
</property>
75+
</widget>
76+
</item>
77+
</layout>
78+
</widget>
79+
</item>
80+
<item row="18" column="0" colspan="2">
81+
<widget class="QPushButton" name="mTestConnectionButton">
82+
<property name="text">
83+
<string>&amp;Test Connection</string>
84+
</property>
85+
</widget>
86+
</item>
87+
<item row="7" column="0" colspan="2">
3788
<widget class="QTabWidget" name="tabAuth">
3889
<property name="sizePolicy">
3990
<sizepolicy hsizetype="Expanding" vsizetype="MinimumExpanding">
@@ -49,19 +100,6 @@
49100
<string>Authentication</string>
50101
</attribute>
51102
<layout class="QGridLayout" name="gridLayout_3">
52-
<item row="1" column="0">
53-
<widget class="QLabel" name="label_2">
54-
<property name="text">
55-
<string>&amp;User name</string>
56-
</property>
57-
<property name="buddy">
58-
<cstring>txtUserName</cstring>
59-
</property>
60-
</widget>
61-
</item>
62-
<item row="1" column="1">
63-
<widget class="QLineEdit" name="txtUserName"/>
64-
</item>
65103
<item row="0" column="0" colspan="2">
66104
<widget class="QLabel" name="label">
67105
<property name="sizePolicy">
@@ -81,6 +119,19 @@
81119
</property>
82120
</widget>
83121
</item>
122+
<item row="1" column="0">
123+
<widget class="QLabel" name="label_2">
124+
<property name="text">
125+
<string>&amp;User name</string>
126+
</property>
127+
<property name="buddy">
128+
<cstring>txtUserName</cstring>
129+
</property>
130+
</widget>
131+
</item>
132+
<item row="1" column="1">
133+
<widget class="QLineEdit" name="txtUserName"/>
134+
</item>
84135
<item row="2" column="0">
85136
<widget class="QLabel" name="label_3">
86137
<property name="text">
@@ -115,150 +166,142 @@
115166
</widget>
116167
</widget>
117168
</item>
118-
<item row="0" column="2">
119-
<widget class="QLineEdit" name="txtName">
120-
<property name="minimumSize">
121-
<size>
122-
<width>0</width>
123-
<height>0</height>
124-
</size>
125-
</property>
126-
<property name="toolTip">
127-
<string>Name of the new connection</string>
128-
</property>
129-
<property name="frame">
130-
<bool>true</bool>
131-
</property>
132-
</widget>
133-
</item>
134-
<item row="7" column="0">
135-
<widget class="QLabel" name="lblDpiMode">
136-
<property name="text">
137-
<string>DPI-Mode</string>
138-
</property>
139-
<property name="buddy">
140-
<cstring>cmbDpiMode</cstring>
141-
</property>
142-
</widget>
143-
</item>
144-
<item row="1" column="0">
145-
<widget class="QLabel" name="TextLabel1">
146-
<property name="text">
147-
<string>URL</string>
148-
</property>
149-
<property name="margin">
150-
<number>5</number>
151-
</property>
152-
<property name="buddy">
153-
<cstring>txtUrl</cstring>
154-
</property>
155-
</widget>
156-
</item>
157-
<item row="0" column="0">
158-
<widget class="QLabel" name="TextLabel1_2">
159-
<property name="text">
160-
<string>Name</string>
161-
</property>
162-
<property name="wordWrap">
163-
<bool>true</bool>
164-
</property>
165-
<property name="margin">
166-
<number>5</number>
167-
</property>
168-
<property name="buddy">
169-
<cstring>txtName</cstring>
170-
</property>
171-
</widget>
172-
</item>
173-
<item row="1" column="2">
174-
<widget class="QLineEdit" name="txtUrl">
175-
<property name="toolTip">
176-
<string>HTTP address of the Web Map Server</string>
177-
</property>
178-
</widget>
179-
</item>
180-
<item row="7" column="2">
181-
<widget class="QComboBox" name="cmbDpiMode"/>
182-
</item>
183-
<item row="6" column="0">
184-
<widget class="QLabel" name="lblReferer">
185-
<property name="text">
186-
<string>Referer</string>
187-
</property>
188-
<property name="buddy">
189-
<cstring>txtReferer</cstring>
190-
</property>
191-
</widget>
192-
</item>
193-
<item row="6" column="2">
194-
<widget class="QLineEdit" name="txtReferer"/>
195-
</item>
196-
<item row="16" column="0" colspan="3">
197-
<widget class="QCheckBox" name="cbxSmoothPixmapTransform">
198-
<property name="text">
199-
<string>Smooth pixmap transform</string>
200-
</property>
201-
</widget>
202-
</item>
203-
<item row="15" column="0" colspan="3">
204-
<widget class="QCheckBox" name="cbxInvertAxisOrientation">
205-
<property name="text">
206-
<string>Invert axis orientation</string>
169+
<item row="12" column="0" colspan="2">
170+
<widget class="QGroupBox" name="mWmsOptionsGroupBox">
171+
<property name="title">
172+
<string>WMS Options</string>
207173
</property>
174+
<layout class="QGridLayout" name="gridLayout_2">
175+
<item row="5" column="0" colspan="2">
176+
<widget class="QCheckBox" name="cbxWmsInvertAxisOrientation">
177+
<property name="text">
178+
<string>Invert axis orientation</string>
179+
</property>
180+
</widget>
181+
</item>
182+
<item row="3" column="0" colspan="2">
183+
<widget class="QCheckBox" name="cbxIgnoreGetFeatureInfoURI">
184+
<property name="text">
185+
<string>Ignore GetFeatureInfo URI reported in capabilities</string>
186+
</property>
187+
</widget>
188+
</item>
189+
<item row="2" column="0" colspan="2">
190+
<widget class="QCheckBox" name="cbxIgnoreGetMapURI">
191+
<property name="text">
192+
<string>Ignore GetMap/GetTile URI reported in capabilities</string>
193+
</property>
194+
</widget>
195+
</item>
196+
<item row="9" column="0" colspan="2">
197+
<widget class="QCheckBox" name="cbxSmoothPixmapTransform">
198+
<property name="text">
199+
<string>Smooth pixmap transform</string>
200+
</property>
201+
</widget>
202+
</item>
203+
<item row="0" column="1">
204+
<widget class="QLineEdit" name="txtReferer"/>
205+
</item>
206+
<item row="1" column="1">
207+
<widget class="QComboBox" name="cmbDpiMode"/>
208+
</item>
209+
<item row="1" column="0">
210+
<widget class="QLabel" name="lblDpiMode">
211+
<property name="text">
212+
<string>DPI-Mode</string>
213+
</property>
214+
<property name="buddy">
215+
<cstring>cmbDpiMode</cstring>
216+
</property>
217+
</widget>
218+
</item>
219+
<item row="0" column="0">
220+
<widget class="QLabel" name="lblReferer">
221+
<property name="text">
222+
<string>Referer</string>
223+
</property>
224+
<property name="buddy">
225+
<cstring>txtReferer</cstring>
226+
</property>
227+
</widget>
228+
</item>
229+
<item row="4" column="0" colspan="2">
230+
<widget class="QCheckBox" name="cbxWmsIgnoreAxisOrientation">
231+
<property name="text">
232+
<string>Ignore axis orientation (WMS 1.3/WMTS)</string>
233+
</property>
234+
</widget>
235+
</item>
236+
</layout>
208237
</widget>
209238
</item>
210-
<item row="14" column="0" colspan="3">
211-
<widget class="QCheckBox" name="cbxIgnoreAxisOrientation">
212-
<property name="text">
213-
<string>Ignore axis orientation (WMS 1.3/WMTS)</string>
214-
</property>
215-
</widget>
216-
</item>
217-
<item row="12" column="0" colspan="3">
218-
<widget class="QCheckBox" name="cbxIgnoreGetMapURI">
219-
<property name="text">
220-
<string>Ignore GetMap/GetTile URI reported in capabilities</string>
221-
</property>
222-
</widget>
223-
</item>
224-
<item row="13" column="0" colspan="3">
225-
<widget class="QCheckBox" name="cbxIgnoreGetFeatureInfoURI">
226-
<property name="text">
227-
<string>Ignore GetFeatureInfo URI reported in capabilities</string>
228-
</property>
229-
</widget>
230-
</item>
231-
<item row="8" column="0">
232-
<widget class="QLabel" name="lblVersion">
233-
<property name="text">
234-
<string>Version</string>
235-
</property>
236-
</widget>
237-
</item>
238-
<item row="8" column="2">
239-
<widget class="QComboBox" name="cmbVersion">
240-
<property name="toolTip">
241-
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Select protocol version&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
242-
</property>
243-
</widget>
244-
</item>
245-
<item row="9" column="0">
246-
<widget class="QLabel" name="lblMaxNumFeatures">
247-
<property name="text">
248-
<string>Max. number of features</string>
249-
</property>
250-
</widget>
251-
</item>
252-
<item row="9" column="2">
253-
<widget class="QLineEdit" name="txtMaxNumFeatures">
254-
<property name="toolTip">
255-
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Enter a number to limit the maximum number of features retrieved in a single GetFeature request. If let to empty, server default will apply.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
256-
</property>
257-
</widget>
239+
<item row="2" column="0">
240+
<layout class="QFormLayout" name="formLayout">
241+
<item row="0" column="0">
242+
<widget class="QLabel" name="TextLabel1_2">
243+
<property name="text">
244+
<string>Name</string>
245+
</property>
246+
<property name="wordWrap">
247+
<bool>true</bool>
248+
</property>
249+
<property name="margin">
250+
<number>5</number>
251+
</property>
252+
<property name="buddy">
253+
<cstring>txtName</cstring>
254+
</property>
255+
</widget>
256+
</item>
257+
<item row="0" column="1">
258+
<widget class="QLineEdit" name="txtName">
259+
<property name="minimumSize">
260+
<size>
261+
<width>0</width>
262+
<height>0</height>
263+
</size>
264+
</property>
265+
<property name="toolTip">
266+
<string>Name of the new connection</string>
267+
</property>
268+
<property name="frame">
269+
<bool>true</bool>
270+
</property>
271+
</widget>
272+
</item>
273+
<item row="1" column="0">
274+
<widget class="QLabel" name="TextLabel1">
275+
<property name="text">
276+
<string>URL</string>
277+
</property>
278+
<property name="margin">
279+
<number>5</number>
280+
</property>
281+
<property name="buddy">
282+
<cstring>txtUrl</cstring>
283+
</property>
284+
</widget>
285+
</item>
286+
<item row="1" column="1">
287+
<widget class="QLineEdit" name="txtUrl">
288+
<property name="toolTip">
289+
<string>HTTP address of the Web Map Server</string>
290+
</property>
291+
</widget>
292+
</item>
293+
</layout>
258294
</item>
259295
</layout>
260296
</widget>
261297
</item>
298+
<item row="1" column="0">
299+
<widget class="QDialogButtonBox" name="buttonBox">
300+
<property name="standardButtons">
301+
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Help|QDialogButtonBox::Ok</set>
302+
</property>
303+
</widget>
304+
</item>
262305
</layout>
263306
</widget>
264307
<layoutdefault spacing="6" margin="11"/>
@@ -270,20 +313,9 @@
270313
</customwidget>
271314
</customwidgets>
272315
<tabstops>
273-
<tabstop>txtName</tabstop>
274-
<tabstop>txtUrl</tabstop>
275316
<tabstop>tabAuth</tabstop>
276317
<tabstop>txtUserName</tabstop>
277318
<tabstop>txtPassword</tabstop>
278-
<tabstop>txtReferer</tabstop>
279-
<tabstop>cmbDpiMode</tabstop>
280-
<tabstop>cmbVersion</tabstop>
281-
<tabstop>txtMaxNumFeatures</tabstop>
282-
<tabstop>cbxIgnoreGetMapURI</tabstop>
283-
<tabstop>cbxIgnoreGetFeatureInfoURI</tabstop>
284-
<tabstop>cbxIgnoreAxisOrientation</tabstop>
285-
<tabstop>cbxInvertAxisOrientation</tabstop>
286-
<tabstop>cbxSmoothPixmapTransform</tabstop>
287319
</tabstops>
288320
<resources/>
289321
<connections>

0 commit comments

Comments
 (0)
Please sign in to comment.