Skip to content

Action Buttons

Action buttons run something when clicked — an operator, a property change, or custom Python code.


OPERATOR

Runs a Blender operator. This is the most common button type.

Setup

Field What to enter
Operator The operator ID (e.g. object.shade_smooth)
Properties Optional parameters in key: value format

Common examples

Goal Operator Properties
Switch to Edit Mode object.mode_set mode: EDIT
Switch to Object Mode object.mode_set mode: OBJECT
Switch to Sculpt Mode object.mode_set mode: SCULPT
Shade Smooth object.shade_smooth (none)
Shade Flat object.shade_flat (none)
Add Cube mesh.primitive_cube_add (none)
Apply All Transforms object.transform_apply location: True, rotation: True, scale: True
Merge at Center mesh.merge type: CENTER
Select All mesh.select_all action: SELECT
Deselect All mesh.select_all action: DESELECT
Invert Selection mesh.select_all action: INVERT
Loop Cut mesh.loopcut_slide (none)
Extrude mesh.extrude_region_move (none)

Macros

You can chain multiple operators or property assignments on one line using ;:

bpy.ops.mesh.primitive_cube_add(); bpy.context.space_data.overlay.show_wireframes = True

Enter this as the Operator field value. PieMaster detects the ; and executes each part in sequence.


PROPERTY

Reads and changes a Blender property. When no value is set, toggles boolean properties (on/off) automatically.

Setup

Field What to enter
Property Path Python path to the property (e.g. context.space_data.overlay.show_wireframes)
Value Leave empty to toggle; or enter a specific value to always set it

Common examples

Goal Property Path Value
Toggle Wireframe Overlay context.space_data.overlay.show_wireframes (empty = toggle)
Toggle X-Ray context.space_data.shading.show_xray (empty = toggle)
Set Solid Display Mode context.space_data.shading.type SOLID
Set Material Preview Mode context.space_data.shading.type MATERIAL
Set Rendered Mode context.space_data.shading.type RENDERED
Toggle Overlays context.space_data.overlay.show_overlays (empty = toggle)
Toggle Statistics context.space_data.overlay.show_stats (empty = toggle)

Active Button Highlight

When the property is ON (True), the button automatically highlights with the Active color from your Design. Great for toggle buttons — the user always sees the current state at a glance.


PYTHON

Executes custom Python code. For advanced users who need something no standard operator covers.

Setup

Field What to enter
Python File Path to a .py file to execute
Command Inline Python expression

Examples

# Change render engine
bpy.context.scene.render.engine = 'CYCLES'

# Toggle a custom property
obj = bpy.context.active_object
obj["my_property"] = not obj.get("my_property", False)

# Run a sequence of operations
bpy.ops.object.shade_smooth()
bpy.context.object.data.use_auto_smooth = True

Warning

Python buttons run with bpy available. Keep code simple and test it in Blender's scripting editor first.