diff options
author | Campbell Barton <campbell@blender.org> | 2022-05-31 07:07:15 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-05-31 07:19:06 +0300 |
commit | c8058e51ee7b355320e20a068ba00f6628567e98 (patch) | |
tree | 0acd58bc1c1e73f1da528e2ad44009fa128ddd47 /source/blender/makesrna/intern/rna_gpencil_modifier.c | |
parent | 1c6b66c9cf80b3c9b4542b27948ae232f930a211 (diff) |
RNA: add macros for EnumPropertyItem layout elements
Add the following macros for enums as support for these features wasn't
all that obvious and there were some inconsistencies in their use.
- RNA_ENUM_ITEM_HEADING(name, description)
- RNA_ENUM_ITEM_SEPR
- RNA_ENUM_ITEM_SEPR_COLUMN
Diffstat (limited to 'source/blender/makesrna/intern/rna_gpencil_modifier.c')
-rw-r--r-- | source/blender/makesrna/intern/rna_gpencil_modifier.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/source/blender/makesrna/intern/rna_gpencil_modifier.c b/source/blender/makesrna/intern/rna_gpencil_modifier.c index 8bbc33d2381..c3d5819caa3 100644 --- a/source/blender/makesrna/intern/rna_gpencil_modifier.c +++ b/source/blender/makesrna/intern/rna_gpencil_modifier.c @@ -46,7 +46,7 @@ #include "WM_types.h" const EnumPropertyItem rna_enum_object_greasepencil_modifier_type_items[] = { - {0, "", 0, N_("Modify"), ""}, + RNA_ENUM_ITEM_HEADING(N_("Modify"), NULL), {eGpencilModifierType_Texture, "GP_TEXTURE", ICON_MOD_UVPROJECT, @@ -63,7 +63,8 @@ const EnumPropertyItem rna_enum_object_greasepencil_modifier_type_items[] = { ICON_MOD_VERTEX_WEIGHT, "Vertex Weight Proximity", "Generate Vertex Weights base on distance to object"}, - {0, "", 0, N_("Generate"), ""}, + + RNA_ENUM_ITEM_HEADING(N_("Generate"), NULL), {eGpencilModifierType_Array, "GP_ARRAY", ICON_MOD_ARRAY, @@ -114,7 +115,7 @@ const EnumPropertyItem rna_enum_object_greasepencil_modifier_type_items[] = { ICON_MOD_SUBSURF, "Subdivide", "Subdivide stroke adding more control points"}, - {0, "", 0, N_("Deform"), ""}, + RNA_ENUM_ITEM_HEADING(N_("Deform"), NULL), {eGpencilModifierType_Armature, "GP_ARMATURE", ICON_MOD_ARMATURE, @@ -147,7 +148,7 @@ const EnumPropertyItem rna_enum_object_greasepencil_modifier_type_items[] = { ICON_MOD_THICKNESS, "Thickness", "Change stroke thickness"}, - {0, "", 0, N_("Color"), ""}, + RNA_ENUM_ITEM_HEADING(N_("Color"), NULL), {eGpencilModifierType_Color, "GP_COLOR", ICON_MOD_HUE_SATURATION, |