[QGIS Commit] r15292 - trunk/qgis/python/plugins/fTools/tools

svn_qgis at osgeo.org svn_qgis at osgeo.org
Mon Feb 28 17:40:23 EST 2011


Author: cfarmer
Date: 2011-02-28 14:40:23 -0800 (Mon, 28 Feb 2011)
New Revision: 15292

Modified:
   trunk/qgis/python/plugins/fTools/tools/doMeanCoords.py
Log:
removes symbology which may cause problems with new/old symbology

Modified: trunk/qgis/python/plugins/fTools/tools/doMeanCoords.py
===================================================================
--- trunk/qgis/python/plugins/fTools/tools/doMeanCoords.py	2011-02-28 22:37:08 UTC (rev 15291)
+++ trunk/qgis/python/plugins/fTools/tools/doMeanCoords.py	2011-02-28 22:40:23 UTC (rev 15292)
@@ -65,17 +65,8 @@
             self.outShape.clear()
             addToTOC = QMessageBox.question(self, self.tr("Coordinate statistics"), self.tr("Created output point shapefile:\n%1\n\nWould you like to add the new layer to the TOC?").arg( outPath ), QMessageBox.Yes, QMessageBox.No, QMessageBox.NoButton)
             if addToTOC == QMessageBox.Yes:
-                self.vlayer = QgsVectorLayer(outPath, unicode(outName), "ogr")
-                if self.vlayer.geometryType() == QGis.Point:
-                    render = QgsSingleSymbolRenderer(QGis.Point)
-                    symbol = QgsSymbol(QGis.Point)
-                    symbol.setFillColor(Qt.red)
-                    symbol.setFillStyle(Qt.SolidPattern)
-                    symbol.setColor(Qt.red)
-                    symbol.setPointSize(5)
-                    render.addSymbol(symbol)
-                    self.vlayer.setRenderer(render)
-                QgsMapLayerRegistry.instance().addMapLayer(self.vlayer)
+                vlayer = QgsVectorLayer(outPath, unicode(outName), "ogr")
+                QgsMapLayerRegistry.instance().addMapLayer(vlayer)
         self.progressBar.setValue(0)
         self.buttonOk.setEnabled( True )
 



More information about the QGIS-commit mailing list