unreal.ToolMenus
¶
- class unreal.ToolMenus(outer=None, name='None')¶
Bases:
unreal.Object
Tool Menus
C++ Source:
Module: ToolMenus
File: ToolMenus.h
Editor Properties: (see get_editor_property/set_editor_property)
customized_menus
(Array(CustomizedToolMenu)): [Read-Write] Customized Menusmenu_substitutions_during_generate
(Map(Name, Name)): [Read-Write] Allow substituting one menu for another during generate but not during find or extend
- classmethod add_menu_entry_object(menu_entry_object) → bool¶
Registers menu entry object from blueprint/script
- Parameters
menu_entry_object (ToolMenuEntryScript) –
- Returns
- Return type
- extend_menu(name) → ToolMenu¶
Extends a menu without registering the menu or claiming ownership of it. Ok to call even if menu does not exist yet.
- classmethod find_context(context, class_) → Object¶
Finds a context object of a given class if it exists
- Parameters
context (ToolMenuContext) –
- Returns
- Return type
- register_menu(name, parent='None', type=MultiBoxType.MENU, warn_if_already_registered=True) → ToolMenu¶
Registers a menu by name
- Parameters
name (Name) –
parent (Name) – Optional name of a menu to layer on top of.
type (MultiBoxType) – Type of menu that will be generated such as: ToolBar, VerticalToolBar, etc..
warn_if_already_registered (bool) – Display warning if already registered
- Returns
ToolMenu Menu object
- Return type