pic2map
pic2map copied to clipboard
Digitizing Tool Renamed?
When I ctrl+click (also regular click) on the image in the monoplotter window to digitize a polygon with the "Add Feature Polygon" tool to a layer in a geopackage, I get this error:
2021-11-04T17:35:10 WARNING Traceback (most recent call last):
File "C:\Users/mmtobias/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\Pic2Map\pic2Map.py", line 394, in clickOnMonoplotter
if self.cTool.isEditTool():
AttributeError: 'QgsMapToolDigitizeFeature' object has no attribute 'isEditTool'
I suspect the name of the digitizing tool has changed.
I'm on Windows 10, QGIS version 3.22.0
I thought maybe it isn't able to make polygons yet, so I tried points and lines in a geopackage and both of them gave me a similar error message.
I did some more investigating. On line 394 of pic2map.py, isEditTool
is a property of mapTool in version 2.0 of the API and isn't available in 3.0 so I wonder if this feature ever worked in QGIS 3.0+. When I replace the if statement on line 394 with one to check that the tool name canvas.mapTool().toolName()
is 'Add feature', it then breaks on line 400 where the event is created. This might be an API version issue too, but I haven't checked.