Bug report #15127
Actions: expose "Set as Atlas feature" in list of layer actions
|Affected QGIS version:||master||Regression?:||No|
|Operating System:||Easy fix?:||No|
|Pull Request or Patch supplied:||No||Resolution:||fixed/implemented|
|Crashes QGIS or corrupts data:||No||Copied to github as #:||23068|
The action "Set as atlas feature" is automatically added if a layer is used as Atlas coverage layer.
However, this action type does not show up in the actions list of the "Layer properties" --> "Actions" tab and thus can't be used where other actions can be used, e.g. as action buttons in the attribute table.
It would be good if the "Set as atlas feature" action can be exposed similar to other actions in the actions tab.
#1 Updated by Matthias Kuhn almost 4 years ago
The current solution with the two different concepts of actions (QgsMapLayerActionRegistry and QgsAttributeAction) causes a lot of additional code throughout the codebase to handle both cases.
I think this could be something to clean up for QGIS 3.0 with one, unified concept of actions. There could be application provided, non-editable actions (e.g. set as atlas feature) similar to the application provided, non-editable variables.
PS: opened issue https://github.com/qgis/qgis3.0_api/issues/52
#3 Updated by Andreas Neumann over 3 years ago
Thank you for this fix. However, my issue still remains unsolved. I may not have expressed myself clearly. What I would need is a way to add the "Set as atlas feature for ..." action to the actions list in the layer properties (e.g. by including it in the "Default actions" or by adding it manually somehow - if I know how. See my first screenshot I am attaching to this update.
The goal is to include a button for "Set as atlas feature for ..." in the new Action column which was introduced in 2.16 in the attribute table. See my second screenshot.
Do you think this could be possible somehow?
Maybe with some Python code and a Python action?
Thank you for having a look at it again!
#6 Updated by Andreas Neumann over 3 years ago
- Resolution set to fixed/implemented
- Status changed from Reopened to Closed
I tested it on Linux and I can see the buttons in the actions column of the attribute table. Due to a lack of Windows build I can just assume that it works on Windows as well. If not, I can still reopen again.
Thanks a lot and sorry about the confusion.