I am working from QGIS actions with python and want go to select the current feature that I've identified using the identify tool. (Key point is that there is a difference between identify and select). What do I need for my action to make the current feature selected?
I have used vlayer.setSelectedFeatures( [ ] ) but this so far hasn't allowed me to enter the current feature.
I've making use of previous posts to help me including:
Is it possible to take automatically a "screenshot" of my selected feature in QGIS using Python?
How to create a QGIS action which copies features between layers?
There is a little more to what I'm trying to achieve which is why I'm looking at actions. Firstly I don't just want to select the feature I want to Zoom to the feature. (I had sussed zooming to selected features). The beauty of actions is that they are available from an attribute table and what's more in a relation within custom forms. Hence I really wanted to achieve zooming to a feature using an action by right clicking on and attribute table. These other options aren't available here.
An automated select on identify May be a solution, I would be interested learn more but would have to look at it.
The key is it needs to be a simple process for the user.