Post #4478: Thank you for your fast reply! I can correctly made pie menu for sculpt and it’s

📋 Metadata

  • Author: you16_0823
  • Date: 2022-07-30 22:26:31
  • Type: showcase
  • Quality Score: 8/10
  • Reply to: post_04475

🏷️ Tags

pie-menu intermediate solved

  • Pie Menu Editor
  • Python Scripting
  • Custom Icons

💬 Content

Thank you for your fast reply! I can correctly made pie menu for sculpt and it’s so intuitive and looks great:)

imageimage820×672 90.4 KB

For someone who also want to try this, here’s more examples of command

-Draw

from bl_ui.space_toolsystem_common import ToolSelectPanelHelper; ico=ToolSelectPanelHelper._icon_value_from_icon_handle('brush.sculpt.draw'); L.operator("pme.exec", text=text, icon_value=ico).cmd = "bpy.ops.wm.tool_set_by_id(name='builtin_brush.Draw')"

-Draw Sharp

from bl_ui.space_toolsystem_common import ToolSelectPanelHelper; ico=ToolSelectPanelHelper._icon_value_from_icon_handle('brush.sculpt.draw_sharp'); L.operator("pme.exec", text=text, icon_value=ico).cmd = "bpy.ops.wm.tool_set_by_id(name='builtin_brush.Draw Sharp')"

-Clay Strips

from bl_ui.space_toolsystem_common import ToolSelectPanelHelper; ico=ToolSelectPanelHelper._icon_value_from_icon_handle('brush.sculpt.clay_strips'); L.operator("pme.exec", text=text, icon_value=ico).cmd = "bpy.ops.wm.tool_set_by_id(name='builtin_brush.Clay Strips')"

-Grab

from bl_ui.space_toolsystem_common import ToolSelectPanelHelper; ico=ToolSelectPanelHelper._icon_value_from_icon_handle('brush.sculpt.grab'); L.operator("pme.exec", text=text, icon_value=ico).cmd = "bpy.ops.wm.tool_set_by_id(name='builtin_brush.Grab')"

For avoid interrupting icon with text, I had to add some spaces before text.
image


❤️ 6 likes


🔗 View on Blender Artists