Post #2623: ![](https://blenderartists.org/user_avatar/blenderartists.org/pinhead/48/528486_

📋 Metadata

  • Author: roaoao
  • Date: 2019-08-17 00:05:42
  • Type: answer
  • Quality Score: 8/10
  • Reply to: post_02622

🏷️ Tags

macro scripting intermediate solved

  • Macro Editor
  • Python Scripting
  • Command Tab

💬 Content

Pinhead:

How in Macro Operator add property

How do you want to use properties in macro? Toggle them?
You can use Command tab for this:

C.object.modifiers["Shrinkwrap"].show_in_editmode = not C.object.modifiers["Shrinkwrap"].show_in_editmode

Pinhead:

Is possible to make menu to toggle “Show Modifiers in edit mode ” global? On all medifier on an object?

Yes, use something like this in Command tab:

o = C.object; value = o and o.modifiers and o.modifiers[0].show_in_editmode; o and [setattr(mod, "show_in_editmode", not value) for mod in o.modifiers]

❤️ 1 likes


🔗 View on Blender Artists