Post #5081: I went to look at the source code and noticed something, so I’ll revise my answe
📋 Metadata
- Author: Pluglug
- Date: 2024-04-01 15:01:39
- Type:
answer - Quality Score: 7/10
- Reply to: post_05080
- Replies (1): post_05082
🏷️ Tags
⚙️ Related PME Features
- Macro Editor
- Python Scripting
💬 Content
I went to look at the source code and noticed something, so I’ll revise my answer.
It seems that specifying Invoke Window Region, like bpy.ops.transform.shrink_fatten('INVOKE_REGION_WIN', .....), should work well.
blender/view3d.py at main
blender - The official Blender project repository.
I tried usingbpy.ops.view3d.edit_mesh_extrude_move_shrink_fatten() and was able to achieve similar behavior (although not perfect). I’m not sure when this operator was implemented in Blender, but it seems that the purpose was likely to standardize Modal operators. This operator cannot take arguments, but it might be useful in this case where it needs to be executed with Invoke. I apologize, but it’s difficult for me to further approximate the behavior because I don’t truly understand the purpose of this feature. Please try bpy.ops.view3d.edit_mesh_extrude_move_shrink_fatten() on your end to see if it’s useful.
(Also, I haven’t tried the bpy.ops.mesh.smart_delete operator because I didn’t have it on my end.)
create_float_panel_edge_macro_edited_by_pluglug_2.json (2.4 KB)
