For my PyQGIS plugin 2.2, I try to:
def logFeatureAdded(self,layerId,addfeatures): message = str(layerId) + " has features added: " for feature in addedFeatures: message += str( feature.id() ) + ", " QgsMessageLog.logMessage(message) QApplication.beep() layer.featureAdded.connect(self.logFeatureAdded)
When I try to add a feature, this following error message appears:
TypeError : logFeaturesAdded() takes exactly 3 arguments (2 given).
How can I use the
featureAdded signal properly?