GPv3: Cyclical set operator

Simply sets the cyclical property selected strokes. Note this does not add extra geometry like the legacy operator.

Note: also adds a key bind 'alt c' to toggle, same as for curves.

Resolves #113671

Pull Request: https://projects.blender.org/blender/blender/pulls/111904
This commit is contained in:
casey bianco-davis
2023-10-20 10:12:24 +02:00
committed by Falk David
parent c77bbdcf82
commit 5a79023409
5 changed files with 115 additions and 0 deletions

View File

@@ -4610,6 +4610,9 @@ def km_grease_pencil_edit(params):
{"properties": [("type", "ALL_FRAMES")]}),
# Keyframe Menu
op_menu("VIEW3D_MT_edit_greasepencil_animation", {"type": 'I', "value": 'PRESS'}),
# Cyclical set
("grease_pencil.cyclical_set", {"type": 'F', "value": 'PRESS'}, {"properties": [("type", "CLOSE")]}),
("grease_pencil.cyclical_set", {"type": 'C', "value": 'PRESS', "alt": True}, {"properties": [("type", "TOGGLE")]}),
])
return keymap

View File

@@ -5814,6 +5814,10 @@ class VIEW3D_MT_edit_greasepencil_stroke(Menu):
layout.operator("grease_pencil.stroke_smooth")
layout.operator("grease_pencil.stroke_simplify")
layout.separator()
layout.operator_enum("grease_pencil.cyclical_set", "type")
class VIEW3D_MT_edit_curves(Menu):
bl_label = "Curves"