MenuDelegate
- class omni.ui.MenuDelegate
Bases:
pybind11_object
MenuDelegate is used to generate widgets that represent the menu item.
Methods
__init__
(self, **kwargs)Constructor.
build_item
(self, item)This method must be reimplemented to generate custom item.
build_status
(self, item)This method must be reimplemented to generate custom widgets on the bottom of the window.
build_title
(self, item)This method must be reimplemented to generate custom title.
call_on_build_item_fn
(self, arg0)Called to create a new item.
call_on_build_status_fn
(self, arg0)Called to create a new widget on the bottom of the window.
call_on_build_title_fn
(self, arg0)Called to create a new title.
has_on_build_item_fn
(self)Called to create a new item.
has_on_build_status_fn
(self)Called to create a new widget on the bottom of the window.
has_on_build_title_fn
(self)Called to create a new title.
set_default_delegate
(delegate)Set the default delegate to use it when the item doesn't have a delegate.
set_on_build_item_fn
(self, fn, None])Called to create a new item.
set_on_build_status_fn
(self, fn, None])Called to create a new widget on the bottom of the window.
set_on_build_title_fn
(self, fn, None])Called to create a new title.
Attributes
propagate
- __init__(self: omni.ui._ui.MenuDelegate, **kwargs) → None
Constructor.
- `kwargsdict`
See below
### Keyword Arguments:
- `on_build_item`
Called to create a new item.
- `on_build_title`
Called to create a new title.
- `on_build_status`
Called to create a new widget on the bottom of the window.
- `propagate`
Determine if Menu children should use this delegate when they don’t have the own one.
- build_item(self: omni.ui._ui.MenuDelegate, item: omni::ui::MenuHelper) → None
This method must be reimplemented to generate custom item.
- build_status(self: omni.ui._ui.MenuDelegate, item: omni::ui::MenuHelper) → None
This method must be reimplemented to generate custom widgets on the bottom of the window.
- build_title(self: omni.ui._ui.MenuDelegate, item: omni::ui::MenuHelper) → None
This method must be reimplemented to generate custom title.
- call_on_build_item_fn(self: omni.ui._ui.MenuDelegate, arg0: omni::ui::MenuHelper) → None
Called to create a new item.
- call_on_build_status_fn(self: omni.ui._ui.MenuDelegate, arg0: omni::ui::MenuHelper) → None
Called to create a new widget on the bottom of the window.
- call_on_build_title_fn(self: omni.ui._ui.MenuDelegate, arg0: omni::ui::MenuHelper) → None
Called to create a new title.
- has_on_build_item_fn(self: omni.ui._ui.MenuDelegate) → bool
Called to create a new item.
- has_on_build_status_fn(self: omni.ui._ui.MenuDelegate) → bool
Called to create a new widget on the bottom of the window.
- has_on_build_title_fn(self: omni.ui._ui.MenuDelegate) → bool
Called to create a new title.
- static set_default_delegate(delegate: MenuDelegate) → None
Set the default delegate to use it when the item doesn’t have a delegate.
- set_on_build_item_fn(self: omni.ui._ui.MenuDelegate, fn: Callable[[omni::ui::MenuHelper], None]) → None
Called to create a new item.
- set_on_build_status_fn(self: omni.ui._ui.MenuDelegate, fn: Callable[[omni::ui::MenuHelper], None]) → None
Called to create a new widget on the bottom of the window.
- set_on_build_title_fn(self: omni.ui._ui.MenuDelegate, fn: Callable[[omni::ui::MenuHelper], None]) → None
Called to create a new title.