[QGIS Commit] r14734 - trunk/qgis/python/plugins/fTools/tools
svn_qgis at osgeo.org
svn_qgis at osgeo.org
Sun Nov 21 17:33:42 EST 2010
Author: cfarmer
Date: 2010-11-21 14:33:42 -0800 (Sun, 21 Nov 2010)
New Revision: 14734
Modified:
trunk/qgis/python/plugins/fTools/tools/doRandPoints.py
trunk/qgis/python/plugins/fTools/tools/frmRandPoints.ui
Log:
Removes extraneous minimum distance option (not currently a real option) from random points tool. Addresses #3213
Modified: trunk/qgis/python/plugins/fTools/tools/doRandPoints.py
===================================================================
--- trunk/qgis/python/plugins/fTools/tools/doRandPoints.py 2010-11-21 22:22:27 UTC (rev 14733)
+++ trunk/qgis/python/plugins/fTools/tools/doRandPoints.py 2010-11-21 22:33:42 UTC (rev 14734)
@@ -116,10 +116,7 @@
value = self.spnUnstratified.value()
else:
QMessageBox.information(self, self.tr("Random Points"), self.tr("Unknown layer type..."))
- if self.chkMinimum.isChecked():
- minimum = self.spnMinimum.value()
- else:
- minimum = 0.00
+ minimum = 0.00
self.progressBar.setValue(10)
self.randomize(inLayer, outPath, minimum, design, value)
self.progressBar.setValue(100)
Modified: trunk/qgis/python/plugins/fTools/tools/frmRandPoints.ui
===================================================================
--- trunk/qgis/python/plugins/fTools/tools/frmRandPoints.ui 2010-11-21 22:22:27 UTC (rev 14733)
+++ trunk/qgis/python/plugins/fTools/tools/frmRandPoints.ui 2010-11-21 22:33:42 UTC (rev 14734)
@@ -1,188 +1,168 @@
-<ui version="4.0" >
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
<class>Dialog</class>
- <widget class="QDialog" name="Dialog" >
- <property name="windowModality" >
+ <widget class="QDialog" name="Dialog">
+ <property name="windowModality">
<enum>Qt::NonModal</enum>
</property>
- <property name="geometry" >
+ <property name="geometry">
<rect>
<x>0</x>
<y>0</y>
- <width>373</width>
+ <width>384</width>
<height>435</height>
</rect>
</property>
- <property name="windowTitle" >
+ <property name="windowTitle">
<string>Generate Random Points</string>
</property>
- <property name="sizeGripEnabled" >
+ <property name="sizeGripEnabled">
<bool>true</bool>
</property>
- <layout class="QGridLayout" name="gridLayout" >
- <item row="0" column="0" >
- <widget class="QLabel" name="label_3" >
- <property name="sizePolicy" >
- <sizepolicy vsizetype="Fixed" hsizetype="Fixed" >
+ <layout class="QGridLayout" name="gridLayout">
+ <item row="0" column="0">
+ <widget class="QLabel" name="label_3">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="text" >
+ <property name="text">
<string>Input Boundary Layer</string>
</property>
</widget>
</item>
- <item row="1" column="0" colspan="2" >
- <widget class="QComboBox" name="inShape" />
+ <item row="1" column="0" colspan="2">
+ <widget class="QComboBox" name="inShape"/>
</item>
- <item row="2" column="0" colspan="2" >
- <layout class="QHBoxLayout" >
- <item>
- <widget class="QCheckBox" name="chkMinimum" >
- <property name="enabled" >
- <bool>false</bool>
- </property>
- <property name="text" >
- <string>Minimum distance between points</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QSpinBox" name="spnMinimum" >
- <property name="enabled" >
- <bool>false</bool>
- </property>
- </widget>
- </item>
- </layout>
- </item>
- <item row="3" column="0" colspan="2" >
- <widget class="QGroupBox" name="groupBox" >
- <property name="title" >
+ <item row="2" column="0" colspan="2">
+ <widget class="QGroupBox" name="groupBox">
+ <property name="title">
<string>Sample Size</string>
</property>
- <layout class="QGridLayout" >
- <item row="0" column="0" >
- <widget class="QLabel" name="label" >
- <property name="font" >
+ <layout class="QGridLayout">
+ <item row="0" column="0">
+ <widget class="QLabel" name="label">
+ <property name="font">
<font>
<pointsize>9</pointsize>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
- <property name="text" >
+ <property name="text">
<string>Unstratified Sampling Design (Entire layer)</string>
</property>
</widget>
</item>
- <item row="1" column="0" >
- <layout class="QHBoxLayout" >
+ <item row="1" column="0">
+ <layout class="QHBoxLayout">
<item>
- <widget class="QRadioButton" name="rdoUnstratified" >
- <property name="text" >
+ <widget class="QRadioButton" name="rdoUnstratified">
+ <property name="text">
<string>Use this number of points</string>
</property>
- <property name="checked" >
+ <property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item>
- <widget class="QSpinBox" name="spnUnstratified" >
- <property name="enabled" >
+ <widget class="QSpinBox" name="spnUnstratified">
+ <property name="enabled">
<bool>true</bool>
</property>
- <property name="minimum" >
+ <property name="minimum">
<number>1</number>
</property>
- <property name="maximum" >
+ <property name="maximum">
<number>9999</number>
</property>
</widget>
</item>
</layout>
</item>
- <item row="2" column="0" >
- <widget class="QLabel" name="label_4" >
- <property name="font" >
+ <item row="2" column="0">
+ <widget class="QLabel" name="label_4">
+ <property name="font">
<font>
<pointsize>9</pointsize>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
- <property name="text" >
+ <property name="text">
<string>Stratified Sampling Design (Individual polygons)</string>
</property>
</widget>
</item>
- <item row="3" column="0" >
- <layout class="QHBoxLayout" >
+ <item row="3" column="0">
+ <layout class="QHBoxLayout">
<item>
- <widget class="QRadioButton" name="rdoStratified" >
- <property name="text" >
+ <widget class="QRadioButton" name="rdoStratified">
+ <property name="text">
<string>Use this number of points</string>
</property>
</widget>
</item>
<item>
- <widget class="QSpinBox" name="spnStratified" >
- <property name="enabled" >
+ <widget class="QSpinBox" name="spnStratified">
+ <property name="enabled">
<bool>false</bool>
</property>
- <property name="minimum" >
+ <property name="minimum">
<number>1</number>
</property>
- <property name="maximum" >
+ <property name="maximum">
<number>9999</number>
</property>
</widget>
</item>
</layout>
</item>
- <item row="4" column="0" >
- <layout class="QHBoxLayout" >
+ <item row="4" column="0">
+ <layout class="QHBoxLayout">
<item>
- <widget class="QRadioButton" name="rdoDensity" >
- <property name="text" >
+ <widget class="QRadioButton" name="rdoDensity">
+ <property name="text">
<string>Use this density of points</string>
</property>
</widget>
</item>
<item>
- <widget class="QDoubleSpinBox" name="spnDensity" >
- <property name="enabled" >
+ <widget class="QDoubleSpinBox" name="spnDensity">
+ <property name="enabled">
<bool>false</bool>
</property>
- <property name="decimals" >
+ <property name="decimals">
<number>4</number>
</property>
- <property name="minimum" >
+ <property name="minimum">
<double>0.000100000000000</double>
</property>
- <property name="singleStep" >
+ <property name="singleStep">
<double>0.000100000000000</double>
</property>
- <property name="value" >
+ <property name="value">
<double>0.000100000000000</double>
</property>
</widget>
</item>
</layout>
</item>
- <item row="5" column="0" >
- <layout class="QHBoxLayout" >
+ <item row="5" column="0">
+ <layout class="QHBoxLayout">
<item>
- <widget class="QRadioButton" name="rdoField" >
- <property name="text" >
+ <widget class="QRadioButton" name="rdoField">
+ <property name="text">
<string>Use value from input field</string>
</property>
</widget>
</item>
<item>
- <widget class="QComboBox" name="cmbField" >
- <property name="enabled" >
+ <widget class="QComboBox" name="cmbField">
+ <property name="enabled">
<bool>false</bool>
</property>
</widget>
@@ -192,56 +172,56 @@
</layout>
</widget>
</item>
- <item row="4" column="0" >
- <widget class="QLabel" name="label_2" >
- <property name="sizePolicy" >
- <sizepolicy vsizetype="Fixed" hsizetype="Fixed" >
+ <item row="3" column="0">
+ <widget class="QLabel" name="label_2">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="text" >
+ <property name="text">
<string>Output Shapefile</string>
</property>
</widget>
</item>
- <item row="5" column="0" colspan="2" >
- <layout class="QHBoxLayout" >
+ <item row="4" column="0" colspan="2">
+ <layout class="QHBoxLayout">
<item>
- <widget class="QLineEdit" name="outShape" >
- <property name="readOnly" >
+ <widget class="QLineEdit" name="outShape">
+ <property name="readOnly">
<bool>true</bool>
</property>
</widget>
</item>
<item>
- <widget class="QToolButton" name="toolOut" >
- <property name="text" >
+ <widget class="QToolButton" name="toolOut">
+ <property name="text">
<string>Browse</string>
</property>
</widget>
</item>
</layout>
</item>
- <item row="6" column="0" >
- <widget class="QProgressBar" name="progressBar" >
- <property name="value" >
+ <item row="5" column="0">
+ <widget class="QProgressBar" name="progressBar">
+ <property name="value">
<number>24</number>
</property>
- <property name="alignment" >
+ <property name="alignment">
<set>Qt::AlignCenter</set>
</property>
- <property name="textVisible" >
+ <property name="textVisible">
<bool>true</bool>
</property>
</widget>
</item>
- <item row="6" column="1" >
- <widget class="QDialogButtonBox" name="buttonBox_2" >
- <property name="orientation" >
+ <item row="5" column="1">
+ <widget class="QDialogButtonBox" name="buttonBox_2">
+ <property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
- <property name="standardButtons" >
+ <property name="standardButtons">
<set>QDialogButtonBox::Close|QDialogButtonBox::Ok</set>
</property>
</widget>
@@ -256,11 +236,11 @@
<receiver>Dialog</receiver>
<slot>accept()</slot>
<hints>
- <hint type="sourcelabel" >
+ <hint type="sourcelabel">
<x>133</x>
<y>408</y>
</hint>
- <hint type="destinationlabel" >
+ <hint type="destinationlabel">
<x>215</x>
<y>290</y>
</hint>
@@ -272,11 +252,11 @@
<receiver>Dialog</receiver>
<slot>close()</slot>
<hints>
- <hint type="sourcelabel" >
+ <hint type="sourcelabel">
<x>59</x>
<y>408</y>
</hint>
- <hint type="destinationlabel" >
+ <hint type="destinationlabel">
<x>132</x>
<y>239</y>
</hint>
@@ -288,11 +268,11 @@
<receiver>spnUnstratified</receiver>
<slot>setEnabled(bool)</slot>
<hints>
- <hint type="sourcelabel" >
+ <hint type="sourcelabel">
<x>102</x>
<y>161</y>
</hint>
- <hint type="destinationlabel" >
+ <hint type="destinationlabel">
<x>218</x>
<y>164</y>
</hint>
@@ -304,11 +284,11 @@
<receiver>spnStratified</receiver>
<slot>setEnabled(bool)</slot>
<hints>
- <hint type="sourcelabel" >
+ <hint type="sourcelabel">
<x>101</x>
<y>219</y>
</hint>
- <hint type="destinationlabel" >
+ <hint type="destinationlabel">
<x>247</x>
<y>223</y>
</hint>
@@ -320,43 +300,27 @@
<receiver>cmbField</receiver>
<slot>setEnabled(bool)</slot>
<hints>
- <hint type="sourcelabel" >
+ <hint type="sourcelabel">
<x>150</x>
<y>280</y>
</hint>
- <hint type="destinationlabel" >
+ <hint type="destinationlabel">
<x>219</x>
<y>281</y>
</hint>
</hints>
</connection>
<connection>
- <sender>chkMinimum</sender>
- <signal>toggled(bool)</signal>
- <receiver>spnMinimum</receiver>
- <slot>setEnabled(bool)</slot>
- <hints>
- <hint type="sourcelabel" >
- <x>172</x>
- <y>74</y>
- </hint>
- <hint type="destinationlabel" >
- <x>260</x>
- <y>80</y>
- </hint>
- </hints>
- </connection>
- <connection>
<sender>rdoDensity</sender>
<signal>toggled(bool)</signal>
<receiver>spnDensity</receiver>
<slot>setEnabled(bool)</slot>
<hints>
- <hint type="sourcelabel" >
+ <hint type="sourcelabel">
<x>96</x>
<y>251</y>
</hint>
- <hint type="destinationlabel" >
+ <hint type="destinationlabel">
<x>221</x>
<y>254</y>
</hint>
More information about the QGIS-commit
mailing list