openFeatureForm() is what you are looking for: http://doc.qgis.org/api/2.18/classQgisInterface.html#a11b90f38afd09ac5e9f363933ee4a509
C Hamilton <[email protected]> escreveu no dia sexta, 17/11/2017 às 17:02: > When a points vector layer is enabled for editing, and the "Add Feature" > tool is selected, when you click on the map you get a popup dialog ("Points > - Feature Attributes") that allows you to enter the vector layer attributes. > > Is it possible to programmatically access this dialog from a plugin that > is going to add a point to the map, but would like an attribute dialog to > pop up for entering the attributes? I would rather make use of the existing > function and not reinvent it. > > Is there a difference between these two functions when adding a feature to > a vector layer other than the first adds a single feature and the second > can add multiple features? > > layer.addFeature(feature) > layer.dataProvider().addFeatures([feature]) > > > Thanks, > > Calvin > > _______________________________________________ > QGIS-Developer mailing list > [email protected] > List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer -- Alexandre Neto --------------------- @AlexNetoGeo http://sigsemgrilhetas.wordpress.com http://gisunchained.wordpress.com
_______________________________________________ QGIS-Developer mailing list [email protected] List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
