Skip to content

Commit 9ae3ae2

Browse files
author
wonder
committedJul 14, 2009
Changed line width to be double, fixed width retrieval from symbol, proportional scaling of symbol layers when settings size/width.
git-svn-id: http://svn.osgeo.org/qgis/branches/symbology-ng-branch@11064 c8812cc2-4d05-0410-92ff-de0c093fc19c

17 files changed

+213
-160
lines changed
 

‎python/core/symbology-ng-core.sip

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -315,8 +315,8 @@ class QgsLineSymbolLayerV2 : QgsSymbolLayerV2
315315
public:
316316
virtual void renderPolyline(const QPolygonF& points, QgsRenderContext& context) = 0;
317317

318-
void setWidth(int width);
319-
int width() const;
318+
void setWidth(double width);
319+
double width() const;
320320

321321
void drawPreviewIcon(QPainter* painter, QSize size);
322322

@@ -450,8 +450,8 @@ class QgsLineSymbolV2 : QgsSymbolV2
450450
public:
451451
QgsLineSymbolV2(QgsSymbolLayerV2List layers /Transfer/ = QgsSymbolLayerV2List());
452452

453-
void setWidth(int width);
454-
int width();
453+
void setWidth(double width);
454+
double width();
455455

456456
void renderPolyline(const QPolygonF& points, QgsRenderContext& context, int layer = -1);
457457

‎python/gui/symbology-ng-gui.sip

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ public slots:
8686
void setSymbolFromStyle(const QModelIndex & index);
8787
void setSymbolColor();
8888
void setMarkerAngle(double angle);
89-
void setMarkerSize(int size);
90-
void setLineWidth(int width);
89+
void setMarkerSize(double size);
90+
void setLineWidth(double width);
9191

9292
};

‎src/core/symbology-ng/qgslinesymbollayerv2.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
#include <cmath>
1010

11-
QgsSimpleLineSymbolLayerV2::QgsSimpleLineSymbolLayerV2(QColor color, int width, Qt::PenStyle penStyle)
11+
QgsSimpleLineSymbolLayerV2::QgsSimpleLineSymbolLayerV2(QColor color, double width, Qt::PenStyle penStyle)
1212
: mPenStyle(penStyle), mOffset(0)
1313
{
1414
mColor = color;
@@ -19,13 +19,13 @@ QgsSimpleLineSymbolLayerV2::QgsSimpleLineSymbolLayerV2(QColor color, int width,
1919
QgsSymbolLayerV2* QgsSimpleLineSymbolLayerV2::create(const QgsStringMap& props)
2020
{
2121
QColor color = DEFAULT_SIMPLELINE_COLOR;
22-
int width = DEFAULT_SIMPLELINE_WIDTH;
22+
double width = DEFAULT_SIMPLELINE_WIDTH;
2323
Qt::PenStyle penStyle = DEFAULT_SIMPLELINE_PENSTYLE;
2424

2525
if (props.contains("color"))
2626
color = QgsSymbolLayerV2Utils::decodeColor(props["color"]);
2727
if (props.contains("width"))
28-
width = props["width"].toInt();
28+
width = props["width"].toDouble();
2929
if (props.contains("penstyle"))
3030
penStyle = QgsSymbolLayerV2Utils::decodePenStyle(props["penstyle"]);
3131

‎src/core/symbology-ng/qgslinesymbollayerv2.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ class QgsSimpleLineSymbolLayerV2 : public QgsLineSymbolLayerV2
1515
{
1616
public:
1717
QgsSimpleLineSymbolLayerV2(QColor color = DEFAULT_SIMPLELINE_COLOR,
18-
int width = DEFAULT_SIMPLELINE_WIDTH,
18+
double width = DEFAULT_SIMPLELINE_WIDTH,
1919
Qt::PenStyle penStyle = DEFAULT_SIMPLELINE_PENSTYLE);
2020

2121
// static stuff

‎src/core/symbology-ng/qgssymbollayerv2.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -89,15 +89,15 @@ class QgsLineSymbolLayerV2 : public QgsSymbolLayerV2
8989
public:
9090
virtual void renderPolyline(const QPolygonF& points, QgsRenderContext& context) = 0;
9191

92-
void setWidth(int width) { mWidth = width; }
93-
int width() const { return mWidth; }
92+
void setWidth(double width) { mWidth = width; }
93+
double width() const { return mWidth; }
9494

9595
void drawPreviewIcon(QPainter* painter, QSize size);
9696

9797
protected:
9898
QgsLineSymbolLayerV2(bool locked = false);
9999

100-
int mWidth;
100+
double mWidth;
101101
};
102102

103103
class QgsFillSymbolLayerV2 : public QgsSymbolLayerV2

‎src/core/symbology-ng/qgssymbolv2.cpp

Lines changed: 28 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -252,13 +252,21 @@ double QgsMarkerSymbolV2::angle()
252252
return 0;
253253
}
254254

255-
void QgsMarkerSymbolV2::setSize(double size)
255+
void QgsMarkerSymbolV2::setSize(double s)
256256
{
257-
// TODO: proportionally set size of layers
257+
double origSize = size();
258+
258259
for (QgsSymbolLayerV2List::iterator it = mLayers.begin(); it != mLayers.end(); ++it)
259260
{
260261
QgsMarkerSymbolLayerV2* layer = (QgsMarkerSymbolLayerV2*) *it;
261-
layer->setSize(size);
262+
if (layer->size() == origSize)
263+
layer->setSize(s);
264+
else
265+
{
266+
// proportionally scale size
267+
if (origSize != 0)
268+
layer->setSize(layer->size() * s / origSize);
269+
}
262270
}
263271
}
264272

@@ -308,24 +316,34 @@ QgsLineSymbolV2::QgsLineSymbolV2(QgsSymbolLayerV2List layers)
308316
mLayers.append(new QgsSimpleLineSymbolLayerV2());
309317
}
310318

311-
void QgsLineSymbolV2::setWidth(int width)
319+
void QgsLineSymbolV2::setWidth(double w)
312320
{
313-
// TODO: proportionally set width of layers
321+
double origWidth = width();
322+
314323
for (QgsSymbolLayerV2List::iterator it = mLayers.begin(); it != mLayers.end(); ++it)
315324
{
316325
QgsLineSymbolLayerV2* layer = (QgsLineSymbolLayerV2*) *it;
317-
layer->setWidth(width);
326+
if (layer->width() == origWidth)
327+
{
328+
layer->setWidth(w);
329+
}
330+
else
331+
{
332+
// proportionally scale the width
333+
if (origWidth != 0)
334+
layer->setWidth( layer->width() * w / origWidth );
335+
}
318336
}
319337
}
320338

321-
int QgsLineSymbolV2::width()
339+
double QgsLineSymbolV2::width()
322340
{
323-
int maxWidth = 0;
341+
double maxWidth = 0;
324342
for (QgsSymbolLayerV2List::const_iterator it = mLayers.begin(); it != mLayers.end(); ++it)
325343
{
326344
const QgsLineSymbolLayerV2* layer = (const QgsLineSymbolLayerV2*) *it;
327-
int width = layer->width();
328-
if (maxWidth > width)
345+
double width = layer->width();
346+
if (width > maxWidth)
329347
maxWidth = width;
330348
}
331349
return maxWidth;

‎src/core/symbology-ng/qgssymbolv2.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,8 +106,8 @@ class QgsLineSymbolV2 : public QgsSymbolV2
106106
public:
107107
QgsLineSymbolV2(QgsSymbolLayerV2List layers = QgsSymbolLayerV2List());
108108

109-
void setWidth(int width);
110-
int width();
109+
void setWidth(double width);
110+
double width();
111111

112112
void renderPolyline(const QPolygonF& points, QgsRenderContext& context, int layer = -1);
113113

‎src/gui/symbology-ng/qgssymbollayerv2widget.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ QgsSimpleLineSymbolLayerV2Widget::QgsSimpleLineSymbolLayerV2Widget(QWidget* pare
3232

3333
setupUi(this);
3434

35-
connect(spinWidth, SIGNAL(valueChanged(int)), this, SLOT(penWidthChanged()));
35+
connect(spinWidth, SIGNAL(valueChanged(double)), this, SLOT(penWidthChanged()));
3636
connect(btnChangeColor, SIGNAL(clicked()), this, SLOT(colorChanged()));
3737
connect(cboPenStyle, SIGNAL(currentIndexChanged(int)), this, SLOT(penStyleChanged()));
3838
connect(spinOffset, SIGNAL(valueChanged(double)), this, SLOT(offsetChanged()));
@@ -114,7 +114,7 @@ QgsSimpleMarkerSymbolLayerV2Widget::QgsSimpleMarkerSymbolLayerV2Widget(QWidget*
114114
connect(lstNames, SIGNAL(currentRowChanged(int)), this, SLOT(setName()));
115115
connect(btnChangeColorBorder, SIGNAL(clicked()), this, SLOT(setColorBorder()));
116116
connect(btnChangeColorFill, SIGNAL(clicked()), this, SLOT(setColorFill()));
117-
connect(spinSize, SIGNAL(valueChanged(int)), this, SLOT(setSize()));
117+
connect(spinSize, SIGNAL(valueChanged(double)), this, SLOT(setSize()));
118118
connect(spinAngle, SIGNAL(valueChanged(double)), this, SLOT(setAngle()));
119119
connect(spinOffsetX, SIGNAL(valueChanged(double)), this, SLOT(setOffset()));
120120
connect(spinOffsetY, SIGNAL(valueChanged(double)), this, SLOT(setOffset()));
@@ -270,7 +270,7 @@ QgsMarkerLineSymbolLayerV2Widget::QgsMarkerLineSymbolLayerV2Widget(QWidget* pare
270270

271271
setupUi(this);
272272

273-
connect(spinInterval, SIGNAL(valueChanged(int)), this, SLOT(setInterval(int)));
273+
connect(spinInterval, SIGNAL(valueChanged(double)), this, SLOT(setInterval(double)));
274274
connect(btnChangeMarker, SIGNAL(clicked()), this, SLOT(setMarker()));
275275
connect(chkRotateMarker, SIGNAL(clicked()), this, SLOT(setRotate()));
276276
connect(spinOffset, SIGNAL(valueChanged(double)), this, SLOT(setOffset()));
@@ -296,7 +296,7 @@ QgsSymbolLayerV2* QgsMarkerLineSymbolLayerV2Widget::symbolLayer()
296296
return mLayer;
297297
}
298298

299-
void QgsMarkerLineSymbolLayerV2Widget::setInterval(int val)
299+
void QgsMarkerLineSymbolLayerV2Widget::setInterval(double val)
300300
{
301301
mLayer->setInterval(val);
302302
emit changed();
@@ -345,7 +345,7 @@ QgsSvgMarkerSymbolLayerV2Widget::QgsSvgMarkerSymbolLayerV2Widget(QWidget* parent
345345
populateList();
346346

347347
connect(viewImages->selectionModel(), SIGNAL(currentChanged(const QModelIndex&, const QModelIndex&)), this, SLOT(setName(const QModelIndex&)));
348-
connect(spinSize, SIGNAL(valueChanged(int)), this, SLOT(setSize()));
348+
connect(spinSize, SIGNAL(valueChanged(double)), this, SLOT(setSize()));
349349
connect(spinAngle, SIGNAL(valueChanged(double)), this, SLOT(setAngle()));
350350
connect(spinOffsetX, SIGNAL(valueChanged(double)), this, SLOT(setOffset()));
351351
connect(spinOffsetY, SIGNAL(valueChanged(double)), this, SLOT(setOffset()));

‎src/gui/symbology-ng/qgssymbollayerv2widget.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ class QgsMarkerLineSymbolLayerV2Widget : public QgsSymbolLayerV2Widget, private
131131

132132
public slots:
133133

134-
void setInterval(int val);
134+
void setInterval(double val);
135135
void setMarker();
136136
void setRotate();
137137
void setOffset();

‎src/gui/symbology-ng/qgssymbolv2selectordialog.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ QgsSymbolV2SelectorDialog::QgsSymbolV2SelectorDialog(QgsSymbolV2* symbol, QgsSty
3636

3737
connect(btnSetColor, SIGNAL(clicked()), this, SLOT(setSymbolColor()));
3838
connect(spinAngle, SIGNAL(valueChanged(double)), this, SLOT(setMarkerAngle(double)));
39-
connect(spinSize, SIGNAL(valueChanged(int)), this, SLOT(setMarkerSize(int)));
40-
connect(spinWidth, SIGNAL(valueChanged(int)), this, SLOT(setLineWidth(int)));
39+
connect(spinSize, SIGNAL(valueChanged(double)), this, SLOT(setMarkerSize(double)));
40+
connect(spinWidth, SIGNAL(valueChanged(double)), this, SLOT(setLineWidth(double)));
4141

4242
}
4343

@@ -154,7 +154,7 @@ void QgsSymbolV2SelectorDialog::setMarkerAngle(double angle)
154154
updateSymbolPreview();
155155
}
156156

157-
void QgsSymbolV2SelectorDialog::setMarkerSize(int size)
157+
void QgsSymbolV2SelectorDialog::setMarkerSize(double size)
158158
{
159159
QgsMarkerSymbolV2* markerSymbol = static_cast<QgsMarkerSymbolV2*>(mSymbol);
160160
if (markerSymbol->size() == size)
@@ -163,7 +163,7 @@ void QgsSymbolV2SelectorDialog::setMarkerSize(int size)
163163
updateSymbolPreview();
164164
}
165165

166-
void QgsSymbolV2SelectorDialog::setLineWidth(int width)
166+
void QgsSymbolV2SelectorDialog::setLineWidth(double width)
167167
{
168168
QgsLineSymbolV2* lineSymbol = static_cast<QgsLineSymbolV2*>(mSymbol);
169169
if (lineSymbol->width() == width)

‎src/gui/symbology-ng/qgssymbolv2selectordialog.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ public slots:
2828
void setSymbolFromStyle(const QModelIndex & index);
2929
void setSymbolColor();
3030
void setMarkerAngle(double angle);
31-
void setMarkerSize(int size);
32-
void setLineWidth(int width);
31+
void setMarkerSize(double size);
32+
void setLineWidth(double width);
3333

3434
protected:
3535
QgsStyleV2* mStyle;

‎src/ui/qgsrendererv2propsdialogbase.ui

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@
9595
<item row="0" column="2">
9696
<widget class="QStackedWidget" name="stackedWidget">
9797
<property name="currentIndex">
98-
<number>1</number>
98+
<number>0</number>
9999
</property>
100100
<widget class="QWidget" name="pageSingleSymbol">
101101
<layout class="QGridLayout">
@@ -394,7 +394,11 @@
394394
</layout>
395395
</item>
396396
<item>
397-
<widget class="QTreeView" name="viewGraduated"/>
397+
<widget class="QTreeView" name="viewGraduated">
398+
<property name="rootIsDecorated">
399+
<bool>false</bool>
400+
</property>
401+
</widget>
398402
</item>
399403
<item>
400404
<layout class="QHBoxLayout">

‎src/ui/qgssymbolv2selectordialogbase.ui

Lines changed: 79 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -1,174 +1,181 @@
1-
<ui version="4.0" >
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<ui version="4.0">
23
<class>QgsSymbolV2SelectorDialogBase</class>
3-
<widget class="QDialog" name="QgsSymbolV2SelectorDialogBase" >
4-
<property name="geometry" >
4+
<widget class="QDialog" name="QgsSymbolV2SelectorDialogBase">
5+
<property name="geometry">
56
<rect>
67
<x>0</x>
78
<y>0</y>
89
<width>477</width>
910
<height>397</height>
1011
</rect>
1112
</property>
12-
<property name="windowTitle" >
13+
<property name="windowTitle">
1314
<string>Symbol selector</string>
1415
</property>
15-
<layout class="QVBoxLayout" >
16+
<layout class="QVBoxLayout">
1617
<item>
17-
<layout class="QGridLayout" >
18-
<item rowspan="2" row="0" column="0" >
19-
<widget class="QLabel" name="lblPreview" >
20-
<property name="sizePolicy" >
21-
<sizepolicy vsizetype="MinimumExpanding" hsizetype="MinimumExpanding" >
18+
<layout class="QGridLayout">
19+
<item row="0" column="0" rowspan="2">
20+
<widget class="QLabel" name="lblPreview">
21+
<property name="sizePolicy">
22+
<sizepolicy hsizetype="MinimumExpanding" vsizetype="MinimumExpanding">
2223
<horstretch>0</horstretch>
2324
<verstretch>0</verstretch>
2425
</sizepolicy>
2526
</property>
26-
<property name="frameShape" >
27+
<property name="frameShape">
2728
<enum>QFrame::Box</enum>
2829
</property>
29-
<property name="frameShadow" >
30+
<property name="frameShadow">
3031
<enum>QFrame::Sunken</enum>
3132
</property>
32-
<property name="text" >
33+
<property name="text">
3334
<string/>
3435
</property>
35-
<property name="alignment" >
36+
<property name="alignment">
3637
<set>Qt::AlignCenter</set>
3738
</property>
3839
</widget>
3940
</item>
40-
<item row="0" column="1" >
41-
<widget class="QPushButton" name="btnSymbolProperties" >
42-
<property name="text" >
41+
<item row="0" column="1">
42+
<widget class="QPushButton" name="btnSymbolProperties">
43+
<property name="text">
4344
<string>Properties</string>
4445
</property>
4546
</widget>
4647
</item>
47-
<item rowspan="2" row="0" column="2" >
48-
<widget class="QStackedWidget" name="stackedWidget" >
49-
<property name="currentIndex" >
50-
<number>0</number>
48+
<item row="0" column="2" rowspan="2">
49+
<widget class="QStackedWidget" name="stackedWidget">
50+
<property name="currentIndex">
51+
<number>1</number>
5152
</property>
52-
<widget class="QWidget" name="pageMarker" >
53-
<layout class="QGridLayout" >
54-
<item row="0" column="0" >
55-
<widget class="QLabel" name="label_2" >
56-
<property name="text" >
53+
<widget class="QWidget" name="pageMarker">
54+
<layout class="QGridLayout">
55+
<item row="0" column="0">
56+
<widget class="QLabel" name="label_2">
57+
<property name="text">
5758
<string>Size:</string>
5859
</property>
5960
</widget>
6061
</item>
61-
<item row="0" column="1" >
62-
<widget class="QSpinBox" name="spinSize" >
63-
<property name="minimum" >
64-
<number>1</number>
65-
</property>
66-
<property name="maximum" >
67-
<number>1000</number>
62+
<item row="1" column="0">
63+
<widget class="QLabel" name="label_3">
64+
<property name="text">
65+
<string>Angle:</string>
6866
</property>
6967
</widget>
7068
</item>
71-
<item row="1" column="0" >
72-
<widget class="QLabel" name="label_3" >
73-
<property name="text" >
74-
<string>Angle:</string>
69+
<item row="1" column="1">
70+
<widget class="QDoubleSpinBox" name="spinAngle">
71+
<property name="decimals">
72+
<number>1</number>
73+
</property>
74+
<property name="maximum">
75+
<double>360.000000000000000</double>
76+
</property>
77+
<property name="singleStep">
78+
<double>5.000000000000000</double>
7579
</property>
7680
</widget>
7781
</item>
78-
<item row="1" column="1" >
79-
<widget class="QDoubleSpinBox" name="spinAngle" >
80-
<property name="decimals" >
82+
<item row="0" column="1">
83+
<widget class="QDoubleSpinBox" name="spinSize">
84+
<property name="decimals">
8185
<number>1</number>
8286
</property>
83-
<property name="maximum" >
84-
<double>360.000000000000000</double>
87+
<property name="value">
88+
<double>1.000000000000000</double>
8589
</property>
8690
</widget>
8791
</item>
8892
</layout>
8993
</widget>
90-
<widget class="QWidget" name="pageLine" >
91-
<layout class="QHBoxLayout" >
94+
<widget class="QWidget" name="pageLine">
95+
<layout class="QHBoxLayout">
9296
<item>
93-
<widget class="QLabel" name="label_4" >
94-
<property name="text" >
97+
<widget class="QLabel" name="label_4">
98+
<property name="text">
9599
<string>Width:</string>
96100
</property>
97101
</widget>
98102
</item>
99103
<item>
100-
<widget class="QSpinBox" name="spinWidth" >
101-
<property name="minimum" >
104+
<widget class="QDoubleSpinBox" name="spinWidth">
105+
<property name="decimals">
102106
<number>1</number>
103107
</property>
108+
<property name="value">
109+
<double>1.000000000000000</double>
110+
</property>
104111
</widget>
105112
</item>
106113
</layout>
107114
</widget>
108-
<widget class="QWidget" name="pageFill" />
115+
<widget class="QWidget" name="pageFill"/>
109116
</widget>
110117
</item>
111-
<item rowspan="2" row="0" column="3" >
118+
<item row="0" column="3" rowspan="2">
112119
<spacer>
113-
<property name="orientation" >
120+
<property name="orientation">
114121
<enum>Qt::Horizontal</enum>
115122
</property>
116-
<property name="sizeType" >
123+
<property name="sizeType">
117124
<enum>QSizePolicy::Preferred</enum>
118125
</property>
119-
<property name="sizeHint" >
126+
<property name="sizeHint" stdset="0">
120127
<size>
121128
<width>50</width>
122129
<height>81</height>
123130
</size>
124131
</property>
125132
</spacer>
126133
</item>
127-
<item row="1" column="1" >
128-
<widget class="QPushButton" name="btnSetColor" >
129-
<property name="text" >
134+
<item row="1" column="1">
135+
<widget class="QPushButton" name="btnSetColor">
136+
<property name="text">
130137
<string>Set color</string>
131138
</property>
132139
</widget>
133140
</item>
134141
</layout>
135142
</item>
136143
<item>
137-
<widget class="QLabel" name="label" >
138-
<property name="text" >
144+
<widget class="QLabel" name="label">
145+
<property name="text">
139146
<string>Symbols from style:</string>
140147
</property>
141148
</widget>
142149
</item>
143150
<item>
144-
<widget class="QListView" name="viewSymbols" >
145-
<property name="iconSize" >
151+
<widget class="QListView" name="viewSymbols">
152+
<property name="iconSize">
146153
<size>
147154
<width>48</width>
148155
<height>48</height>
149156
</size>
150157
</property>
151-
<property name="flow" >
158+
<property name="flow">
152159
<enum>QListView::LeftToRight</enum>
153160
</property>
154-
<property name="resizeMode" >
161+
<property name="resizeMode">
155162
<enum>QListView::Adjust</enum>
156163
</property>
157-
<property name="spacing" >
164+
<property name="spacing">
158165
<number>5</number>
159166
</property>
160-
<property name="viewMode" >
167+
<property name="viewMode">
161168
<enum>QListView::IconMode</enum>
162169
</property>
163170
</widget>
164171
</item>
165172
<item>
166-
<widget class="QDialogButtonBox" name="buttonBox" >
167-
<property name="orientation" >
173+
<widget class="QDialogButtonBox" name="buttonBox">
174+
<property name="orientation">
168175
<enum>Qt::Horizontal</enum>
169176
</property>
170-
<property name="standardButtons" >
171-
<set>QDialogButtonBox::Cancel|QDialogButtonBox::NoButton|QDialogButtonBox::Ok</set>
177+
<property name="standardButtons">
178+
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
172179
</property>
173180
</widget>
174181
</item>
@@ -182,11 +189,11 @@
182189
<receiver>QgsSymbolV2SelectorDialogBase</receiver>
183190
<slot>accept()</slot>
184191
<hints>
185-
<hint type="sourcelabel" >
192+
<hint type="sourcelabel">
186193
<x>248</x>
187194
<y>254</y>
188195
</hint>
189-
<hint type="destinationlabel" >
196+
<hint type="destinationlabel">
190197
<x>157</x>
191198
<y>274</y>
192199
</hint>
@@ -198,11 +205,11 @@
198205
<receiver>QgsSymbolV2SelectorDialogBase</receiver>
199206
<slot>reject()</slot>
200207
<hints>
201-
<hint type="sourcelabel" >
208+
<hint type="sourcelabel">
202209
<x>316</x>
203210
<y>260</y>
204211
</hint>
205-
<hint type="destinationlabel" >
212+
<hint type="destinationlabel">
206213
<x>286</x>
207214
<y>274</y>
208215
</hint>

‎src/ui/symbollayer/widget_markerline.ui

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -53,13 +53,6 @@
5353
</property>
5454
</widget>
5555
</item>
56-
<item row="1" column="1">
57-
<widget class="QSpinBox" name="spinInterval">
58-
<property name="minimum">
59-
<number>1</number>
60-
</property>
61-
</widget>
62-
</item>
6356
<item row="2" column="0" colspan="2">
6457
<widget class="QCheckBox" name="chkRotateMarker">
6558
<property name="text">
@@ -76,8 +69,21 @@
7669
</item>
7770
<item row="3" column="1">
7871
<widget class="QDoubleSpinBox" name="spinOffset">
72+
<property name="decimals">
73+
<number>1</number>
74+
</property>
7975
<property name="minimum">
80-
<double>-99.989999999999995</double>
76+
<double>-100.000000000000000</double>
77+
</property>
78+
</widget>
79+
</item>
80+
<item row="1" column="1">
81+
<widget class="QDoubleSpinBox" name="spinInterval">
82+
<property name="decimals">
83+
<number>1</number>
84+
</property>
85+
<property name="value">
86+
<double>1.000000000000000</double>
8187
</property>
8288
</widget>
8389
</item>

‎src/ui/symbollayer/widget_simpleline.ui

Lines changed: 26 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -59,22 +59,6 @@
5959
</property>
6060
</widget>
6161
</item>
62-
<item row="1" column="1">
63-
<widget class="QSpinBox" name="spinWidth">
64-
<property name="sizePolicy">
65-
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
66-
<horstretch>0</horstretch>
67-
<verstretch>0</verstretch>
68-
</sizepolicy>
69-
</property>
70-
<property name="alignment">
71-
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
72-
</property>
73-
<property name="minimum">
74-
<number>1</number>
75-
</property>
76-
</widget>
77-
</item>
7862
<item row="2" column="0">
7963
<widget class="QLabel" name="label_3">
8064
<property name="text">
@@ -94,8 +78,33 @@
9478
</item>
9579
<item row="3" column="1">
9680
<widget class="QDoubleSpinBox" name="spinOffset">
81+
<property name="alignment">
82+
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
83+
</property>
84+
<property name="decimals">
85+
<number>1</number>
86+
</property>
9787
<property name="minimum">
98-
<double>-99.989999999999995</double>
88+
<double>-100.000000000000000</double>
89+
</property>
90+
</widget>
91+
</item>
92+
<item row="1" column="1">
93+
<widget class="QDoubleSpinBox" name="spinWidth">
94+
<property name="sizePolicy">
95+
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
96+
<horstretch>0</horstretch>
97+
<verstretch>0</verstretch>
98+
</sizepolicy>
99+
</property>
100+
<property name="alignment">
101+
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
102+
</property>
103+
<property name="decimals">
104+
<number>1</number>
105+
</property>
106+
<property name="value">
107+
<double>1.000000000000000</double>
99108
</property>
100109
</widget>
101110
</item>

‎src/ui/symbollayer/widget_simplemarker.ui

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<x>0</x>
88
<y>0</y>
99
<width>394</width>
10-
<height>270</height>
10+
<height>275</height>
1111
</rect>
1212
</property>
1313
<property name="windowTitle">
@@ -67,13 +67,6 @@
6767
</property>
6868
</widget>
6969
</item>
70-
<item row="2" column="1">
71-
<widget class="QSpinBox" name="spinSize">
72-
<property name="minimum">
73-
<number>1</number>
74-
</property>
75-
</widget>
76-
</item>
7770
<item row="3" column="0">
7871
<widget class="QLabel" name="label_4">
7972
<property name="text">
@@ -89,6 +82,9 @@
8982
<property name="maximum">
9083
<double>360.000000000000000</double>
9184
</property>
85+
<property name="singleStep">
86+
<double>5.000000000000000</double>
87+
</property>
9288
</widget>
9389
</item>
9490
<item row="4" column="0">
@@ -122,6 +118,16 @@
122118
</item>
123119
</layout>
124120
</item>
121+
<item row="2" column="1">
122+
<widget class="QDoubleSpinBox" name="spinSize">
123+
<property name="decimals">
124+
<number>1</number>
125+
</property>
126+
<property name="value">
127+
<double>1.000000000000000</double>
128+
</property>
129+
</widget>
130+
</item>
125131
</layout>
126132
</item>
127133
<item>

‎src/ui/symbollayer/widget_svgmarker.ui

Lines changed: 19 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -29,22 +29,6 @@
2929
</property>
3030
</widget>
3131
</item>
32-
<item row="0" column="1">
33-
<widget class="QSpinBox" name="spinSize">
34-
<property name="sizePolicy">
35-
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
36-
<horstretch>0</horstretch>
37-
<verstretch>0</verstretch>
38-
</sizepolicy>
39-
</property>
40-
<property name="minimum">
41-
<number>1</number>
42-
</property>
43-
<property name="value">
44-
<number>5</number>
45-
</property>
46-
</widget>
47-
</item>
4832
<item row="0" column="2" rowspan="3">
4933
<spacer>
5034
<property name="orientation">
@@ -73,6 +57,9 @@
7357
<property name="maximum">
7458
<double>360.000000000000000</double>
7559
</property>
60+
<property name="singleStep">
61+
<double>5.000000000000000</double>
62+
</property>
7663
</widget>
7764
</item>
7865
<item row="2" column="1">
@@ -106,6 +93,22 @@
10693
</property>
10794
</widget>
10895
</item>
96+
<item row="0" column="1">
97+
<widget class="QDoubleSpinBox" name="spinSize">
98+
<property name="sizePolicy">
99+
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
100+
<horstretch>0</horstretch>
101+
<verstretch>0</verstretch>
102+
</sizepolicy>
103+
</property>
104+
<property name="decimals">
105+
<number>1</number>
106+
</property>
107+
<property name="value">
108+
<double>1.000000000000000</double>
109+
</property>
110+
</widget>
111+
</item>
109112
</layout>
110113
</item>
111114
<item>

0 commit comments

Comments
 (0)
Please sign in to comment.