Skip to content
Permalink
Browse files

Fix #6063

  • Loading branch information
ddanielvaz committed Jul 14, 2013
1 parent f340ca0 commit f8e2cacf45a095b95733762d405f62f4de519c99
Showing with 2 additions and 8 deletions.
  1. +2 −8 python/plugins/fTools/tools/doGeoprocessing.py
@@ -467,13 +467,9 @@ def convex_hull(self, useField ):
outFeatFields = QgsFields()
if useField:
importedField = vproviderA.fields().at( self.myParam )
outFeatFields.append( importedField )
#
importedFieldName = importedField.name( )
else:
outIdField = QgsField( "hullGeneratedID", QVariant.String )
outFeatFields.append( outIdField )
# creating fields
outFeatFields.append( importedField )
# creating area and perimeter fields
areaField = QgsField("area", QVariant.Double)
perimField = QgsField("perim", QVariant.Double)
# appending fields
@@ -551,7 +547,6 @@ def convex_hull(self, useField ):
(area, perim) = self.simpleMeasure( outGeom )
for f in inFeat.fields():
outFeat.setAttribute( f.name( ), inFeat.attribute( f.name( ) ) )
outFeat.setAttribute( "hullGeneratedID", 'hullPolygonGenerated' )
outFeat.setAttribute( "area", area )
outFeat.setAttribute( "perim", perim )
writer.addFeature( outFeat )
@@ -613,7 +608,6 @@ def convex_hull(self, useField ):
(area, perim) = self.simpleMeasure( outGeom )
for f in inFeat.fields():
outFeat.setAttribute( f.name( ), inFeat.attribute( f.name( ) ) )
outFeat.setAttribute( "hullGeneratedID", 'hullPolygonGenerated' )
outFeat.setAttribute( "area", area )
outFeat.setAttribute( "perim", perim )
writer.addFeature( outFeat )

0 comments on commit f8e2cac

Please sign in to comment.
You can’t perform that action at this time.