Uranium
Application Framework
UM.Extension.Extension Class Reference

Base class for plugins that extend the functionality of Uranium. More...

Inheritance diagram for UM.Extension.Extension:
UM.PluginObject.PluginObject

Public Member Functions

def __init__ (self)
 
def addMenuItem (self, str name, Callable[[], Any] func)
 Add an item to the sub-menu of the extension. More...
 
def setMenuName (self, str name)
 Set name of the menu where all menu items are placed in. More...
 
Optional[str] getMenuName (self)
 Get the name of the menu where all menu items are placed in. More...
 
def activateMenuItem (self, str name)
 Call function associated with option. More...
 
List[str] getMenuItemList (self)
 Get list of all menu item names. More...
 
- Public Member Functions inherited from UM.PluginObject.PluginObject
str getPluginId (self)
 
None setPluginId (self, str plugin_id)
 
None setVersion (self, str version)
 
str getVersion (self)
 

Detailed Description

Base class for plugins that extend the functionality of Uranium.

Every extension adds a (sub) menu to the extension menu with one or more menu items.

Member Function Documentation

◆ activateMenuItem()

def UM.Extension.Extension.activateMenuItem (   self,
str  name 
)

Call function associated with option.

Parameters
namestring

◆ addMenuItem()

def UM.Extension.Extension.addMenuItem (   self,
str  name,
Callable[[], Any]  func 
)

Add an item to the sub-menu of the extension.

Parameters
namestring
functionfunction

◆ getMenuItemList()

List[str] UM.Extension.Extension.getMenuItemList (   self)

Get list of all menu item names.

Returns
list

◆ getMenuName()

Optional[str] UM.Extension.Extension.getMenuName (   self)

Get the name of the menu where all menu items are placed in.

Parameters
menuname string

◆ setMenuName()

def UM.Extension.Extension.setMenuName (   self,
str  name 
)

Set name of the menu where all menu items are placed in.

Parameters
namestring

The documentation for this class was generated from the following file: