|
Blender V5.0
|
#include <algorithm>#include <string>#include <Python.h>#include "RNA_types.hh"#include "BLI_array.hh"#include "BLI_listbase.h"#include "BLI_utildefines.h"#include "bpy_capi_utils.hh"#include "bpy_props.hh"#include "bpy_rna.hh"#include "RNA_access.hh"#include "RNA_define.hh"#include "RNA_enum_types.hh"#include "RNA_prototypes.hh"#include "MEM_guardedalloc.h"#include "DNA_ID.h"#include "../generic/py_capi_rna.hh"#include "../generic/py_capi_utils.hh"#include "../generic/python_compat.hh"#include "../generic/python_utildefines.hh"Go to the source code of this file.
Classes | |
| struct | BPyPropStore |
| struct | BPyPropGIL_RNAWritable_State |
| struct | BPyPropArrayLength |
| struct | BPy_PropIDParse |
| struct | BPy_EnumProperty_Parse_WithSRNA |
Functions | |
Multi-Dimensional Property Utilities | |
| static int | bpy_prop_array_length_parse (PyObject *o, void *p) |
| static int | bpy_prop_array_from_py_with_dims (void *values, size_t values_elem_size, PyObject *py_values, const BPyPropArrayLength *array_len_info, const PyTypeObject *type, const char *error_str) |
| static PyObject * | bpy_py_object_from_prop_array_with_dims (const void *values, const BPyPropArrayLength &array_len_info, const PyTypeObject &type) |
| static bool | bpy_prop_array_is_matrix_compatible_ex (int subtype, const BPyPropArrayLength *array_len_info) |
| static bool | bpy_prop_array_is_matrix_compatible (PropertyRNA *prop, const BPyPropArrayLength *array_len_info) |
| static void | bpy_prop_array_matrix_swap_row_column_vn_vn (float *values_dst, const float *values_src, const BPyPropArrayLength *array_len_info) |
| static void | bpy_prop_array_matrix_swap_row_column_vn (float *values, const BPyPropArrayLength *array_len_info) |
Shared Property Callbacks | |
Unique data is accessed via RNA_property_py_data_get | |
| static void | bpy_prop_update_fn (bContext *C, PointerRNA *ptr, PropertyRNA *prop) |
Boolean Property Callbacks | |
| static bool | bpy_prop_boolean_get_fn (PointerRNA *ptr, PropertyRNA *prop) |
| static bool | bpy_prop_boolean_get_transform_fn (PointerRNA *ptr, PropertyRNA *prop, bool curr_value, bool is_set) |
| static void | bpy_prop_boolean_set_fn (PointerRNA *ptr, PropertyRNA *prop, bool value) |
| static bool | bpy_prop_boolean_set_transform_fn (PointerRNA *ptr, PropertyRNA *prop, bool new_value, bool curr_value, bool is_set) |
| static void | bpy_prop_boolean_array_from_callback_or_error (PyObject *bool_array_obj, const BPyPropArrayLength &array_len_info, PyObject *py_func, bool *r_values) |
| static void | bpy_prop_boolean_array_get_fn (PointerRNA *ptr, PropertyRNA *prop, bool *values) |
| static void | bpy_prop_boolean_array_get_transform_fn (PointerRNA *ptr, PropertyRNA *prop, const bool *curr_values, bool is_set, bool *r_values) |
| static void | bpy_prop_boolean_array_set_fn (PointerRNA *ptr, PropertyRNA *prop, const bool *values) |
| static void | bpy_prop_boolean_array_set_transform_fn (PointerRNA *ptr, PropertyRNA *prop, const bool *new_values, const bool *curr_values, bool is_set, bool *r_final_values) |
Int Property Callbacks | |
| static int | bpy_prop_int_get_fn (PointerRNA *ptr, PropertyRNA *prop) |
| static int | bpy_prop_int_get_transform_fn (PointerRNA *ptr, PropertyRNA *prop, int curr_value, bool is_set) |
| static void | bpy_prop_int_set_fn (PointerRNA *ptr, PropertyRNA *prop, int value) |
| static int | bpy_prop_int_set_transform_fn (PointerRNA *ptr, PropertyRNA *prop, int new_value, int curr_value, bool is_set) |
| static void | bpy_prop_int_array_from_callback_or_error (PyObject *int_array_obj, const BPyPropArrayLength &array_len_info, PyObject *py_func, int *r_values) |
| static void | bpy_prop_int_array_get_fn (PointerRNA *ptr, PropertyRNA *prop, int *values) |
| static void | bpy_prop_int_array_get_transform_fn (PointerRNA *ptr, PropertyRNA *prop, const int *curr_values, bool is_set, int *r_values) |
| static void | bpy_prop_int_array_set_fn (PointerRNA *ptr, PropertyRNA *prop, const int *values) |
| static void | bpy_prop_int_array_set_transform_fn (PointerRNA *ptr, PropertyRNA *prop, const int *new_values, const int *curr_values, bool is_set, int *r_final_values) |
Float Property Callbacks | |
| static float | bpy_prop_float_get_fn (PointerRNA *ptr, PropertyRNA *prop) |
| static float | bpy_prop_float_get_transform_fn (PointerRNA *ptr, PropertyRNA *prop, float curr_value, bool is_set) |
| static void | bpy_prop_float_set_fn (PointerRNA *ptr, PropertyRNA *prop, float value) |
| static float | bpy_prop_float_set_transform_fn (PointerRNA *ptr, PropertyRNA *prop, float new_value, float curr_value, bool is_set) |
| static void | bpy_prop_float_array_from_callback_or_error (PropertyRNA *prop, PyObject *float_array_obj, const BPyPropArrayLength &array_len_info, PyObject *py_func, const bool do_matrix_row_col_swap, float *r_values) |
| static void | bpy_prop_float_array_get_fn (PointerRNA *ptr, PropertyRNA *prop, float *values) |
| static void | bpy_prop_float_array_get_transform_fn (PointerRNA *ptr, PropertyRNA *prop, const float *curr_values, bool is_set, float *r_values) |
| static void | bpy_prop_float_array_set_fn (PointerRNA *ptr, PropertyRNA *prop, const float *values) |
| static void | bpy_prop_float_array_set_transform_fn (PointerRNA *ptr, PropertyRNA *prop, const float *new_values, const float *curr_values, bool is_set, float *r_final_values) |
String Property Callbacks | |
| static std::optional< std::string > | bpy_prop_string_from_callback_or_error (PyObject *str_obj, const size_t max_length, PyObject *py_func) |
| static std::string | bpy_prop_string_get_locked_fn (PointerRNA *ptr, PropertyRNA *prop) |
| static std::string | bpy_prop_string_get_fn (PointerRNA *ptr, PropertyRNA *prop) |
| static std::string | bpy_prop_string_get_transform_locked_fn (PointerRNA *ptr, PropertyRNA *prop, const std::string &curr_value, bool is_set) |
| static std::string | bpy_prop_string_get_transform_fn (PointerRNA *ptr, PropertyRNA *prop, const std::string &curr_value, bool is_set) |
| static int | bpy_prop_string_length_fn (PointerRNA *ptr, PropertyRNA *prop) |
| static void | bpy_prop_string_set_fn (PointerRNA *ptr, PropertyRNA *prop, const std::string &value) |
| static std::string | bpy_prop_string_set_transform_fn (PointerRNA *ptr, PropertyRNA *prop, const std::string &new_value, const std::string &curr_value, bool is_set) |
| static bool | bpy_prop_string_visit_fn_call (PyObject *py_func, PyObject *item, blender::FunctionRef< void(StringPropertySearchVisitParams)> visit_fn) |
| static void | bpy_prop_string_visit_for_search_fn (const bContext *C, PointerRNA *ptr, PropertyRNA *prop, const char *edit_text, blender::FunctionRef< void(StringPropertySearchVisitParams)> visit_fn) |
Pointer Property Callbacks | |
| static bool | bpy_prop_pointer_poll_fn (PointerRNA *self, PointerRNA candidate, PropertyRNA *prop) |
Enum Property Callbacks | |
| static int | bpy_prop_enum_get_fn (PointerRNA *ptr, PropertyRNA *prop) |
| static int | bpy_prop_enum_get_transform_fn (PointerRNA *ptr, PropertyRNA *prop, int curr_value, bool is_set) |
| static void | bpy_prop_enum_set_fn (PointerRNA *ptr, PropertyRNA *prop, int value) |
| static int | bpy_prop_enum_set_transform_fn (PointerRNA *ptr, PropertyRNA *prop, int new_value, int curr_value, bool is_set) |
| static bool | py_long_as_int (PyObject *py_long, int *r_int) |
| static int | icon_id_from_name (const char *name) |
| static const EnumPropertyItem * | enum_items_from_py (PyObject *seq_fast, const bool is_enum_flag, PyObject *default_py, int *r_default_value) |
| static const EnumPropertyItem * | bpy_prop_enum_itemf_fn (bContext *C, PointerRNA *ptr, PropertyRNA *prop, bool *r_free) |
| static int | bpy_prop_callback_check (PyObject *py_func, const char *keyword, int argcount) |
Shared Callback Assignment | |
| static void | bpy_prop_callback_assign_update (PropertyRNA *prop, PyObject *update_fn) |
| static void | bpy_prop_callback_assign_pointer (PropertyRNA *prop, PyObject *poll_fn) |
| static bool | bpy_prop_callback_assign_boolean (PropertyRNA *prop, PyObject *get_fn, PyObject *set_fn, PyObject *get_transform_fn, PyObject *set_transform_fn) |
| static bool | bpy_prop_callback_assign_boolean_array (PropertyRNA *prop, PyObject *get_fn, PyObject *set_fn, PyObject *get_transform_fn, PyObject *set_transform_fn) |
| static bool | bpy_prop_callback_assign_int (PropertyRNA *prop, PyObject *get_fn, PyObject *set_fn, PyObject *get_transform_fn, PyObject *set_transform_fn) |
| static void | bpy_prop_callback_assign_int_array (PropertyRNA *prop, PyObject *get_fn, PyObject *set_fn, PyObject *get_transform_fn, PyObject *set_transform_fn) |
| static bool | bpy_prop_callback_assign_float (PropertyRNA *prop, PyObject *get_fn, PyObject *set_fn, PyObject *get_transform_fn, PyObject *set_transform_fn) |
| static void | bpy_prop_callback_assign_float_array (PropertyRNA *prop, PyObject *get_fn, PyObject *set_fn, PyObject *get_transform_fn, PyObject *set_transform_fn) |
| static bool | bpy_prop_callback_assign_string (PropertyRNA *prop, PyObject *get_fn, PyObject *set_fn, PyObject *get_transform_fn, PyObject *set_transform_fn, PyObject *search_fn, const eStringPropertySearchFlag search_flag) |
| static bool | bpy_prop_callback_assign_enum (PropertyRNA *prop, PyObject *get_fn, PyObject *set_fn, PyObject *itemf_fn, PyObject *get_transform_fn, PyObject *set_transform_fn) |
Shared Method Utilities | |
| static StructRNA * | bpy_prop_deferred_data_or_srna (PyObject *self, PyObject *args, PyObject *kw, PyObject *method_object, PyObject **r_deferred_result) |
| static int | bpy_prop_arg_parse_id (PyObject *o, void *p) |
| static int | bpy_prop_arg_parse_tag_defines (PyObject *o, void *p) |
Module Methods | |
Functions that register RNA.
| |
| PyDoc_STRVAR (BPy_BoolProperty_doc, ".. function:: BoolProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=False, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new boolean property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_NUMBER_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("bool") BPY_PROPDEF_SET_DOC("bool") BPY_PROPDEF_GET_TRANSFORM_DOC("bool") BPY_PROPDEF_SET_TRANSFORM_DOC("bool")) | |
| static PyObject * | BPy_BoolProperty (PyObject *self, PyObject *args, PyObject *kw) |
| PyDoc_STRVAR (BPy_BoolVectorProperty_doc, ".. function:: BoolVectorProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=(False, False, False), " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "size=3, " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new vector boolean property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC " :arg default: sequence of booleans the length of *size*.\n" " :type default: Sequence[bool]\n" BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_NUMBER_ARRAY_DOC BPY_PROPDEF_VECSIZE_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("Sequence[bool]") BPY_PROPDEF_SET_TRANSFORM_DOC("Sequence[bool]")) | |
| static PyObject * | BPy_BoolVectorProperty (PyObject *self, PyObject *args, PyObject *kw) |
| PyDoc_STRVAR (BPy_IntProperty_doc, ".. function:: IntProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=0, " "min=-2**31, max=2**31-1, " "soft_min=-2**31, soft_max=2**31-1, " "step=1, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new int property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC BPY_PROPDEF_NUM_MINMAX_DOC("int") BPY_PROPDEF_NUM_SOFT_MINMAX_DOC("int") BPY_PROPDEF_INT_STEP_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_NUMBER_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("int") BPY_PROPDEF_SET_DOC("int") BPY_PROPDEF_GET_TRANSFORM_DOC("int") BPY_PROPDEF_SET_TRANSFORM_DOC("int")) | |
| static PyObject * | BPy_IntProperty (PyObject *self, PyObject *args, PyObject *kw) |
| PyDoc_STRVAR (BPy_IntVectorProperty_doc, ".. function:: IntVectorProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=(0, 0, 0), min=-2**31, max=2**31-1, " "soft_min=-2**31, " "soft_max=2**31-1, " "step=1, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "size=3, " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new vector int property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC " :arg default: sequence of ints the length of *size*.\n" " :type default: Sequence[int]\n" BPY_PROPDEF_NUM_MINMAX_DOC("int") BPY_PROPDEF_INT_STEP_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_NUMBER_ARRAY_DOC BPY_PROPDEF_VECSIZE_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("Sequence[int]") BPY_PROPDEF_SET_TRANSFORM_DOC("Sequence[int]")) | |
| static PyObject * | BPy_IntVectorProperty (PyObject *self, PyObject *args, PyObject *kw) |
| PyDoc_STRVAR (BPy_FloatProperty_doc, ".. function:: FloatProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=0.0, " "min=-3.402823e+38, max=3.402823e+38, " "soft_min=-3.402823e+38, soft_max=3.402823e+38, " "step=3, " "precision=2, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "unit='NONE', " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new float (single precision) property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC BPY_PROPDEF_NUM_MINMAX_DOC("float") BPY_PROPDEF_NUM_SOFT_MINMAX_DOC("float") BPY_PROPDEF_FLOAT_STEP_DOC BPY_PROPDEF_FLOAT_PREC_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_NUMBER_DOC BPY_PROPDEF_UNIT_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("float") BPY_PROPDEF_SET_DOC("float") BPY_PROPDEF_GET_TRANSFORM_DOC("float") BPY_PROPDEF_SET_TRANSFORM_DOC("float")) | |
| static PyObject * | BPy_FloatProperty (PyObject *self, PyObject *args, PyObject *kw) |
| PyDoc_STRVAR (BPy_FloatVectorProperty_doc, ".. function:: FloatVectorProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=(0.0, 0.0, 0.0), " "min=sys.float_info.min, max=sys.float_info.max, " "soft_min=sys.float_info.min, soft_max=sys.float_info.max, " "step=3, " "precision=2, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "unit='NONE', " "size=3, " "update=None, " "get=None, " "set=None)\n" "\n" " Returns a new vector float property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC " :arg default: Sequence of floats the length of *size*.\n" " :type default: Sequence[float]\n" BPY_PROPDEF_NUM_MINMAX_DOC("float") BPY_PROPDEF_NUM_SOFT_MINMAX_DOC("float") BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_FLOAT_STEP_DOC BPY_PROPDEF_FLOAT_PREC_DOC BPY_PROPDEF_SUBTYPE_NUMBER_ARRAY_DOC BPY_PROPDEF_UNIT_DOC BPY_PROPDEF_VECSIZE_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("Sequence[float]") BPY_PROPDEF_SET_TRANSFORM_DOC("Sequence[float]")) | |
| static PyObject * | BPy_FloatVectorProperty (PyObject *self, PyObject *args, PyObject *kw) |
| PyDoc_STRVAR (BPy_StringProperty_doc, ".. function:: StringProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=\"\", " "maxlen=0, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None, " "search=None, " "search_options={'SUGGESTION'})\n" "\n" " Returns a new string property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC " :arg default: initializer string.\n" " :type default: str\n" " :arg maxlen: maximum length of the string.\n" " :type maxlen: int\n" BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_STRING_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("str") BPY_PROPDEF_SET_DOC("str") BPY_PROPDEF_GET_TRANSFORM_DOC("str") BPY_PROPDEF_SET_TRANSFORM_DOC("str") BPY_PROPDEF_SEARCH_DOC) | |
| static PyObject * | BPy_StringProperty (PyObject *self, PyObject *args, PyObject *kw) |
| PyDoc_STRVAR (BPy_EnumProperty_doc, ".. function:: EnumProperty(" "items, " "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=None, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new enumerator property definition.\n" "\n" " :arg items: sequence of enum items formatted:\n" " ``[(identifier, name, description, icon, number), ...]``.\n" "\n" " The first three elements of the tuples are mandatory.\n" "\n" " :identifier: The identifier is used for Python access.\n" " An empty identifier means that the item is a separator\n" " :name: Name for the interface.\n" " :description: Used for documentation and tooltips.\n" " :icon: An icon string identifier or integer icon value\n" " (e.g. returned by :class:`bpy.types.UILayout.icon`)\n" " :number: Unique value used as the identifier for this item (stored in file data).\n" " Use when the identifier may need to change. If the *ENUM_FLAG* option is used,\n" " the values are bit-masks and should be powers of two.\n" "\n" " When an item only contains 4 items they define ``(identifier, name, description, " "number)``.\n" "\n" " Separators may be added using either None (nameless separator),\n" " or a regular item tuple with an empty identifier string, in which case the name,\n" " if non-empty, will be displayed in the UI above the separator line." "\n" " For dynamic values a callback can be passed which returns a list in\n" " the same format as the static list.\n" " This function must take 2 arguments ``(self, context)``, **context may be None**.\n" "\n" " .. warning::\n" "\n" " There is a known bug with using a callback,\n" " Python must keep a reference to the strings returned by the callback or Blender\n" " will misbehave or even crash." "\n" " :type items: Iterable[" "tuple[str, str, str] | " "tuple[str, str, str, int] | " "tuple[str, str, str, int, int] | " "None] | " "Callable[[:class:`bpy.types.bpy_struct`, :class:`bpy.types.Context` | None], " "Iterable[" "tuple[str, str, str] | " "tuple[str, str, str, int] | " "tuple[str, str, str, int, int] | " "None]" "]\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC " :arg default: The default value for this enum, a string from the identifiers used in " "*items*, or integer matching an item number.\n" " If the *ENUM_FLAG* option is used this must be a set of such string identifiers " "instead.\n" " WARNING: Strings cannot be specified for dynamic enums\n" " (i.e. if a callback function is given as *items* parameter).\n" " :type default: str | int | set[str]\n" BPY_PROPDEF_OPTIONS_ENUM_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("int") BPY_PROPDEF_SET_DOC("int") BPY_PROPDEF_GET_TRANSFORM_DOC("int") BPY_PROPDEF_SET_TRANSFORM_DOC("int")) | |
| static PyObject * | BPy_EnumProperty (PyObject *self, PyObject *args, PyObject *kw) |
| StructRNA * | pointer_type_from_py (PyObject *value, const char *error_prefix) |
| PyDoc_STRVAR (BPy_PointerProperty_doc, ".. function:: PointerProperty(" "type, " "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "poll=None, " "update=None)\n" "\n" " Returns a new pointer property definition.\n" "\n" BPY_PROPDEF_POINTER_TYPE_DOC BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_POLL_DOC BPY_PROPDEF_UPDATE_DOC "\n" ".. note:: Pointer properties do not support storing references to embedded IDs " "(e.g. :class:`bpy.types.Scene.collection`, :class:`bpy.types.Material.node_tree`).\n" " These should exclusively be referenced and accessed through their owner ID " "(e.g. the scene or material).\n") | |
| PyObject * | BPy_PointerProperty (PyObject *self, PyObject *args, PyObject *kw) |
| PyDoc_STRVAR (BPy_CollectionProperty_doc, ".. function:: CollectionProperty(" "type, " "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "options={'ANIMATABLE'}, " "override=set(), " "tags=set())\n" "\n" " Returns a new collection property definition.\n" "\n" BPY_PROPDEF_COLLECTION_TYPE_DOC BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_COLLECTION_DOC BPY_PROPDEF_TAGS_DOC) | |
| PyObject * | BPy_CollectionProperty (PyObject *self, PyObject *args, PyObject *kw) |
| PyDoc_STRVAR (BPy_RemoveProperty_doc, ".. function:: RemoveProperty(cls, attr)\n" "\n" " Removes a dynamically defined property.\n" "\n" " :arg cls: The class containing the property (must be a positional argument).\n" " :type cls: type\n" " :arg attr: Property name (must be passed as a keyword).\n" " :type attr: str\n" "\n" ".. note:: Typically this function doesn't need to be accessed directly.\n" " Instead use ``del cls.attr``\n") | |
| static PyObject * | BPy_RemoveProperty (PyObject *self, PyObject *args, PyObject *kw) |
Python Property Storage API | |
Functionality needed to use Python native callbacks from generic C RNA callbacks. | |
| #define | BPY_PROP_STORE_PY_DATA_SIZE (sizeof(BPyPropStore::py_data) / sizeof(PyObject *)) |
| #define | ASSIGN_PYOBJECT_INCREF(a, b) |
| static ListBase | g_bpy_prop_store_list = {nullptr, nullptr} |
| static BPyPropStore * | bpy_prop_py_data_ensure (PropertyRNA *prop) |
| static void | bpy_prop_py_data_remove (PropertyRNA *prop) |
Deferred Property Type | |
Operators and classes use this so it can store the arguments given but defer running it until the operator runs where these values are used to setup the default arguments for that operator instance. | |
| static PyGetSetDef | bpy_prop_deferred_getset [] |
| PyTypeObject | bpy_prop_deferred_Type |
| static void | bpy_prop_deferred_dealloc (BPy_PropDeferred *self) |
| static int | bpy_prop_deferred_traverse (BPy_PropDeferred *self, visitproc visit, void *arg) |
| static int | bpy_prop_deferred_clear (BPy_PropDeferred *self) |
| static PyObject * | bpy_prop_deferred_repr (BPy_PropDeferred *self) |
| static PyObject * | bpy_prop_deferred_call (BPy_PropDeferred *, PyObject *, PyObject *) |
| static PyObject * | bpy_prop_deferred_function_get (BPy_PropDeferred *self, void *) |
| static PyObject * | bpy_prop_deferred_keywords_get (BPy_PropDeferred *self, void *) |
| PyDoc_STRVAR (bpy_prop_deferred_doc, "Intermediate storage for properties before registration.\n" "\n" ".. note::\n" "\n" " This is not part of the stable API and may change between releases.\n") | |
| static PyObject * | bpy_prop_deferred_data_CreatePyObject (PyObject *fn, PyObject *kw) |
Shared Property Utilities | |
| static PyObject * | pymeth_BoolProperty = nullptr |
| static PyObject * | pymeth_BoolVectorProperty = nullptr |
| static PyObject * | pymeth_IntProperty = nullptr |
| static PyObject * | pymeth_IntVectorProperty = nullptr |
| static PyObject * | pymeth_FloatProperty = nullptr |
| static PyObject * | pymeth_FloatVectorProperty = nullptr |
| static PyObject * | pymeth_StringProperty = nullptr |
| static PyObject * | pymeth_EnumProperty = nullptr |
| static PyObject * | pymeth_PointerProperty = nullptr |
| static PyObject * | pymeth_CollectionProperty = nullptr |
| static PyObject * | pymeth_RemoveProperty = nullptr |
| static PyObject * | pyrna_struct_as_instance (PointerRNA *ptr) |
| static void | bpy_prop_assign_flag (PropertyRNA *prop, int flag) |
| static void | bpy_prop_assign_flag_override (PropertyRNA *prop, const int flag_override) |
| static BPyPropGIL_RNAWritable_State | bpy_prop_gil_rna_writable_begin () |
| static void | bpy_prop_gil_rna_writable_end (const BPyPropGIL_RNAWritable_State &prop_state) |
Main Module <tt>bpy.props</tt> | |
| static PyMethodDef | props_methods [] |
| static PyModuleDef | props_module |
| static int | props_visit (PyObject *, visitproc visit, void *arg) |
| static int | props_clear (PyObject *) |
| PyDoc_STRVAR (props_module_doc, "This module defines properties to extend Blender's internal data. The result of these " "functions" " is used to assign properties to classes registered with Blender and can't be used " "directly.\n" "\n" ".. note:: All parameters to these functions must be passed as keywords.\n") | |
| PyObject * | BPY_rna_props () |
| void | BPY_rna_props_clear_all () |
This file defines 'bpy.props' module used so scripts can define their own rna properties for use with python operators or adding new properties to existing blender types.
Definition in file bpy_props.cc.
| #define ASSIGN_PYOBJECT_INCREF | ( | a, | |
| b ) |
Definition at line 181 of file bpy_props.cc.
Referenced by bpy_prop_callback_assign_boolean(), bpy_prop_callback_assign_boolean_array(), bpy_prop_callback_assign_enum(), bpy_prop_callback_assign_float(), bpy_prop_callback_assign_float_array(), bpy_prop_callback_assign_int(), bpy_prop_callback_assign_int_array(), bpy_prop_callback_assign_pointer(), bpy_prop_callback_assign_string(), and bpy_prop_callback_assign_update().
| #define ASSIGN_STATIC | ( | _name | ) |
Referenced by BPY_rna_props().
| #define BPY_PROP_STORE_PY_DATA_SIZE (sizeof(BPyPropStore::py_data) / sizeof(PyObject *)) |
Definition at line 179 of file bpy_props.cc.
Referenced by bpy_prop_py_data_remove(), props_clear(), and props_visit().
| #define BPY_PROPDEF_COLLECTION_TYPE_DOC |
Definition at line 3492 of file bpy_props.cc.
Referenced by PyDoc_STRVAR().
| #define BPY_PROPDEF_CTXT_DOC |
Definition at line 3351 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_DESC_DOC |
Definition at line 3347 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_FLOAT_PREC_DOC |
Definition at line 3399 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_FLOAT_STEP_DOC |
Definition at line 3394 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_GET_DOC | ( | ty | ) |
Definition at line 3422 of file bpy_props.cc.
| #define BPY_PROPDEF_GET_TRANSFORM_DOC | ( | ty | ) |
Definition at line 3441 of file bpy_props.cc.
| #define BPY_PROPDEF_INT_STEP_DOC |
Definition at line 3389 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_NAME_DOC |
Definition at line 3343 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_NUM_MAX_DOC_ | ( | ty | ) |
Definition at line 3364 of file bpy_props.cc.
| #define BPY_PROPDEF_NUM_MIN_DOC_ | ( | ty | ) |
Definition at line 3359 of file bpy_props.cc.
| #define BPY_PROPDEF_NUM_MINMAX_DOC | ( | ty | ) |
Definition at line 3369 of file bpy_props.cc.
| #define BPY_PROPDEF_NUM_SOFT_MAX_DOC_ | ( | ty | ) |
Definition at line 3376 of file bpy_props.cc.
| #define BPY_PROPDEF_NUM_SOFT_MIN_DOC_ | ( | ty | ) |
Definition at line 3371 of file bpy_props.cc.
| #define BPY_PROPDEF_NUM_SOFT_MINMAX_DOC | ( | ty | ) |
Definition at line 3381 of file bpy_props.cc.
| #define BPY_PROPDEF_OPTIONS_DOC |
Definition at line 56 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_OPTIONS_ENUM_DOC |
Definition at line 60 of file bpy_props.cc.
Referenced by PyDoc_STRVAR().
| #define BPY_PROPDEF_OPTIONS_OVERRIDE_COLLECTION_DOC |
Definition at line 68 of file bpy_props.cc.
Referenced by PyDoc_STRVAR().
| #define BPY_PROPDEF_OPTIONS_OVERRIDE_DOC |
Definition at line 64 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_POINTER_TYPE_DOC |
Definition at line 3488 of file bpy_props.cc.
Referenced by PyDoc_STRVAR().
| #define BPY_PROPDEF_POLL_DOC |
Definition at line 3412 of file bpy_props.cc.
Referenced by PyDoc_STRVAR().
| #define BPY_PROPDEF_SEARCH_DOC |
Definition at line 3468 of file bpy_props.cc.
Referenced by PyDoc_STRVAR().
| #define BPY_PROPDEF_SET_DOC | ( | ty | ) |
Definition at line 3432 of file bpy_props.cc.
| #define BPY_PROPDEF_SET_TRANSFORM_DOC | ( | ty | ) |
Definition at line 3453 of file bpy_props.cc.
| #define BPY_PROPDEF_SUBTYPE_NUMBER_ARRAY_DOC |
Definition at line 80 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_SUBTYPE_NUMBER_DOC |
Definition at line 76 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_SUBTYPE_STRING_DOC |
Definition at line 72 of file bpy_props.cc.
Referenced by PyDoc_STRVAR().
| #define BPY_PROPDEF_TAGS_DOC |
Definition at line 3496 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_UNIT_DOC |
Definition at line 3355 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_UPDATE_DOC |
Definition at line 3405 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define BPY_PROPDEF_VECSIZE_DOC |
Definition at line 3384 of file bpy_props.cc.
Referenced by PyDoc_STRVAR(), PyDoc_STRVAR(), and PyDoc_STRVAR().
| #define PY_SSIZE_T_CLEAN |
Definition at line 14 of file bpy_props.cc.
|
static |
Definition at line 3545 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, bpy_prop_arg_parse_id(), bpy_prop_arg_parse_tag_defines(), bpy_prop_assign_flag(), bpy_prop_assign_flag_override(), bpy_prop_callback_assign_boolean(), bpy_prop_callback_assign_update(), bpy_prop_callback_check(), bpy_prop_deferred_data_or_srna(), BPy_EnumProperty_Parse::is_set, BPy_EnumProperty_Parse::items, name, PROP_BOOLEAN, BPy_PropIDParse::prop_free_handle, PROP_NONE, PY_ARG_PARSER_HEAD_COMPAT, PyC_ParseBool(), pymeth_BoolProperty, pyrna_enum_bitfield_parse_set(), pyrna_enum_value_parse_string(), RNA_def_property(), RNA_def_property_boolean_default(), RNA_def_property_duplicate_pointers(), RNA_def_property_free_identifier_deferred_finish(), RNA_def_property_tags(), RNA_def_property_translation_context(), RNA_def_property_ui_text(), rna_enum_property_flag_items, rna_enum_property_override_flag_items, rna_enum_property_subtype_number_items, self, BPy_EnumProperty_Parse_WithSRNA::srna, BPy_PropIDParse::srna, BPy_EnumProperty_Parse::value, and BPy_PropIDParse::value.
|
static |
Definition at line 3725 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, bpy_prop_arg_parse_id(), bpy_prop_arg_parse_tag_defines(), bpy_prop_array_from_py_with_dims(), bpy_prop_array_length_parse(), bpy_prop_assign_flag(), bpy_prop_assign_flag_override(), bpy_prop_callback_assign_boolean_array(), bpy_prop_callback_assign_update(), bpy_prop_callback_check(), bpy_prop_deferred_data_or_srna(), blender::Array< T, InlineBufferCapacity, Allocator >::data(), BPyPropArrayLength::dims, BPyPropArrayLength::dims_len, BPy_EnumProperty_Parse::is_set, BPy_EnumProperty_Parse::items, BPyPropArrayLength::len_total, name, PROP_BOOLEAN, BPy_PropIDParse::prop_free_handle, PROP_NONE, PY_ARG_PARSER_HEAD_COMPAT, pymeth_BoolVectorProperty, pyrna_enum_bitfield_parse_set(), pyrna_enum_value_parse_string(), blender::Array< T, InlineBufferCapacity, Allocator >::reinitialize(), RNA_def_property(), RNA_def_property_array(), RNA_def_property_boolean_array_default(), RNA_def_property_duplicate_pointers(), RNA_def_property_free_identifier_deferred_finish(), RNA_def_property_multi_array(), RNA_def_property_tags(), RNA_def_property_translation_context(), RNA_def_property_ui_text(), rna_enum_property_flag_items, rna_enum_property_override_flag_items, rna_enum_property_subtype_number_array_items, self, BPy_EnumProperty_Parse_WithSRNA::srna, BPy_PropIDParse::srna, BPy_EnumProperty_Parse::value, and BPy_PropIDParse::value.
|
nodiscard |
Definition at line 5425 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, bpy_prop_arg_parse_id(), bpy_prop_arg_parse_tag_defines(), bpy_prop_assign_flag(), bpy_prop_assign_flag_override(), bpy_prop_deferred_data_or_srna(), BPy_EnumProperty_Parse::is_set, BPy_EnumProperty_Parse::items, name, pointer_type_from_py(), BPy_PropIDParse::prop_free_handle, PY_ARG_PARSER_HEAD_COMPAT, pymeth_CollectionProperty, pyrna_enum_bitfield_parse_set(), RNA_def_collection_runtime(), RNA_def_property_duplicate_pointers(), RNA_def_property_free_identifier_deferred_finish(), RNA_def_property_tags(), RNA_def_property_translation_context(), RNA_def_struct_flag(), rna_enum_property_flag_items, rna_enum_property_override_flag_collection_items, RNA_PropertyGroup, RNA_struct_idprops_contains_datablock(), RNA_struct_is_a(), RNA_struct_ui_name(), self, BPy_EnumProperty_Parse_WithSRNA::srna, BPy_PropIDParse::srna, STRUCT_CONTAINS_DATABLOCK_IDPROPERTIES, BPy_EnumProperty_Parse::value, and BPy_PropIDParse::value.
Referenced by deferred_register_prop().
|
static |
Definition at line 5015 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, bpy_prop_arg_parse_id(), bpy_prop_arg_parse_tag_defines(), bpy_prop_assign_flag(), bpy_prop_assign_flag_override(), bpy_prop_callback_assign_enum(), bpy_prop_callback_assign_update(), bpy_prop_callback_check(), bpy_prop_deferred_data_or_srna(), enum_items_from_py(), BPy_EnumProperty_Parse::is_set, BPy_EnumProperty_Parse::items, MEM_freeN(), name, PROP_ENUM_FLAG, BPy_PropIDParse::prop_free_handle, PY_ARG_PARSER_HEAD_COMPAT, Py_DECREF(), py_long_as_int(), pymeth_EnumProperty, pyrna_enum_bitfield_parse_set(), RNA_def_enum(), RNA_def_enum_flag(), RNA_def_property_duplicate_pointers(), RNA_def_property_free_identifier_deferred_finish(), RNA_def_property_tags(), RNA_def_property_translation_context(), rna_enum_dummy_NULL_items, rna_enum_property_flag_enum_items, rna_enum_property_override_flag_items, self, BPy_EnumProperty_Parse_WithSRNA::srna, BPy_PropIDParse::srna, BPy_EnumProperty_Parse::value, and BPy_PropIDParse::value.
|
static |
Definition at line 4335 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, bpy_prop_arg_parse_id(), bpy_prop_arg_parse_tag_defines(), bpy_prop_assign_flag(), bpy_prop_assign_flag_override(), bpy_prop_callback_assign_float(), bpy_prop_callback_assign_update(), bpy_prop_callback_check(), bpy_prop_deferred_data_or_srna(), FLT_MAX, BPy_EnumProperty_Parse::is_set, BPy_EnumProperty_Parse::items, max, min, name, PROP_FLOAT, BPy_PropIDParse::prop_free_handle, PROP_NONE, PROP_UNIT_NONE, PY_ARG_PARSER_HEAD_COMPAT, pymeth_FloatProperty, pyrna_enum_bitfield_parse_set(), pyrna_enum_value_parse_string(), RNA_def_property(), RNA_def_property_duplicate_pointers(), RNA_def_property_float_default(), RNA_def_property_free_identifier_deferred_finish(), RNA_def_property_range(), RNA_def_property_tags(), RNA_def_property_translation_context(), RNA_def_property_ui_range(), RNA_def_property_ui_text(), rna_enum_property_flag_items, rna_enum_property_override_flag_items, rna_enum_property_subtype_number_items, rna_enum_property_unit_items, self, BPy_EnumProperty_Parse_WithSRNA::srna, BPy_PropIDParse::srna, step, BPy_EnumProperty_Parse::value, and BPy_PropIDParse::value.
|
static |
Definition at line 4533 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, bpy_prop_arg_parse_id(), bpy_prop_arg_parse_tag_defines(), bpy_prop_array_from_py_with_dims(), bpy_prop_array_is_matrix_compatible_ex(), bpy_prop_array_length_parse(), bpy_prop_array_matrix_swap_row_column_vn(), bpy_prop_assign_flag(), bpy_prop_assign_flag_override(), bpy_prop_callback_assign_float_array(), bpy_prop_callback_assign_update(), bpy_prop_callback_check(), bpy_prop_deferred_data_or_srna(), blender::Array< T, InlineBufferCapacity, Allocator >::data(), BPyPropArrayLength::dims, BPyPropArrayLength::dims_len, FLT_MAX, BPy_EnumProperty_Parse::is_set, BPy_EnumProperty_Parse::items, BPyPropArrayLength::len_total, max, min, name, PROP_FLOAT, BPy_PropIDParse::prop_free_handle, PROP_NONE, PROP_UNIT_NONE, PY_ARG_PARSER_HEAD_COMPAT, pymeth_FloatVectorProperty, pyrna_enum_bitfield_parse_set(), pyrna_enum_value_parse_string(), blender::Array< T, InlineBufferCapacity, Allocator >::reinitialize(), RNA_def_property(), RNA_def_property_array(), RNA_def_property_duplicate_pointers(), RNA_def_property_float_array_default(), RNA_def_property_free_identifier_deferred_finish(), RNA_def_property_multi_array(), RNA_def_property_range(), RNA_def_property_tags(), RNA_def_property_translation_context(), RNA_def_property_ui_range(), RNA_def_property_ui_text(), rna_enum_property_flag_items, rna_enum_property_override_flag_items, rna_enum_property_subtype_number_array_items, rna_enum_property_unit_items, self, BPy_EnumProperty_Parse_WithSRNA::srna, BPy_PropIDParse::srna, step, BPy_EnumProperty_Parse::value, and BPy_PropIDParse::value.
|
static |
Definition at line 3934 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, bpy_prop_arg_parse_id(), bpy_prop_arg_parse_tag_defines(), bpy_prop_assign_flag(), bpy_prop_assign_flag_override(), bpy_prop_callback_assign_int(), bpy_prop_callback_assign_update(), bpy_prop_callback_check(), bpy_prop_deferred_data_or_srna(), BPy_EnumProperty_Parse::is_set, BPy_EnumProperty_Parse::items, max, min, name, BPy_PropIDParse::prop_free_handle, PROP_INT, PROP_NONE, PY_ARG_PARSER_HEAD_COMPAT, pymeth_IntProperty, pyrna_enum_bitfield_parse_set(), pyrna_enum_value_parse_string(), RNA_def_property(), RNA_def_property_duplicate_pointers(), RNA_def_property_free_identifier_deferred_finish(), RNA_def_property_int_default(), RNA_def_property_range(), RNA_def_property_tags(), RNA_def_property_translation_context(), RNA_def_property_ui_range(), RNA_def_property_ui_text(), rna_enum_property_flag_items, rna_enum_property_override_flag_items, rna_enum_property_subtype_number_items, self, BPy_EnumProperty_Parse_WithSRNA::srna, BPy_PropIDParse::srna, step, BPy_EnumProperty_Parse::value, and BPy_PropIDParse::value.
|
static |
Definition at line 4119 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, bpy_prop_arg_parse_id(), bpy_prop_arg_parse_tag_defines(), bpy_prop_array_from_py_with_dims(), bpy_prop_array_length_parse(), bpy_prop_assign_flag(), bpy_prop_assign_flag_override(), bpy_prop_callback_assign_int_array(), bpy_prop_callback_assign_update(), bpy_prop_callback_check(), bpy_prop_deferred_data_or_srna(), blender::Array< T, InlineBufferCapacity, Allocator >::data(), BPyPropArrayLength::dims, BPyPropArrayLength::dims_len, BPy_EnumProperty_Parse::is_set, BPy_EnumProperty_Parse::items, BPyPropArrayLength::len_total, max, min, name, BPy_PropIDParse::prop_free_handle, PROP_INT, PROP_NONE, PY_ARG_PARSER_HEAD_COMPAT, pymeth_IntVectorProperty, pyrna_enum_bitfield_parse_set(), pyrna_enum_value_parse_string(), blender::Array< T, InlineBufferCapacity, Allocator >::reinitialize(), RNA_def_property(), RNA_def_property_array(), RNA_def_property_duplicate_pointers(), RNA_def_property_free_identifier_deferred_finish(), RNA_def_property_int_array_default(), RNA_def_property_multi_array(), RNA_def_property_range(), RNA_def_property_tags(), RNA_def_property_translation_context(), RNA_def_property_ui_range(), RNA_def_property_ui_text(), rna_enum_property_flag_items, rna_enum_property_override_flag_items, rna_enum_property_subtype_number_array_items, self, BPy_EnumProperty_Parse_WithSRNA::srna, BPy_PropIDParse::srna, step, BPy_EnumProperty_Parse::value, and BPy_PropIDParse::value.
|
nodiscard |
Definition at line 5274 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, bpy_prop_arg_parse_id(), bpy_prop_arg_parse_tag_defines(), bpy_prop_assign_flag(), bpy_prop_assign_flag_override(), bpy_prop_callback_assign_pointer(), bpy_prop_callback_assign_update(), bpy_prop_callback_check(), bpy_prop_deferred_data_or_srna(), BPy_EnumProperty_Parse::is_set, BPy_EnumProperty_Parse::items, name, pointer_type_from_py(), BPy_PropIDParse::prop_free_handle, PY_ARG_PARSER_HEAD_COMPAT, pymeth_PointerProperty, pyrna_enum_bitfield_parse_set(), RNA_def_pointer_runtime(), RNA_def_property_duplicate_pointers(), RNA_def_property_free_identifier_deferred_finish(), RNA_def_property_tags(), RNA_def_property_translation_context(), RNA_def_struct_flag(), rna_enum_property_flag_items, rna_enum_property_override_flag_items, RNA_PropertyGroup, RNA_struct_idprops_contains_datablock(), RNA_struct_is_a(), RNA_struct_is_ID(), RNA_struct_ui_name(), self, BPy_EnumProperty_Parse_WithSRNA::srna, BPy_PropIDParse::srna, STRUCT_CONTAINS_DATABLOCK_IDPROPERTIES, BPy_EnumProperty_Parse::value, and BPy_PropIDParse::value.
Referenced by deferred_register_prop().
|
static |
Use with #PyArg_ParseTuple's O& formatting.
Definition at line 3279 of file bpy_props.cc.
References MAX_IDPROP_NAME, BPy_PropIDParse::prop_free_handle, RNA_def_property_free_identifier_deferred_prepare(), RNA_struct_identifier(), BPy_PropIDParse::srna, UNLIKELY, and BPy_PropIDParse::value.
Referenced by BPy_BoolProperty(), BPy_BoolVectorProperty(), BPy_CollectionProperty(), BPy_EnumProperty(), BPy_FloatProperty(), BPy_FloatVectorProperty(), BPy_IntProperty(), BPy_IntVectorProperty(), BPy_PointerProperty(), and BPy_StringProperty().
|
static |
Wrapper for pyrna_enum_bitfield_parse_set that looks up tags from the srna.
Definition at line 3324 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, BPy_EnumProperty_Parse::items, pyrna_enum_bitfield_parse_set(), RNA_struct_identifier(), RNA_struct_property_tag_defines(), and BPy_EnumProperty_Parse_WithSRNA::srna.
Referenced by BPy_BoolProperty(), BPy_BoolVectorProperty(), BPy_CollectionProperty(), BPy_EnumProperty(), BPy_FloatProperty(), BPy_FloatVectorProperty(), BPy_IntProperty(), BPy_IntVectorProperty(), BPy_PointerProperty(), and BPy_StringProperty().
|
static |
Return -1 on error.
Definition at line 574 of file bpy_props.cc.
References BPyPropArrayLength::dims, BPyPropArrayLength::dims_len, BPyPropArrayLength::len_total, PyC_AsArray(), and PyC_AsArray_Multi().
Referenced by BPy_BoolVectorProperty(), BPy_FloatVectorProperty(), BPy_IntVectorProperty(), bpy_prop_boolean_array_from_callback_or_error(), bpy_prop_float_array_from_callback_or_error(), and bpy_prop_int_array_from_callback_or_error().
|
static |
Definition at line 643 of file bpy_props.cc.
References BLI_assert, bpy_prop_array_is_matrix_compatible_ex(), PROP_FLOAT, RNA_property_subtype(), and RNA_property_type().
Referenced by bpy_prop_float_array_from_callback_or_error().
|
static |
Definition at line 635 of file bpy_props.cc.
References BPyPropArrayLength::dims, BPyPropArrayLength::dims_len, and PROP_MATRIX.
Referenced by BPy_FloatVectorProperty(), and bpy_prop_array_is_matrix_compatible().
|
static |
Use with #PyArg_ParseTuple's O& formatting.
Definition at line 506 of file bpy_props.cc.
References BPyPropArrayLength::dims, BPyPropArrayLength::dims_len, i, BPyPropArrayLength::len_total, Py_DECREF(), PYRNA_STACK_ARRAY, RNA_MAX_ARRAY_DIMENSION, size(), and STRINGIFY.
Referenced by BPy_BoolVectorProperty(), BPy_FloatVectorProperty(), and BPy_IntVectorProperty().
|
static |
Definition at line 667 of file bpy_props.cc.
References BLI_assert, bpy_prop_array_matrix_swap_row_column_vn_vn(), and BPyPropArrayLength::dims.
Referenced by BPy_FloatVectorProperty(), and bpy_prop_float_array_from_callback_or_error().
|
static |
Needed since the internal storage of matrices swaps row/column.
Definition at line 653 of file bpy_props.cc.
References BLI_assert, BPyPropArrayLength::dims, and i.
Referenced by bpy_prop_array_matrix_swap_row_column_vn().
|
static |
Definition at line 420 of file bpy_props.cc.
References flag, PROP_ANIMATABLE, PROP_EDITABLE, RNA_def_property_clear_flag(), and RNA_def_property_flag().
Referenced by BPy_BoolProperty(), BPy_BoolVectorProperty(), BPy_CollectionProperty(), BPy_EnumProperty(), BPy_FloatProperty(), BPy_FloatVectorProperty(), BPy_IntProperty(), BPy_IntVectorProperty(), BPy_PointerProperty(), and BPy_StringProperty().
|
static |
Definition at line 438 of file bpy_props.cc.
References RNA_def_property_override_flag().
Referenced by BPy_BoolProperty(), BPy_BoolVectorProperty(), BPy_CollectionProperty(), BPy_EnumProperty(), BPy_FloatProperty(), BPy_FloatVectorProperty(), BPy_IntProperty(), BPy_IntVectorProperty(), BPy_PointerProperty(), and BPy_StringProperty().
|
static |
Definition at line 918 of file bpy_props.cc.
References bpy_prop_array_from_py_with_dims(), i, BPyPropArrayLength::len_total, and PyC_Err_PrintWithFunc().
Referenced by bpy_prop_boolean_array_get_fn(), bpy_prop_boolean_array_get_transform_fn(), and bpy_prop_boolean_array_set_transform_fn().
|
static |
Definition at line 950 of file bpy_props.cc.
References BLI_assert, bpy_prop_boolean_array_from_callback_or_error(), bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::get_fn, ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_boolean_array().
|
static |
Definition at line 978 of file bpy_props.cc.
References BLI_assert, bpy_prop_boolean_array_from_callback_or_error(), bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_py_object_from_prop_array_with_dims(), BPyPropStore::get_transform_fn, ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_boolean_array().
|
static |
Definition at line 1011 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_py_object_from_prop_array_with_dims(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_fn.
Referenced by bpy_prop_callback_assign_boolean_array().
|
static |
Definition at line 1051 of file bpy_props.cc.
References BLI_assert, bpy_prop_boolean_array_from_callback_or_error(), bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_py_object_from_prop_array_with_dims(), ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_transform_fn.
Referenced by bpy_prop_callback_assign_boolean_array().
|
static |
Definition at line 739 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::get_fn, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), PyC_Long_AsBool(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_boolean().
|
static |
Definition at line 785 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::get_transform_fn, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), PyC_Long_AsBool(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_boolean().
|
static |
Definition at line 832 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_fn.
Referenced by bpy_prop_callback_assign_boolean().
|
static |
Definition at line 869 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), PyC_Long_AsBool(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_transform_fn.
Referenced by bpy_prop_callback_assign_boolean().
|
static |
Definition at line 2761 of file bpy_props.cc.
References ASSIGN_PYOBJECT_INCREF, bpy_prop_boolean_get_fn(), bpy_prop_boolean_get_transform_fn(), bpy_prop_boolean_set_fn(), bpy_prop_boolean_set_transform_fn(), bpy_prop_py_data_ensure(), BPyPropStore::get_fn, BPyPropStore::get_transform_fn, BPyPropStore::py_data, RNA_def_property_boolean_funcs_runtime(), BPyPropStore::set_fn, and BPyPropStore::set_transform_fn.
Referenced by BPy_BoolProperty().
|
static |
Definition at line 2813 of file bpy_props.cc.
References ASSIGN_PYOBJECT_INCREF, bpy_prop_boolean_array_get_fn(), bpy_prop_boolean_array_get_transform_fn(), bpy_prop_boolean_array_set_fn(), bpy_prop_boolean_array_set_transform_fn(), bpy_prop_py_data_ensure(), BPyPropStore::get_fn, BPyPropStore::get_transform_fn, BPyPropStore::py_data, RNA_def_property_boolean_array_funcs_runtime(), BPyPropStore::set_fn, and BPyPropStore::set_transform_fn.
Referenced by BPy_BoolVectorProperty().
|
static |
Definition at line 3134 of file bpy_props.cc.
References ASSIGN_PYOBJECT_INCREF, bpy_prop_enum_get_fn(), bpy_prop_enum_get_transform_fn(), bpy_prop_enum_itemf_fn(), bpy_prop_enum_set_fn(), bpy_prop_enum_set_transform_fn(), bpy_prop_py_data_ensure(), BPyPropStore::enum_data, BPyPropStore::get_fn, BPyPropStore::get_transform_fn, BPyPropStore::itemf_fn, BPyPropStore::py_data, RNA_def_property_enum_funcs_runtime(), BPyPropStore::set_fn, and BPyPropStore::set_transform_fn.
Referenced by BPy_EnumProperty().
|
static |
Definition at line 2966 of file bpy_props.cc.
References ASSIGN_PYOBJECT_INCREF, bpy_prop_float_get_fn(), bpy_prop_float_get_transform_fn(), bpy_prop_float_set_fn(), bpy_prop_float_set_transform_fn(), bpy_prop_py_data_ensure(), BPyPropStore::get_fn, BPyPropStore::get_transform_fn, BPyPropStore::py_data, RNA_def_property_float_funcs_runtime(), BPyPropStore::set_fn, and BPyPropStore::set_transform_fn.
Referenced by BPy_FloatProperty().
|
static |
Definition at line 3018 of file bpy_props.cc.
References ASSIGN_PYOBJECT_INCREF, bpy_prop_float_array_get_fn(), bpy_prop_float_array_get_transform_fn(), bpy_prop_float_array_set_fn(), bpy_prop_float_array_set_transform_fn(), bpy_prop_py_data_ensure(), BPyPropStore::get_fn, BPyPropStore::get_transform_fn, BPyPropStore::py_data, RNA_def_property_float_array_funcs_runtime(), BPyPropStore::set_fn, and BPyPropStore::set_transform_fn.
Referenced by BPy_FloatVectorProperty().
|
static |
Definition at line 2865 of file bpy_props.cc.
References ASSIGN_PYOBJECT_INCREF, bpy_prop_int_get_fn(), bpy_prop_int_get_transform_fn(), bpy_prop_int_set_fn(), bpy_prop_int_set_transform_fn(), bpy_prop_py_data_ensure(), BPyPropStore::get_fn, BPyPropStore::get_transform_fn, BPyPropStore::py_data, RNA_def_property_int_funcs_runtime(), BPyPropStore::set_fn, and BPyPropStore::set_transform_fn.
Referenced by BPy_IntProperty().
|
static |
Definition at line 2917 of file bpy_props.cc.
References ASSIGN_PYOBJECT_INCREF, bpy_prop_int_array_get_fn(), bpy_prop_int_array_get_transform_fn(), bpy_prop_int_array_set_fn(), bpy_prop_int_array_set_transform_fn(), bpy_prop_py_data_ensure(), BPyPropStore::get_fn, BPyPropStore::get_transform_fn, BPyPropStore::py_data, RNA_def_property_int_array_funcs_runtime(), BPyPropStore::set_fn, and BPyPropStore::set_transform_fn.
Referenced by BPy_IntVectorProperty().
|
static |
Definition at line 2751 of file bpy_props.cc.
References ASSIGN_PYOBJECT_INCREF, bpy_prop_pointer_poll_fn(), bpy_prop_py_data_ensure(), BPyPropStore::pointer_data, BPyPropStore::poll_fn, BPyPropStore::py_data, and RNA_def_property_poll_runtime().
Referenced by BPy_PointerProperty().
|
static |
Definition at line 3067 of file bpy_props.cc.
References ASSIGN_PYOBJECT_INCREF, bpy_prop_py_data_ensure(), bpy_prop_string_get_fn(), bpy_prop_string_get_transform_fn(), bpy_prop_string_length_fn(), bpy_prop_string_set_fn(), bpy_prop_string_set_transform_fn(), bpy_prop_string_visit_for_search_fn(), BPyPropStore::get_fn, BPyPropStore::get_transform_fn, BPyPropStore::py_data, RNA_def_property_string_funcs_runtime(), RNA_def_property_string_search_func_runtime(), BPyPropStore::search_fn, BPyPropStore::set_fn, BPyPropStore::set_transform_fn, and BPyPropStore::string_data.
Referenced by BPy_StringProperty().
|
static |
Definition at line 2740 of file bpy_props.cc.
References ASSIGN_PYOBJECT_INCREF, bpy_prop_py_data_ensure(), bpy_prop_update_fn(), BPyPropStore::py_data, RNA_def_property_update_runtime_with_context_and_property(), and BPyPropStore::update_fn.
Referenced by BPy_BoolProperty(), BPy_BoolVectorProperty(), BPy_EnumProperty(), BPy_FloatProperty(), BPy_FloatVectorProperty(), BPy_IntProperty(), BPy_IntVectorProperty(), BPy_PointerProperty(), and BPy_StringProperty().
|
static |
Definition at line 2709 of file bpy_props.cc.
Referenced by BPy_BoolProperty(), BPy_BoolVectorProperty(), BPy_EnumProperty(), BPy_FloatProperty(), BPy_FloatVectorProperty(), BPy_IntProperty(), BPy_IntVectorProperty(), BPy_PointerProperty(), and BPy_StringProperty().
|
static |
HACK: needed by typing.get_type_hints with from __future__ import annotations enabled or when using Python 3.10 or newer.
When callable this object type passes the test for being an acceptable annotation.
Definition at line 263 of file bpy_props.cc.
|
static |
Definition at line 246 of file bpy_props.cc.
References self.
|
static |
Definition at line 361 of file bpy_props.cc.
References BLI_assert, bpy_prop_deferred_Type, and self.
Referenced by bpy_prop_deferred_data_or_srna().
|
static |
This define runs at the start of each function and deals with returning a deferred property BPy_PropDeferred (to be registered later).
| self | The self argument from the caller. |
| args | The positional arguments of the caller. |
| kw | The keyword arguments of the caller. |
| method_object | The method of the caller (unfortunately this can't be deduced). |
| r_deferred_result | The deferred result (or nullptr in the case of an error). The caller must return this value unless a valid srna is returned. |
Definition at line 3213 of file bpy_props.cc.
References BLI_assert, bpy_prop_deferred_data_CreatePyObject(), nullptr, Py_DECREF(), self, and srna_from_self().
Referenced by BPy_BoolProperty(), BPy_BoolVectorProperty(), BPy_CollectionProperty(), BPy_EnumProperty(), BPy_FloatProperty(), BPy_FloatVectorProperty(), BPy_IntProperty(), BPy_IntVectorProperty(), BPy_PointerProperty(), and BPy_StringProperty().
|
static |
Definition at line 233 of file bpy_props.cc.
References self.
|
static |
Expose the function in case scripts need to introspect this information (not currently used by Blender itself).
Definition at line 277 of file bpy_props.cc.
|
static |
Expose keywords in case scripts need to introspect this information (not currently used by Blender itself).
Definition at line 288 of file bpy_props.cc.
|
static |
Definition at line 252 of file bpy_props.cc.
References self.
|
static |
Definition at line 240 of file bpy_props.cc.
References self.
|
static |
Definition at line 2237 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::get_fn, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_enum_get_default(), RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_enum().
|
static |
Definition at line 2280 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::get_transform_fn, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_enum().
|
static |
Definition at line 2629 of file bpy_props.cc.
References bpy_context_clear(), bpy_context_module, bpy_context_set(), C, BPyPropStore::enum_data, enum_items_from_py(), BPyPropStore::itemf_fn, PROP_ENUM_FLAG, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, rna_enum_dummy_NULL_items, RNA_property_flag(), RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_enum().
|
static |
Definition at line 2325 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_fn.
Referenced by bpy_prop_callback_assign_enum().
|
static |
Definition at line 2362 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_transform_fn.
Referenced by bpy_prop_callback_assign_enum().
|
static |
Definition at line 1618 of file bpy_props.cc.
References bpy_prop_array_from_py_with_dims(), bpy_prop_array_is_matrix_compatible(), bpy_prop_array_matrix_swap_row_column_vn(), i, BPyPropArrayLength::len_total, and PyC_Err_PrintWithFunc().
Referenced by bpy_prop_float_array_get_fn(), bpy_prop_float_array_get_transform_fn(), and bpy_prop_float_array_set_transform_fn().
|
static |
Definition at line 1657 of file bpy_props.cc.
References BLI_assert, bpy_prop_float_array_from_callback_or_error(), bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::get_fn, ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_float_array().
|
static |
Definition at line 1686 of file bpy_props.cc.
References BLI_assert, bpy_prop_float_array_from_callback_or_error(), bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_py_object_from_prop_array_with_dims(), BPyPropStore::get_fn, BPyPropStore::get_transform_fn, ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_float_array().
|
static |
Definition at line 1723 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_py_object_from_prop_array_with_dims(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_fn.
Referenced by bpy_prop_callback_assign_float_array().
|
static |
Definition at line 1763 of file bpy_props.cc.
References BLI_assert, bpy_prop_float_array_from_callback_or_error(), bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_py_object_from_prop_array_with_dims(), ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_transform_fn.
Referenced by bpy_prop_callback_assign_float_array().
|
static |
Definition at line 1446 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::get_fn, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_float().
|
static |
Definition at line 1489 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::get_transform_fn, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_float().
|
static |
Definition at line 1534 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_fn.
Referenced by bpy_prop_callback_assign_float().
|
static |
Definition at line 1571 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_transform_fn.
Referenced by bpy_prop_callback_assign_float().
|
static |
Definition at line 451 of file bpy_props.cc.
References pyrna_write_check().
Referenced by bpy_prop_boolean_array_get_fn(), bpy_prop_boolean_array_get_transform_fn(), bpy_prop_boolean_array_set_fn(), bpy_prop_boolean_array_set_transform_fn(), bpy_prop_boolean_get_fn(), bpy_prop_boolean_get_transform_fn(), bpy_prop_boolean_set_fn(), bpy_prop_boolean_set_transform_fn(), bpy_prop_enum_get_fn(), bpy_prop_enum_get_transform_fn(), bpy_prop_enum_set_fn(), bpy_prop_enum_set_transform_fn(), bpy_prop_float_array_get_fn(), bpy_prop_float_array_get_transform_fn(), bpy_prop_float_array_set_fn(), bpy_prop_float_array_set_transform_fn(), bpy_prop_float_get_fn(), bpy_prop_float_get_transform_fn(), bpy_prop_float_set_fn(), bpy_prop_float_set_transform_fn(), bpy_prop_int_array_get_fn(), bpy_prop_int_array_get_transform_fn(), bpy_prop_int_array_set_fn(), bpy_prop_int_array_set_transform_fn(), bpy_prop_int_get_fn(), bpy_prop_int_get_transform_fn(), bpy_prop_int_set_fn(), bpy_prop_int_set_transform_fn(), bpy_prop_pointer_poll_fn(), bpy_prop_string_get_fn(), bpy_prop_string_get_transform_fn(), bpy_prop_string_length_fn(), bpy_prop_string_set_fn(), and bpy_prop_string_set_transform_fn().
|
static |
Definition at line 462 of file bpy_props.cc.
References BPyPropGIL_RNAWritable_State::gilstate, BPyPropGIL_RNAWritable_State::is_write_ok, and pyrna_write_set().
Referenced by bpy_prop_boolean_array_get_fn(), bpy_prop_boolean_array_get_transform_fn(), bpy_prop_boolean_array_set_fn(), bpy_prop_boolean_array_set_transform_fn(), bpy_prop_boolean_get_fn(), bpy_prop_boolean_get_transform_fn(), bpy_prop_boolean_set_fn(), bpy_prop_boolean_set_transform_fn(), bpy_prop_enum_get_fn(), bpy_prop_enum_get_transform_fn(), bpy_prop_enum_set_fn(), bpy_prop_enum_set_transform_fn(), bpy_prop_float_array_get_fn(), bpy_prop_float_array_get_transform_fn(), bpy_prop_float_array_set_fn(), bpy_prop_float_array_set_transform_fn(), bpy_prop_float_get_fn(), bpy_prop_float_get_transform_fn(), bpy_prop_float_set_fn(), bpy_prop_float_set_transform_fn(), bpy_prop_int_array_get_fn(), bpy_prop_int_array_get_transform_fn(), bpy_prop_int_array_set_fn(), bpy_prop_int_array_set_transform_fn(), bpy_prop_int_get_fn(), bpy_prop_int_get_transform_fn(), bpy_prop_int_set_fn(), bpy_prop_int_set_transform_fn(), bpy_prop_pointer_poll_fn(), bpy_prop_string_get_fn(), bpy_prop_string_get_transform_fn(), bpy_prop_string_length_fn(), bpy_prop_string_set_fn(), and bpy_prop_string_set_transform_fn().
|
static |
Definition at line 1268 of file bpy_props.cc.
References bpy_prop_array_from_py_with_dims(), i, BPyPropArrayLength::len_total, and PyC_Err_PrintWithFunc().
Referenced by bpy_prop_int_array_get_fn(), bpy_prop_int_array_get_transform_fn(), and bpy_prop_int_array_set_transform_fn().
|
static |
Definition at line 1300 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_prop_int_array_from_callback_or_error(), BPyPropStore::get_fn, ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_int_array().
|
static |
Definition at line 1328 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_prop_int_array_from_callback_or_error(), bpy_py_object_from_prop_array_with_dims(), BPyPropStore::get_transform_fn, ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_int_array().
|
static |
Definition at line 1361 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_py_object_from_prop_array_with_dims(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_fn.
Referenced by bpy_prop_callback_assign_int_array().
|
static |
Definition at line 1401 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_prop_int_array_from_callback_or_error(), bpy_py_object_from_prop_array_with_dims(), ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_transform_fn.
Referenced by bpy_prop_callback_assign_int_array().
|
static |
Definition at line 1096 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::get_fn, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_int().
|
static |
Definition at line 1139 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::get_transform_fn, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_int().
|
static |
Definition at line 1184 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_fn.
Referenced by bpy_prop_callback_assign_int().
|
static |
Definition at line 1221 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::set_transform_fn.
Referenced by bpy_prop_callback_assign_int().
|
static |
Definition at line 2193 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), BPyPropStore::pointer_data, BPyPropStore::poll_fn, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, result, ret, RNA_property_py_data_get(), and self.
Referenced by bpy_prop_callback_assign_pointer().
|
static |
Definition at line 195 of file bpy_props.cc.
References BLI_addtail(), g_bpy_prop_store_list, MEM_callocN(), RNA_def_py_data(), and RNA_property_py_data_get().
Referenced by bpy_prop_callback_assign_boolean(), bpy_prop_callback_assign_boolean_array(), bpy_prop_callback_assign_enum(), bpy_prop_callback_assign_float(), bpy_prop_callback_assign_float_array(), bpy_prop_callback_assign_int(), bpy_prop_callback_assign_int_array(), bpy_prop_callback_assign_pointer(), bpy_prop_callback_assign_string(), and bpy_prop_callback_assign_update().
|
static |
Perform all removal actions except for freeing, which is handled by RNA.
Definition at line 209 of file bpy_props.cc.
References BLI_remlink(), BPY_PROP_STORE_PY_DATA_SIZE, g_bpy_prop_store_list, i, BPyPropStore::py_data, and RNA_property_py_data_get().
Referenced by BPY_rna_props().
|
static |
Definition at line 1810 of file bpy_props.cc.
References length(), and PyC_Err_PrintWithFunc().
Referenced by bpy_prop_string_get_locked_fn(), bpy_prop_string_get_transform_locked_fn(), and bpy_prop_string_set_transform_fn().
|
static |
Definition at line 1869 of file bpy_props.cc.
References bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_prop_string_get_locked_fn(), and ptr.
Referenced by bpy_prop_callback_assign_string().
|
static |
Definition at line 1845 of file bpy_props.cc.
References BLI_assert, bpy_prop_string_from_callback_or_error(), BPyPropStore::get_fn, ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), RNA_property_string_maxlength(), and self.
Referenced by bpy_prop_string_get_fn(), and bpy_prop_string_length_fn().
|
static |
Definition at line 1912 of file bpy_props.cc.
References bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_prop_string_get_transform_locked_fn(), and ptr.
Referenced by bpy_prop_callback_assign_string().
|
static |
Definition at line 1880 of file bpy_props.cc.
References BLI_assert, bpy_prop_string_from_callback_or_error(), BPyPropStore::get_transform_fn, ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), RNA_property_string_maxlength(), and self.
Referenced by bpy_prop_string_get_transform_fn().
|
static |
Definition at line 1926 of file bpy_props.cc.
References bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_prop_string_get_locked_fn(), length(), ptr, and ret.
Referenced by bpy_prop_callback_assign_string().
|
static |
Definition at line 1940 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), RNA_property_string_maxlength(), self, and BPyPropStore::set_fn.
Referenced by bpy_prop_callback_assign_string().
|
static |
Definition at line 1995 of file bpy_props.cc.
References BLI_assert, bpy_prop_gil_rna_writable_begin(), bpy_prop_gil_rna_writable_end(), bpy_prop_string_from_callback_or_error(), ptr, BPyPropStore::py_data, Py_DECREF(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), RNA_property_string_maxlength(), self, and BPyPropStore::set_transform_fn.
Referenced by bpy_prop_callback_assign_string().
|
static |
Definition at line 2035 of file bpy_props.cc.
References StringPropertySearchVisitParams::info, PY_ARG_PARSER_HEAD_COMPAT, PyC_Err_PrintWithFunc(), StringPropertySearchVisitParams::text, and UNLIKELY.
Referenced by bpy_prop_string_visit_for_search_fn().
|
static |
Definition at line 2082 of file bpy_props.cc.
References BLI_assert, bpy_context_clear(), bpy_context_module, bpy_context_set(), bpy_prop_string_visit_fn_call(), C, i, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), BPyPropStore::search_fn, self, and BPyPropStore::string_data.
Referenced by bpy_prop_callback_assign_string().
|
static |
Definition at line 686 of file bpy_props.cc.
References BLI_assert, bpy_context_clear(), bpy_context_module, bpy_context_set(), C, ptr, BPyPropStore::py_data, Py_DECREF(), PyC_Err_PrintWithFunc(), pyrna_struct_as_instance(), pyrna_write_check(), pyrna_write_set(), PyTuple_SET_ITEMS, ret, RNA_property_py_data_get(), self, and BPyPropStore::update_fn.
Referenced by bpy_prop_callback_assign_update().
|
static |
Definition at line 591 of file bpy_props.cc.
References BLI_assert_unreachable, BPyPropArrayLength::dims, BPyPropArrayLength::dims_len, BPyPropArrayLength::len_total, PyC_Tuple_PackArray_Bool(), PyC_Tuple_PackArray_F32(), PyC_Tuple_PackArray_I32(), PyC_Tuple_PackArray_Multi_Bool(), PyC_Tuple_PackArray_Multi_F32(), and PyC_Tuple_PackArray_Multi_I32().
Referenced by bpy_prop_boolean_array_get_transform_fn(), bpy_prop_boolean_array_set_fn(), bpy_prop_boolean_array_set_transform_fn(), bpy_prop_float_array_get_transform_fn(), bpy_prop_float_array_set_fn(), bpy_prop_float_array_set_transform_fn(), bpy_prop_int_array_get_transform_fn(), bpy_prop_int_array_set_fn(), and bpy_prop_int_array_set_transform_fn().
|
static |
Definition at line 5557 of file bpy_props.cc.
References BPy_RemoveProperty(), PY_ARG_PARSER_HEAD_COMPAT, Py_DECREF(), ret, RNA_def_property_free_identifier(), self, and srna_from_self().
Referenced by BPy_RemoveProperty().
|
nodiscard |
Definition at line 5724 of file bpy_props.cc.
References ASSIGN_STATIC, bpy_prop_deferred_Type, bpy_prop_py_data_remove(), props_module, and RNA_def_property_free_pointers_set_py_data_callback().
Referenced by BPy_init_modules().
| void BPY_rna_props_clear_all | ( | ) |
Run this on exit, clearing all Python callback users and disable the RNA callback, as it would be called after Python has already finished.
Definition at line 5760 of file bpy_props.cc.
References BLI_listbase_clear(), g_bpy_prop_store_list, props_clear(), and RNA_def_property_free_pointers_set_py_data_callback().
Referenced by BPY_python_end().
|
static |
Definition at line 4763 of file bpy_props.cc.
References BPy_EnumProperty_Parse_WithSRNA::base, bpy_prop_arg_parse_id(), bpy_prop_arg_parse_tag_defines(), bpy_prop_assign_flag(), bpy_prop_assign_flag_override(), bpy_prop_callback_assign_string(), bpy_prop_callback_assign_update(), bpy_prop_callback_check(), bpy_prop_deferred_data_or_srna(), BPy_EnumProperty_Parse::is_set, BPy_EnumProperty_Parse::items, name, BPy_PropIDParse::prop_free_handle, PROP_NONE, PROP_STRING, PROP_STRING_SEARCH_SUGGESTION, PY_ARG_PARSER_HEAD_COMPAT, pymeth_StringProperty, pyrna_enum_bitfield_parse_set(), pyrna_enum_value_parse_string(), RNA_def_property(), RNA_def_property_duplicate_pointers(), RNA_def_property_free_identifier_deferred_finish(), RNA_def_property_string_default(), RNA_def_property_string_maxlength(), RNA_def_property_tags(), RNA_def_property_translation_context(), RNA_def_property_ui_text(), rna_enum_property_flag_items, rna_enum_property_override_flag_items, rna_enum_property_string_search_flag_items, rna_enum_property_subtype_string_items, self, BPy_EnumProperty_Parse_WithSRNA::srna, BPy_PropIDParse::srna, BPy_EnumProperty_Parse::value, and BPy_PropIDParse::value.
|
static |
Definition at line 2453 of file bpy_props.cc.
References EnumPropertyItem::description, i, EnumPropertyItem::icon, icon_id_from_name(), EnumPropertyItem::identifier, MEM_calloc_arrayN(), MEM_freeN(), MEM_mallocN(), EnumPropertyItem::name, py_long_as_int(), py_long_as_int(), RNA_ENUM_BITFLAG_SIZE, STREQ, STRINGIFY, and EnumPropertyItem::value.
Referenced by BPy_EnumProperty(), and bpy_prop_enum_itemf_fn().
|
static |
Definition at line 2437 of file bpy_props.cc.
References EnumPropertyItem::identifier, EnumPropertyItem::name, name, rna_enum_icon_items, STREQ, and EnumPropertyItem::value.
Referenced by enum_items_from_py().
|
nodiscard |
Definition at line 5223 of file bpy_props.cc.
References Py_DECREF(), PyC_ExceptionBuffer(), and srna_from_self().
Referenced by BPy_CollectionProperty(), and BPy_PointerProperty().
|
static |
Definition at line 5692 of file bpy_props.cc.
References BPY_PROP_STORE_PY_DATA_SIZE, g_bpy_prop_store_list, i, and LISTBASE_FOREACH.
Referenced by BPY_rna_props_clear_all().
|
static |
Definition at line 5681 of file bpy_props.cc.
References BPY_PROP_STORE_PY_DATA_SIZE, g_bpy_prop_store_list, i, and LISTBASE_FOREACH.
|
static |
Definition at line 2410 of file bpy_props.cc.
Referenced by BPy_EnumProperty(), and enum_items_from_py().
| PyDoc_STRVAR | ( | BPy_BoolProperty_doc | , |
| ".. function:: | BoolProperty" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=False, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new boolean property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_NUMBER_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("bool") BPY_PROPDEF_SET_DOC("bool") BPY_PROPDEF_GET_TRANSFORM_DOC("bool") BPY_PROPDEF_SET_TRANSFORM_DOC("bool" ) |
| PyDoc_STRVAR | ( | BPy_BoolVectorProperty_doc | , |
| ".. function:: | BoolVectorProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=(False, False, False), " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "size=3, " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new vector boolean property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC " :arg default: sequence of booleans the length of *size*.\n" " :type default: Sequence\n" BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_NUMBER_ARRAY_DOC BPY_PROPDEF_VECSIZE_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("Sequence[bool]") BPY_PROPDEF_SET_TRANSFORM_DOC("Sequence[bool]")[bool] ) |
| PyDoc_STRVAR | ( | BPy_CollectionProperty_doc | , |
| ".. function:: CollectionProperty(" "type, " "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "options={'ANIMATABLE'}, " "override=set(), " "tags=set())\n" "\n" " Returns a new collection property definition.\n" "\n" BPY_PROPDEF_COLLECTION_TYPE_DOC BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_COLLECTION_DOC | BPY_PROPDEF_TAGS_DOC ) |
| PyDoc_STRVAR | ( | BPy_EnumProperty_doc | , |
| ".. function:: EnumProperty(" "items, " "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=None, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new enumerator property definition.\n" "\n" " :arg items: sequence of enum items formatted:\n" " ````.\n" "\n" " The first three elements of the tuples are mandatory.\n" "\n" " :identifier: The identifier is used for Python access.\n" " An empty identifier means that the item is a separator\n" " :name: Name for the interface.\n" " :description: Used for documentation and tooltips.\n" " :icon: An icon string identifier or integer icon value\n" " (e.g. returned by :class:`bpy.types.UILayout.icon`)\n" " :number: Unique value used as the identifier for this item (stored in file data).\n" " Use when the identifier may need to change. If the *ENUM_FLAG* option is | used[(identifier, name, description, icon, number),...], | ||
| \n" " the values are bit-masks and should be powers of two.\n" "\n" " When an item only contains 4 items they define `` | identifier, name, description, " "number)``.\n" "\n" " Separators may be added using either None(nameless separator, | ||
| \n" " or a regular item tuple with an empty identifier | string, | ||
| in which case the | name, | ||
| \n" " if non- | empty, | ||
| will be displayed in the UI above the separator line." "\n" " For dynamic values a callback can be passed which returns a list in\n" " the same format as the static list.\n" " This function must take 2 arguments ``(self, context)`` | , | ||
| **context may be None **.\n" "\n" " .. warning::\n" "\n" " There is a known bug with using a | callback, | ||
| \n" " Python must keep a reference to the strings returned by the callback or Blender\n" " will misbehave or even crash." "\n" " :type items:Iterable|" "tuple|" "tuple|" "None]|" " | Callable[" "tuple[str, str, str][str, str, str, int][str, str, str, int, int][[:class:`bpy.types.bpy_struct`, :class:`bpy.types.Context`|None], | ||
| " "Iterable|" "tuple|" "tuple|" "None]" "]\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC " :arg default:The default value for this | enum[" "tuple[str, str, str][str, str, str, int][str, str, str, int, int], | ||
| a string from the identifiers used in " " *items * | , | ||
| or integer matching an item number.\n" " If the *ENUM_FLAG *option is used this must be a set of such string identifiers " "instead.\n" " WARNING:Strings cannot be specified for dynamic enums\n" " | (i.e. if a callback function is given as *items *parameter).\n" " :type default:str|int|set\n" BPY_PROPDEF_OPTIONS_ENUM_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("int") BPY_PROPDEF_SET_DOC("int") BPY_PROPDEF_GET_TRANSFORM_DOC("int") BPY_PROPDEF_SET_TRANSFORM_DOC("int")[str] ) |
| PyDoc_STRVAR | ( | BPy_FloatProperty_doc | , |
| ".. function:: | FloatProperty" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=0.0, " "min=-3.402823e+38, max=3.402823e+38, " "soft_min=-3.402823e+38, soft_max=3.402823e+38, " "step=3, " "precision=2, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "unit='NONE', " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new float (single precision) property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC BPY_PROPDEF_NUM_MINMAX_DOC("float") BPY_PROPDEF_NUM_SOFT_MINMAX_DOC("float") BPY_PROPDEF_FLOAT_STEP_DOC BPY_PROPDEF_FLOAT_PREC_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_NUMBER_DOC BPY_PROPDEF_UNIT_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("float") BPY_PROPDEF_SET_DOC("float") BPY_PROPDEF_GET_TRANSFORM_DOC("float") BPY_PROPDEF_SET_TRANSFORM_DOC("float" ) |
| PyDoc_STRVAR | ( | BPy_FloatVectorProperty_doc | , |
| ".. function:: | FloatVectorProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=(0.0, 0.0, 0.0), " "min=sys.float_info.min, max=sys.float_info.max, " "soft_min=sys.float_info.min, soft_max=sys.float_info.max, " "step=3, " "precision=2, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "unit='NONE', " "size=3, " "update=None, " "get=None, " "set=None)\n" "\n" " Returns a new vector float property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC " :arg default: Sequence of floats the length of *size*.\n" " :type default: Sequence\n" BPY_PROPDEF_NUM_MINMAX_DOC("float") BPY_PROPDEF_NUM_SOFT_MINMAX_DOC("float") BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_FLOAT_STEP_DOC BPY_PROPDEF_FLOAT_PREC_DOC BPY_PROPDEF_SUBTYPE_NUMBER_ARRAY_DOC BPY_PROPDEF_UNIT_DOC BPY_PROPDEF_VECSIZE_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("Sequence[float]") BPY_PROPDEF_SET_TRANSFORM_DOC("Sequence[float]")[float] ) |
References BPY_PROPDEF_CTXT_DOC, BPY_PROPDEF_DESC_DOC, BPY_PROPDEF_FLOAT_PREC_DOC, BPY_PROPDEF_FLOAT_STEP_DOC, BPY_PROPDEF_NAME_DOC, BPY_PROPDEF_OPTIONS_DOC, BPY_PROPDEF_OPTIONS_OVERRIDE_DOC, BPY_PROPDEF_SUBTYPE_NUMBER_ARRAY_DOC, BPY_PROPDEF_TAGS_DOC, BPY_PROPDEF_UNIT_DOC, BPY_PROPDEF_UPDATE_DOC, and BPY_PROPDEF_VECSIZE_DOC.
| PyDoc_STRVAR | ( | BPy_IntProperty_doc | , |
| ".. function:: | IntProperty" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=0, " "min=-2**31, max=2**31-1, " "soft_min=-2**31, soft_max=2**31-1, " "step=1, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new int property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC BPY_PROPDEF_NUM_MINMAX_DOC("int") BPY_PROPDEF_NUM_SOFT_MINMAX_DOC("int") BPY_PROPDEF_INT_STEP_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_NUMBER_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("int") BPY_PROPDEF_SET_DOC("int") BPY_PROPDEF_GET_TRANSFORM_DOC("int") BPY_PROPDEF_SET_TRANSFORM_DOC("int" ) |
| PyDoc_STRVAR | ( | BPy_IntVectorProperty_doc | , |
| ".. function:: | IntVectorProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=(0, 0, 0), min=-2**31, max=2**31-1, " "soft_min=-2**31, " "soft_max=2**31-1, " "step=1, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "size=3, " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None)\n" "\n" " Returns a new vector int property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC " :arg default: sequence of ints the length of *size*.\n" " :type default: Sequence\n" BPY_PROPDEF_NUM_MINMAX_DOC("int") BPY_PROPDEF_INT_STEP_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_NUMBER_ARRAY_DOC BPY_PROPDEF_VECSIZE_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("Sequence[int]") BPY_PROPDEF_SET_TRANSFORM_DOC("Sequence[int]")[int] ) |
| PyDoc_STRVAR | ( | BPy_PointerProperty_doc | , |
| ".. function:: PointerProperty(" "type, " "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "poll=None, " "update=None)\n" "\n" " Returns a new pointer property definition.\n" "\n" BPY_PROPDEF_POINTER_TYPE_DOC BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_POLL_DOC BPY_PROPDEF_UPDATE_DOC "\n" ".. note:: Pointer properties do not support storing references to embedded IDs " "(e.g. :class:`bpy.types.Scene.collection`, :class:`bpy.types.Material.node_tree`).\n" " These should exclusively be referenced and accessed through their owner ID " "(e.g. the scene or material).\n" | ) |
| PyDoc_STRVAR | ( | bpy_prop_deferred_doc | , |
| "Intermediate storage for properties before registration.\n" "\n" ".. note::\n" "\n" " This is not part of the stable API and may change between releases.\n" | ) |
| PyDoc_STRVAR | ( | BPy_RemoveProperty_doc | , |
| ".. function:: RemoveProperty(cls, attr)\n" "\n" " Removes a dynamically defined property.\n" "\n" " :arg cls: The class containing the property (must be a positional argument).\n" " :type cls: type\n" " :arg attr: Property name (must be passed as a keyword).\n" " :type attr: str\n" "\n" ".. note:: Typically this function doesn't need to be accessed directly.\n" " Instead use ``del cls.attr``\n" | ) |
| PyDoc_STRVAR | ( | BPy_StringProperty_doc | , |
| ".. function:: StringProperty(" "*, " "name=\"\", " "description=\"\", " "translation_context=\"*\", " "default=\"\", " "maxlen=0, " "options={'ANIMATABLE'}, " "override=set(), " "tags=set(), " "subtype='NONE', " "update=None, " "get=None, " "set=None, " "get_transform=None, " "set_transform=None, " "search=None, " "search_options={'SUGGESTION'})\n" "\n" " Returns a new string property definition.\n" "\n" BPY_PROPDEF_NAME_DOC BPY_PROPDEF_DESC_DOC BPY_PROPDEF_CTXT_DOC " :arg default: initializer string.\n" " :type default: str\n" " :arg maxlen: maximum length of the string.\n" " :type maxlen: int\n" BPY_PROPDEF_OPTIONS_DOC BPY_PROPDEF_OPTIONS_OVERRIDE_DOC BPY_PROPDEF_TAGS_DOC BPY_PROPDEF_SUBTYPE_STRING_DOC BPY_PROPDEF_UPDATE_DOC BPY_PROPDEF_GET_DOC("str") BPY_PROPDEF_SET_DOC("str") BPY_PROPDEF_GET_TRANSFORM_DOC("str") BPY_PROPDEF_SET_TRANSFORM_DOC("str") | BPY_PROPDEF_SEARCH_DOC ) |
| PyDoc_STRVAR | ( | props_module_doc | , |
| "This module defines properties to extend Blender's internal data. The result of these " "functions" " is used to assign properties to classes registered with Blender and can't be used " "directly.\n" "\n" ".. note:: All parameters to these functions must be passed as keywords.\n" | ) |
|
static |
Definition at line 396 of file bpy_props.cc.
References ptr, pyrna_struct_CreatePyObject(), RNA_struct_instance(), and self.
Referenced by bpy_prop_boolean_array_get_fn(), bpy_prop_boolean_array_get_transform_fn(), bpy_prop_boolean_array_set_fn(), bpy_prop_boolean_array_set_transform_fn(), bpy_prop_boolean_get_fn(), bpy_prop_boolean_get_transform_fn(), bpy_prop_boolean_set_fn(), bpy_prop_boolean_set_transform_fn(), bpy_prop_enum_get_fn(), bpy_prop_enum_get_transform_fn(), bpy_prop_enum_itemf_fn(), bpy_prop_enum_set_fn(), bpy_prop_enum_set_transform_fn(), bpy_prop_float_array_get_fn(), bpy_prop_float_array_get_transform_fn(), bpy_prop_float_array_set_fn(), bpy_prop_float_array_set_transform_fn(), bpy_prop_float_get_fn(), bpy_prop_float_get_transform_fn(), bpy_prop_float_set_fn(), bpy_prop_float_set_transform_fn(), bpy_prop_int_array_get_fn(), bpy_prop_int_array_get_transform_fn(), bpy_prop_int_array_set_fn(), bpy_prop_int_array_set_transform_fn(), bpy_prop_int_get_fn(), bpy_prop_int_get_transform_fn(), bpy_prop_int_set_fn(), bpy_prop_int_set_transform_fn(), bpy_prop_pointer_poll_fn(), bpy_prop_string_get_locked_fn(), bpy_prop_string_get_transform_locked_fn(), bpy_prop_string_set_fn(), bpy_prop_string_set_transform_fn(), bpy_prop_string_visit_for_search_fn(), and bpy_prop_update_fn().
|
static |
Definition at line 295 of file bpy_props.cc.
| PyTypeObject bpy_prop_deferred_Type |
Definition at line 309 of file bpy_props.cc.
Referenced by bpy_prop_deferred_data_CreatePyObject(), and BPY_rna_props().
Maintain a list of Python defined properties, so the GC can visit them, and so they can be cleared on exit.
Definition at line 193 of file bpy_props.cc.
Referenced by bpy_prop_py_data_ensure(), bpy_prop_py_data_remove(), BPY_rna_props_clear_all(), props_clear(), and props_visit().
|
static |
Definition at line 5624 of file bpy_props.cc.
|
static |
Definition at line 5712 of file bpy_props.cc.
Referenced by BPY_rna_props().
|
static |
Definition at line 384 of file bpy_props.cc.
Referenced by BPy_BoolProperty().
|
static |
Definition at line 385 of file bpy_props.cc.
Referenced by BPy_BoolVectorProperty().
|
static |
Definition at line 393 of file bpy_props.cc.
Referenced by BPy_CollectionProperty().
|
static |
Definition at line 391 of file bpy_props.cc.
Referenced by BPy_EnumProperty().
|
static |
Definition at line 388 of file bpy_props.cc.
Referenced by BPy_FloatProperty().
|
static |
Definition at line 389 of file bpy_props.cc.
Referenced by BPy_FloatVectorProperty().
|
static |
Definition at line 386 of file bpy_props.cc.
Referenced by BPy_IntProperty().
|
static |
Definition at line 387 of file bpy_props.cc.
Referenced by BPy_IntVectorProperty().
|
static |
Definition at line 392 of file bpy_props.cc.
Referenced by BPy_PointerProperty().
|
static |
Definition at line 394 of file bpy_props.cc.
|
static |
Definition at line 390 of file bpy_props.cc.
Referenced by BPy_StringProperty().