Skip to content

Commit 71d88a7

Browse files
committedOct 22, 2015
[composer] Fix wording of scalebar widget controls (fix #12063)
Also add some tooltips to clarify meaning of various controls
1 parent 0886e98 commit 71d88a7

File tree

1 file changed

+48
-27
lines changed

1 file changed

+48
-27
lines changed
 

‎src/ui/composer/qgscomposerscalebarwidgetbase.ui

Lines changed: 48 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060
<property name="geometry">
6161
<rect>
6262
<x>0</x>
63-
<y>-275</y>
63+
<y>0</y>
6464
<width>438</width>
6565
<height>914</height>
6666
</rect>
@@ -143,38 +143,32 @@
143143
<property name="collapsed" stdset="0">
144144
<bool>false</bool>
145145
</property>
146-
<layout class="QGridLayout" name="gridLayout_2" columnstretch="0,1">
147-
<item row="1" column="0">
148-
<widget class="QLabel" name="mUnitLabelLabel">
146+
<layout class="QGridLayout" name="gridLayout_2" columnstretch="0,0">
147+
<item row="0" column="0">
148+
<widget class="QLabel" name="label_12">
149149
<property name="text">
150-
<string>&amp;Label</string>
151-
</property>
152-
<property name="wordWrap">
153-
<bool>true</bool>
154-
</property>
155-
<property name="buddy">
156-
<cstring>mUnitLabelLineEdit</cstring>
150+
<string>Scalebar units</string>
157151
</property>
158152
</widget>
159153
</item>
160-
<item row="1" column="1">
161-
<widget class="QLineEdit" name="mUnitLabelLineEdit"/>
162-
</item>
163154
<item row="2" column="0">
164-
<widget class="QLabel" name="mMapUnitsPerBarUnitLabel">
155+
<widget class="QLabel" name="mUnitLabelLabel">
165156
<property name="text">
166-
<string>Map &amp;units per bar unit</string>
157+
<string>&amp;Label for units</string>
167158
</property>
168159
<property name="wordWrap">
169-
<bool>false</bool>
160+
<bool>true</bool>
170161
</property>
171162
<property name="buddy">
172-
<cstring>mMapUnitsPerBarUnitSpinBox</cstring>
163+
<cstring>mUnitLabelLineEdit</cstring>
173164
</property>
174165
</widget>
175166
</item>
176-
<item row="2" column="1">
167+
<item row="1" column="1">
177168
<widget class="QgsDoubleSpinBox" name="mMapUnitsPerBarUnitSpinBox">
169+
<property name="toolTip">
170+
<string>Specifies how many scalebar units per labeled unit. Eg, if your scalebar units are set to &quot;meters&quot;, a multiplier of 1000 will result in the scalebar labels in kilometers.</string>
171+
</property>
178172
<property name="decimals">
179173
<number>6</number>
180174
</property>
@@ -186,8 +180,32 @@
186180
</property>
187181
</widget>
188182
</item>
189-
<item row="0" column="0" colspan="2">
190-
<widget class="QComboBox" name="mUnitsComboBox"/>
183+
<item row="2" column="1">
184+
<widget class="QLineEdit" name="mUnitLabelLineEdit">
185+
<property name="toolTip">
186+
<string>Text used for labeling the scalebar units, eg &quot;m&quot; or &quot;km&quot;. This should be matched to the reflect the multiplier above. </string>
187+
</property>
188+
</widget>
189+
</item>
190+
<item row="0" column="1">
191+
<widget class="QComboBox" name="mUnitsComboBox">
192+
<property name="toolTip">
193+
<string>Specifies the underlying units used for scalebar calculations, eg &quot;meters&quot; or &quot;feet&quot;</string>
194+
</property>
195+
</widget>
196+
</item>
197+
<item row="1" column="0">
198+
<widget class="QLabel" name="mMapUnitsPerBarUnitLabel">
199+
<property name="text">
200+
<string>Label unit multiplier</string>
201+
</property>
202+
<property name="wordWrap">
203+
<bool>false</bool>
204+
</property>
205+
<property name="buddy">
206+
<cstring>mMapUnitsPerBarUnitSpinBox</cstring>
207+
</property>
208+
</widget>
191209
</item>
192210
</layout>
193211
</widget>
@@ -216,6 +234,9 @@
216234
</item>
217235
<item row="2" column="2">
218236
<widget class="QgsDoubleSpinBox" name="mSegmentSizeSpinBox">
237+
<property name="toolTip">
238+
<string>Number of scalebar units per scalebar segment</string>
239+
</property>
219240
<property name="suffix">
220241
<string> units</string>
221242
</property>
@@ -664,11 +685,6 @@
664685
<extends>QDoubleSpinBox</extends>
665686
<header>qgsdoublespinbox.h</header>
666687
</customwidget>
667-
<customwidget>
668-
<class>QgsSpinBox</class>
669-
<extends>QSpinBox</extends>
670-
<header>qgsspinbox.h</header>
671-
</customwidget>
672688
<customwidget>
673689
<class>QgsPenJoinStyleComboBox</class>
674690
<extends>QComboBox</extends>
@@ -679,6 +695,11 @@
679695
<extends>QComboBox</extends>
680696
<header>qgspenstylecombobox.h</header>
681697
</customwidget>
698+
<customwidget>
699+
<class>QgsSpinBox</class>
700+
<extends>QSpinBox</extends>
701+
<header>qgsspinbox.h</header>
702+
</customwidget>
682703
<customwidget>
683704
<class>QgsCollapsibleGroupBoxBasic</class>
684705
<extends>QGroupBox</extends>
@@ -693,8 +714,8 @@
693714
<tabstop>mStyleComboBox</tabstop>
694715
<tabstop>mGroupBoxUnits</tabstop>
695716
<tabstop>mUnitsComboBox</tabstop>
696-
<tabstop>mUnitLabelLineEdit</tabstop>
697717
<tabstop>mMapUnitsPerBarUnitSpinBox</tabstop>
718+
<tabstop>mUnitLabelLineEdit</tabstop>
698719
<tabstop>mGroupBoxSegments</tabstop>
699720
<tabstop>mSegmentsLeftSpinBox</tabstop>
700721
<tabstop>mNumberOfSegmentsSpinBox</tabstop>

0 commit comments

Comments
 (0)
Please sign in to comment.