Widget Buttons¶
Widget buttons display interactive controls directly inside the menu — no need to open a separate panel.
INT_PROP / FLOAT_PROP¶
Shows an interactive number field.
- Click and drag left/right → change the value
- Click once → type a number directly
| Field | What to enter |
|---|---|
| Property Path | Python path to the numeric property |
| Min / Max | Allowed range |
| Step | How much each drag unit changes the value |
| Suffix | Optional text shown after the number (e.g. °, %, px) |
Example — Brush Strength:
| Field | Value |
|---|---|
| Property Path | context.tool_settings.sculpt.brush.strength |
| Min | 0.0 |
| Max | 1.0 |
| Step | 0.01 |
SLIDER¶
Same as FLOAT_PROP but displayed as a visual progress bar. Best for 0–1 ranges like strength, opacity, or factor.
| Field | What to enter |
|---|---|
| Property Path | Python path to a 0–1 float property |
| Min / Max | Usually 0.0 and 1.0 |
Tip
Use SLIDER when the visual bar helps the user understand where they are in the range. Use FLOAT_PROP for values with arbitrary ranges.
ENUM_PROP¶
Shows an enum property (a list of fixed options).
| Field | What to enter |
|---|---|
| Property Path | Python path to the enum property |
| Expanded | True = show as a row of buttons; False = compact dropdown |
Example — Object Display Type:
| Field | Value |
|---|---|
| Property Path | context.object.display_type |
| Expanded | True |
This shows all display options (Bounds, Wire, Solid, etc.) as clickable buttons in a row.
COLOR_PROP¶
Shows a color swatch. The user drags on it to adjust the color interactively.
| Field | What to enter |
|---|---|
| Property Path | Python path to the color property |
Drag interactions¶
| Action | Effect |
|---|---|
| Drag left / right | Change Hue |
| Drag up / down | Change Value (brightness) |
| Hold Ctrl + drag left/right | Change Saturation |
| Hold Ctrl + drag up/down | Change Alpha |
Example — Object Color:
| Field | Value |
|---|---|
| Property Path | context.object.color |