Blender Git Commit Log
Git Commits -> Revision ad625ac
Revision ad625ac by Julian Eisel (master) November 29, 2017, 02:48 (GMT) |
RNA: Allow structs to define tags for their properties Adds support for defining a number of tags as part of the rna-struct definition, which its properties can set similar to property-flags. BPY supports setting these tags when defining custom properties too. * To define tags for a struct (which its properties can use then), define the tags in an `EnumPropertyItem` array, and assign them to the struct using `RNA_def_struct_property_tags(...)`. * To set tags for an RNA-property in C, use the new `RNA_def_property_tags(...)`. * To set tags for an RNA-property in Python, use the newly added tags parameter. E.g. `bpy.props.FloatProperty(name="Some Float", tags={'SOME_TAG', 'ANOTHER_TAG'})`. |
Commit Details:
Full Hash: ad625acda82281461267a3379c57ce76d54325a1
Parent Commit: 0b325ba
Committed By: Campbell Barton
Lines Changed: +242, -34
8 Modified Paths:
/source/blender/makesrna/intern/makesrna.c (+2, -2) (Diff)
/source/blender/makesrna/intern/rna_access.c (+28, -0) (Diff)
/source/blender/makesrna/intern/rna_define.c (+17, -0) (Diff)
/source/blender/makesrna/intern/rna_internal_types.h (+5, -0) (Diff)
/source/blender/makesrna/intern/rna_rna.c (+56, -0) (Diff)
/source/blender/makesrna/RNA_access.h (+3, -0) (Diff)
/source/blender/makesrna/RNA_define.h (+2, -0) (Diff)
/source/blender/python/intern/bpy_props.c (+129, -32) (Diff)
/source/blender/makesrna/intern/rna_access.c (+28, -0) (Diff)
/source/blender/makesrna/intern/rna_define.c (+17, -0) (Diff)
/source/blender/makesrna/intern/rna_internal_types.h (+5, -0) (Diff)
/source/blender/makesrna/intern/rna_rna.c (+56, -0) (Diff)
/source/blender/makesrna/RNA_access.h (+3, -0) (Diff)
/source/blender/makesrna/RNA_define.h (+2, -0) (Diff)
/source/blender/python/intern/bpy_props.c (+129, -32) (Diff)