Skip to content

Commit

Permalink
Some symbol layer widget fixes:
Browse files Browse the repository at this point in the history
- Fix broken shapeburst fill widget
- Tweak stretch behaviour of some widgets
  • Loading branch information
nyalldawson committed May 20, 2016
1 parent 0fcff9f commit 8724feb
Show file tree
Hide file tree
Showing 8 changed files with 78 additions and 76 deletions.
6 changes: 6 additions & 0 deletions src/gui/symbology-ng/qgssymbollayerv2widget.cpp
Expand Up @@ -1360,6 +1360,12 @@ QgsShapeburstFillSymbolLayerV2Widget::QgsShapeburstFillSymbolLayerV2Widget( cons
mDistanceUnitWidget->setUnits( QgsSymbolV2::OutputUnitList() << QgsSymbolV2::MM << QgsSymbolV2::MapUnit << QgsSymbolV2::Pixel );
mOffsetUnitWidget->setUnits( QgsSymbolV2::OutputUnitList() << QgsSymbolV2::MM << QgsSymbolV2::MapUnit << QgsSymbolV2::Pixel );

QButtonGroup* group1 = new QButtonGroup( this );
group1->addButton( radioColorRamp );
group1->addButton( radioTwoColor );
QButtonGroup* group2 = new QButtonGroup( this );
group2->addButton( mRadioUseMaxDistance );
group2->addButton( mRadioUseWholeShape );
btnChangeColor->setAllowAlpha( true );
btnChangeColor->setColorDialogTitle( tr( "Select gradient color" ) );
btnChangeColor->setContext( "symbology" );
Expand Down
4 changes: 2 additions & 2 deletions src/ui/symbollayer/qgsarrowsymbollayerwidgetbase.ui
Expand Up @@ -6,7 +6,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>306</width>
<width>418</width>
<height>267</height>
</rect>
</property>
Expand All @@ -16,7 +16,7 @@
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Symbols clip the geometry to the current canvas extent by default. This could result in undesired renderings for this kind of symbol layer. Make sure to check the corresponding &amp;quot;Clip features to canvas extent&amp;quot; advanced option of the symbol.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<layout class="QGridLayout" name="gridLayout" columnstretch="0,1,0">
<item row="2" column="0">
<widget class="QLabel" name="label">
<property name="text">
Expand Down
4 changes: 2 additions & 2 deletions src/ui/symbollayer/widget_filledmarker.ui
Expand Up @@ -6,14 +6,14 @@
<rect>
<x>0</x>
<y>0</y>
<width>275</width>
<width>450</width>
<height>312</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<layout class="QGridLayout" name="gridLayout" columnstretch="0,1,0">
<item row="0" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
Expand Down
6 changes: 3 additions & 3 deletions src/ui/symbollayer/widget_linepatternfill.ui
Expand Up @@ -6,14 +6,14 @@
<rect>
<x>0</x>
<y>0</y>
<width>245</width>
<height>163</height>
<width>327</width>
<height>161</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<layout class="QGridLayout" name="gridLayout" columnstretch="0,1,0">
<item row="0" column="0">
<widget class="QLabel" name="mRotationLabel">
<property name="text">
Expand Down
40 changes: 20 additions & 20 deletions src/ui/symbollayer/widget_markerline.ui
Expand Up @@ -6,7 +6,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>324</width>
<width>371</width>
<height>327</height>
</rect>
</property>
Expand Down Expand Up @@ -187,15 +187,28 @@
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Line offset</string>
<item row="3" column="0" colspan="2">
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
</widget>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
<item row="2" column="1">
<item row="2" column="0" colspan="2">
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="QLabel" name="label_3">
<property name="text">
<string>Line offset</string>
</property>
</widget>
</item>
<item>
<widget class="QgsDoubleSpinBox" name="spinOffset">
<property name="sizePolicy">
Expand Down Expand Up @@ -237,19 +250,6 @@
</item>
</layout>
</item>
<item row="3" column="0" colspan="2">
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<customwidgets>
Expand Down
6 changes: 3 additions & 3 deletions src/ui/symbollayer/widget_pointpatternfill.ui
Expand Up @@ -6,14 +6,14 @@
<rect>
<x>0</x>
<y>0</y>
<width>331</width>
<height>198</height>
<width>401</width>
<height>206</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<layout class="QGridLayout" name="gridLayout" columnstretch="0,1,0">
<item row="0" column="0">
<widget class="QLabel" name="mHorizontalDistanceLabel">
<property name="text">
Expand Down
72 changes: 34 additions & 38 deletions src/ui/symbollayer/widget_shapeburstfill.ui
Expand Up @@ -6,14 +6,14 @@
<rect>
<x>0</x>
<y>0</y>
<width>374</width>
<width>418</width>
<height>429</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<layout class="QGridLayout" name="gridLayout" columnstretch="0,1,0,0,0">
<item row="9" column="0">
<widget class="QLabel" name="label">
<property name="text">
Expand Down Expand Up @@ -188,19 +188,6 @@
</property>
</widget>
</item>
<item row="11" column="1">
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
<item row="1" column="4">
<widget class="QgsDataDefinedButton" name="mStartColorDDBtn">
<property name="text">
Expand Down Expand Up @@ -296,19 +283,6 @@
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_3">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="text">
<string>Shading style</string>
</property>
</widget>
</item>
<item row="10" column="1" colspan="3">
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0">
Expand Down Expand Up @@ -384,17 +358,39 @@
</item>
</layout>
</item>
<item row="4" column="0" colspan="4">
<widget class="QLabel" name="label_3">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="text">
<string>Shading style</string>
</property>
</widget>
</item>
<item row="11" column="0">
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
<zorder>label</zorder>
<zorder>label_6</zorder>
<zorder>label_2</zorder>
<zorder>radioTwoColor</zorder>
<zorder>radioColorRamp</zorder>
<zorder>label_3</zorder>
<zorder>mRadioUseWholeShape</zorder>
<zorder>mRadioUseMaxDistance</zorder>
<zorder>mIgnoreRingsCheckBox</zorder>
<zorder>mRadioUseWholeShape</zorder>
<zorder>mStartColorDDBtn</zorder>
<zorder>mEndColorDDBtn</zorder>
<zorder>btnChangeColor</zorder>
Expand All @@ -405,12 +401,6 @@
<zorder>mBlurRadiusDDBtn</zorder>
</widget>
<customwidgets>
<customwidget>
<class>QgsColorButtonV2</class>
<extends>QToolButton</extends>
<header>qgscolorbuttonv2.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>QgsDataDefinedButton</class>
<extends>QToolButton</extends>
Expand All @@ -427,6 +417,12 @@
<header>qgsunitselectionwidget.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>QgsColorButtonV2</class>
<extends>QToolButton</extends>
<header>qgscolorbuttonv2.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>QgsColorRampComboBox</class>
<extends>QComboBox</extends>
Expand Down
16 changes: 8 additions & 8 deletions src/ui/symbollayer/widget_svgmarker.ui
Expand Up @@ -6,14 +6,14 @@
<rect>
<x>0</x>
<y>0</y>
<width>275</width>
<width>445</width>
<height>663</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
<layout class="QGridLayout" name="gridLayout_2">
<layout class="QGridLayout" name="gridLayout_2" columnstretch="0,1,0">
<item row="1" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
Expand Down Expand Up @@ -519,12 +519,6 @@
</layout>
</widget>
<customwidgets>
<customwidget>
<class>QgsColorButtonV2</class>
<extends>QToolButton</extends>
<header>qgscolorbuttonv2.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>QgsDataDefinedButton</class>
<extends>QToolButton</extends>
Expand All @@ -541,6 +535,12 @@
<header>qgsunitselectionwidget.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>QgsColorButtonV2</class>
<extends>QToolButton</extends>
<header>qgscolorbuttonv2.h</header>
<container>1</container>
</customwidget>
</customwidgets>
<tabstops>
<tabstop>spinSize</tabstop>
Expand Down

0 comments on commit 8724feb

Please sign in to comment.