tiled
tiled copied to clipboard
Allow scripts to extend the tool bars
Currently scripts can register custom actions through tiled.registerAction
and then they can add them to various menus using tiled.extendMenu
. It is however not possible to extend a tool bar.
It should be possible for scripts to extend most of the existing tool bars, probably through a tiled.extendToolBar
function.
Somewhat related: It would be very useful if scripted Tools could have toggles to their tool-specific toolbar, like some of the native tools do. I suspect this would need to be done differently from extendToolbar though.
@eishiya Yes, that's a somewhat different feature. Such actions or toggles are mostly just actions added to the tool bar, so I guess it would be best in this case to add a property to the ScriptedTool
class that is an array of action IDs, which will be added to this tool bar.
Alright, Tool.toolBarActions
done. :-)
Interested in tiled.extendToolBar
as well