fusion_addin_framework.Workspace¶
- class fusion_addin_framework.Workspace(parent: Optional[fusion_addin_framework.wrapper.FusionAddin] = None, id: str = 'FusionSolidEnvironment', name: str = 'random', productType: str = 'DesignProductType', resourceFolder: Union[str, pathlib.Path] = 'lightbulb', toolClipFilename: Union[str, pathlib.Path] = 'lightbulb', tooltip: str = '', tooltipDescription: str = '')¶
Wraps around Fusions Workspace object. Besides the documented attributes and methods on this page all attributes and methods of the wrapped class can be accessed with the same attribute and method names as in the wrapped class.
If an Id of an existing workspace is provided, all parameters except parent and id will be ignored.
It is currently not possible to create a custom workspace via the API. This seems like a bug in Fusion360s API. Therfore you need to use a ID of an native workspace. If you have any information on this please answer this forum post.
- Parameters
parent (FusionAddin) – The parental addin instance. Defaults to an addin with the default values.
id (str, optional) – The id of the workspace. Defaults to “FusionSolidEnvironment”.
productType (str, optional) – The name of the product this workspace is associated with. Defaults to “DesignProductType”.
resourceFolder (Union[str, Path], optional) – The resource folder should contain two files; 49X31.png and 98x62.png. The larger is used for the Apple Retina display. Alternatively you can provide the name of one of the available default images. Defaults to “lightbulb”.
toolClipFilename (Union[str, Path], optional) – The full filename of the image file (png) used for the tool clip. The tool clip is the image shown when the user hovers the mouse over the workspace name in the workspace drop-down. Alternatively you can provide the name of one of the available default images. Defaults to “lightbulb”.
tooltip (str, optional) – Tooltip text displayed for the workspace. This is the first line of text shown when the user hovers over the workspace name in the Fusion 360 toolbar drop-down. Defaults to “”.
tooltipDescription (str, optional) – The tooltip description displayed for the workspace. The tooltip description is a longer description of the workspace and is only displayed when the user hovers over the workspace name in the Fusion 360 toolbar drop-down. Defaults to “”.
- tab(*args, **kwargs)¶
Creates a
Tabas a child of this workspace.Calling this method is the same as initialsing a
Tabwith this workspace instance as parent parameters. Therefore the same parameters are passed. SeeTabfor a detailed description of the paramters.- Returns
The newly created or accessed tab instance.
- Return type