Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <campbell@blender.org>2022-04-20 08:10:14 +0300
committerCampbell Barton <campbell@blender.org>2022-04-20 08:10:14 +0300
commitc2cdbe1e88f1397d624538589137c013e087c38a (patch)
tree549b28c72f2c1db46796e626778e7f4a0e1e0691 /doc/python_api/examples/bpy.types.Operator.4.py
parentdf3316cbe98e19def7284c028e53682db0be9a30 (diff)
Cleanup: run autopep8 on doc/
Diffstat (limited to 'doc/python_api/examples/bpy.types.Operator.4.py')
-rw-r--r--doc/python_api/examples/bpy.types.Operator.4.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/doc/python_api/examples/bpy.types.Operator.4.py b/doc/python_api/examples/bpy.types.Operator.4.py
index 00c9cd250b1..d33f6a6113d 100644
--- a/doc/python_api/examples/bpy.types.Operator.4.py
+++ b/doc/python_api/examples/bpy.types.Operator.4.py
@@ -41,11 +41,13 @@ class CustomDrawOperator(bpy.types.Operator):
col.prop(self, "my_string")
-# Only needed if you want to add into a dynamic menu
+
+# Only needed if you want to add into a dynamic menu.
def menu_func(self, context):
self.layout.operator(CustomDrawOperator.bl_idname, text="Custom Draw Operator")
-# Register and add to the object menu (required to also use F3 search "Custom Draw Operator" for quick access)
+
+# Register and add to the object menu (required to also use F3 search "Custom Draw Operator" for quick access).
bpy.utils.register_class(CustomDrawOperator)
bpy.types.VIEW3D_MT_object.append(menu_func)