hkb_editor.gui.dialogs.apply_template_dialog
¶
apply_template_dialog
¶
Bases: DpgItem
Render a template's arguments as a form and run it.
One input widget is created per template argument; the widget type comes from the argument's annotation. The dialog stays open after a successful run so the template can be applied again.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
behavior
|
HavokBehavior
|
Behavior to modify. |
required |
template_file
|
str
|
Path to the template module. |
required |
callback
|
callable
|
Called as |
None
|
tag
|
int or str
|
Explicit tag; auto-generated if None. |
None
|
user_data
|
any
|
Passed through to |
None
|
Raises:
| Type | Description |
|---|---|
ValueError
|
If a template argument has a type no widget can handle. |