Skip to content

Commit efb0c40

Browse files
committed
Add missing diagram is obstacle property button
1 parent 0dfa4ef commit efb0c40

File tree

2 files changed

+107
-55
lines changed

2 files changed

+107
-55
lines changed

src/app/qgsdiagramproperties.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -418,6 +418,7 @@ QgsDiagramProperties::QgsDiagramProperties( QgsVectorLayer* layer, QWidget* pare
418418
registerDataDefinedButton( mZOrderDDBtn, QgsDiagramLayerSettings::ZIndex );
419419
registerDataDefinedButton( mShowDiagramDDBtn, QgsDiagramLayerSettings::Show );
420420
registerDataDefinedButton( mAlwaysShowDDBtn, QgsDiagramLayerSettings::AlwaysShow );
421+
registerDataDefinedButton( mIsObstacleDDBtn, QgsDiagramLayerSettings::IsObstacle );
421422
registerDataDefinedButton( mStartAngleDDBtn, QgsDiagramLayerSettings::StartAngle );
422423
}
423424

src/ui/qgsdiagrampropertiesbase.ui

+106-55
Original file line numberDiff line numberDiff line change
@@ -303,8 +303,8 @@
303303
<rect>
304304
<x>0</x>
305305
<y>0</y>
306-
<width>632</width>
307-
<height>415</height>
306+
<width>303</width>
307+
<height>104</height>
308308
</rect>
309309
</property>
310310
<layout class="QHBoxLayout" name="horizontalLayout_6">
@@ -538,9 +538,9 @@
538538
<property name="geometry">
539539
<rect>
540540
<x>0</x>
541-
<y>0</y>
542-
<width>632</width>
543-
<height>415</height>
541+
<y>-93</y>
542+
<width>618</width>
543+
<height>498</height>
544544
</rect>
545545
</property>
546546
<layout class="QVBoxLayout" name="verticalLayout" stretch="0,0,0,1">
@@ -856,6 +856,13 @@
856856
</item>
857857
</layout>
858858
</item>
859+
<item row="1" column="2">
860+
<widget class="QGroupBox" name="groupBox">
861+
<property name="title">
862+
<string>GroupBox</string>
863+
</property>
864+
</widget>
865+
</item>
859866
</layout>
860867
</widget>
861868
</item>
@@ -954,18 +961,21 @@
954961
<property name="verticalSpacing">
955962
<number>6</number>
956963
</property>
957-
<item row="1" column="6">
958-
<spacer name="horizontalSpacer_23">
959-
<property name="orientation">
960-
<enum>Qt::Horizontal</enum>
964+
<item row="1" column="1">
965+
<widget class="QLabel" name="mShowLabelLabel">
966+
<property name="enabled">
967+
<bool>true</bool>
961968
</property>
962-
<property name="sizeHint" stdset="0">
963-
<size>
964-
<width>195</width>
965-
<height>20</height>
966-
</size>
969+
<property name="sizePolicy">
970+
<sizepolicy hsizetype="Maximum" vsizetype="Preferred">
971+
<horstretch>0</horstretch>
972+
<verstretch>0</verstretch>
973+
</sizepolicy>
967974
</property>
968-
</spacer>
975+
<property name="text">
976+
<string>Show diagram</string>
977+
</property>
978+
</widget>
969979
</item>
970980
<item row="1" column="2">
971981
<widget class="QgsPropertyOverrideButton" name="mShowDiagramDDBtn">
@@ -974,10 +984,10 @@
974984
</property>
975985
</widget>
976986
</item>
977-
<item row="1" column="5">
978-
<widget class="QgsPropertyOverrideButton" name="mAlwaysShowDDBtn">
979-
<property name="text">
980-
<string>...</string>
987+
<item row="1" column="3">
988+
<widget class="Line" name="line_4">
989+
<property name="orientation">
990+
<enum>Qt::Vertical</enum>
981991
</property>
982992
</widget>
983993
</item>
@@ -994,19 +1004,10 @@
9941004
</property>
9951005
</widget>
9961006
</item>
997-
<item row="1" column="1">
998-
<widget class="QLabel" name="mShowLabelLabel">
999-
<property name="enabled">
1000-
<bool>true</bool>
1001-
</property>
1002-
<property name="sizePolicy">
1003-
<sizepolicy hsizetype="Maximum" vsizetype="Preferred">
1004-
<horstretch>0</horstretch>
1005-
<verstretch>0</verstretch>
1006-
</sizepolicy>
1007-
</property>
1007+
<item row="1" column="5">
1008+
<widget class="QgsPropertyOverrideButton" name="mAlwaysShowDDBtn">
10081009
<property name="text">
1009-
<string>Show diagram</string>
1010+
<string>...</string>
10101011
</property>
10111012
</widget>
10121013
</item>
@@ -1026,20 +1027,57 @@
10261027
</property>
10271028
</spacer>
10281029
</item>
1029-
<item row="1" column="3">
1030-
<widget class="Line" name="line_4">
1031-
<property name="orientation">
1032-
<enum>Qt::Vertical</enum>
1033-
</property>
1034-
</widget>
1035-
</item>
10361030
<item row="0" column="0" colspan="7">
10371031
<widget class="QLabel" name="label_7">
10381032
<property name="text">
10391033
<string>Data defined</string>
10401034
</property>
10411035
</widget>
10421036
</item>
1037+
<item row="1" column="6">
1038+
<spacer name="horizontalSpacer_23">
1039+
<property name="orientation">
1040+
<enum>Qt::Horizontal</enum>
1041+
</property>
1042+
<property name="sizeHint" stdset="0">
1043+
<size>
1044+
<width>195</width>
1045+
<height>20</height>
1046+
</size>
1047+
</property>
1048+
</spacer>
1049+
</item>
1050+
<item row="4" column="1" colspan="6">
1051+
<layout class="QHBoxLayout" name="horizontalLayout_12">
1052+
<item>
1053+
<widget class="QLabel" name="label_8">
1054+
<property name="text">
1055+
<string>Discourage labels from covering features</string>
1056+
</property>
1057+
</widget>
1058+
</item>
1059+
<item>
1060+
<widget class="QgsPropertyOverrideButton" name="mIsObstacleDDBtn">
1061+
<property name="text">
1062+
<string>...</string>
1063+
</property>
1064+
</widget>
1065+
</item>
1066+
<item>
1067+
<spacer name="horizontalSpacer">
1068+
<property name="orientation">
1069+
<enum>Qt::Horizontal</enum>
1070+
</property>
1071+
<property name="sizeHint" stdset="0">
1072+
<size>
1073+
<width>40</width>
1074+
<height>20</height>
1075+
</size>
1076+
</property>
1077+
</spacer>
1078+
</item>
1079+
</layout>
1080+
</item>
10431081
</layout>
10441082
</widget>
10451083
</item>
@@ -1099,8 +1137,8 @@
10991137
<rect>
11001138
<x>0</x>
11011139
<y>0</y>
1102-
<width>632</width>
1103-
<height>415</height>
1140+
<width>511</width>
1141+
<height>294</height>
11041142
</rect>
11051143
</property>
11061144
<layout class="QGridLayout" name="gridLayout_11">
@@ -1415,8 +1453,8 @@
14151453
<rect>
14161454
<x>0</x>
14171455
<y>0</y>
1418-
<width>632</width>
1419-
<height>415</height>
1456+
<width>280</width>
1457+
<height>288</height>
14201458
</rect>
14211459
</property>
14221460
<layout class="QGridLayout" name="gridLayout_12">
@@ -1841,8 +1879,8 @@
18411879
<rect>
18421880
<x>0</x>
18431881
<y>0</y>
1844-
<width>632</width>
1845-
<height>415</height>
1882+
<width>100</width>
1883+
<height>180</height>
18461884
</rect>
18471885
</property>
18481886
<layout class="QVBoxLayout" name="verticalLayout_3">
@@ -2060,8 +2098,8 @@
20602098
<rect>
20612099
<x>0</x>
20622100
<y>0</y>
2063-
<width>632</width>
2064-
<height>415</height>
2101+
<width>324</width>
2102+
<height>131</height>
20652103
</rect>
20662104
</property>
20672105
<layout class="QVBoxLayout" name="verticalLayout_12">
@@ -2139,28 +2177,28 @@
21392177
</widget>
21402178
<customwidgets>
21412179
<customwidget>
2142-
<class>QgsCollapsibleGroupBox</class>
2143-
<extends>QGroupBox</extends>
2144-
<header>qgscollapsiblegroupbox.h</header>
2145-
<container>1</container>
2180+
<class>QgsDoubleSpinBox</class>
2181+
<extends>QDoubleSpinBox</extends>
2182+
<header>qgsdoublespinbox.h</header>
21462183
</customwidget>
21472184
<customwidget>
21482185
<class>QgsColorButton</class>
21492186
<extends>QToolButton</extends>
21502187
<header>qgscolorbutton.h</header>
21512188
<container>1</container>
21522189
</customwidget>
2153-
<customwidget>
2154-
<class>QgsDoubleSpinBox</class>
2155-
<extends>QDoubleSpinBox</extends>
2156-
<header>qgsdoublespinbox.h</header>
2157-
</customwidget>
21582190
<customwidget>
21592191
<class>QgsFieldExpressionWidget</class>
21602192
<extends>QWidget</extends>
21612193
<header>qgsfieldexpressionwidget.h</header>
21622194
<container>1</container>
21632195
</customwidget>
2196+
<customwidget>
2197+
<class>QgsCollapsibleGroupBox</class>
2198+
<extends>QGroupBox</extends>
2199+
<header>qgscollapsiblegroupbox.h</header>
2200+
<container>1</container>
2201+
</customwidget>
21642202
<customwidget>
21652203
<class>QgsScaleRangeWidget</class>
21662204
<extends>QWidget</extends>
@@ -2233,6 +2271,19 @@
22332271
<tabstop>mCheckBoxAttributeLegend</tabstop>
22342272
<tabstop>mCheckBoxSizeLegend</tabstop>
22352273
<tabstop>mButtonSizeLegendSymbol</tabstop>
2274+
<tabstop>mBackgroundColorDDBtn</tabstop>
2275+
<tabstop>mLineColorDDBtn</tabstop>
2276+
<tabstop>mDiagramLineUnitComboBox</tabstop>
2277+
<tabstop>mLineWidthDDBtn</tabstop>
2278+
<tabstop>mStartAngleDDBtn</tabstop>
2279+
<tabstop>mShowDiagramDDBtn</tabstop>
2280+
<tabstop>mAlwaysShowDDBtn</tabstop>
2281+
<tabstop>mIsObstacleDDBtn</tabstop>
2282+
<tabstop>mDistanceDDBtn</tabstop>
2283+
<tabstop>mPriorityDDBtn</tabstop>
2284+
<tabstop>mZOrderDDBtn</tabstop>
2285+
<tabstop>mCoordXDDBtn</tabstop>
2286+
<tabstop>mCoordYDDBtn</tabstop>
22362287
</tabstops>
22372288
<resources>
22382289
<include location="../../images/images.qrc"/>

0 commit comments

Comments
 (0)