11#include <fmt/format.h>
49#include "RNA_prototypes.hh"
133 std::optional<std::string> path;
166 ot->
name =
"Copy Data Path";
167 ot->
idname =
"UI_OT_copy_data_path_button";
168 ot->
description =
"Copy the RNA data path for this property to the clipboard";
223 bmain, &
ptr, prop, dim, index, &
id))
239 ot->
name =
"Copy as New Driver";
240 ot->
idname =
"UI_OT_copy_as_driver_button";
242 "Create a new driver with this property as input, and copy it to the "
243 "internal clipboard. Use Paste Driver to add it to the target property, "
244 "or Paste Driver Variables to extend an existing driver";
264 if (but && (but->
optype !=
nullptr)) {
275 if (but && (but->
optype !=
nullptr)) {
292 ot->
name =
"Copy Python Command";
293 ot->
idname =
"UI_OT_copy_python_command_button";
294 ot->
description =
"Copy the Python command matching this button";
377 ot->
name =
"Reset to Default Value";
378 ot->
idname =
"UI_OT_reset_default_button";
379 ot->
description =
"Reset this property's value to its default value";
392 ot->
srna,
"all",
true,
"All",
"Reset to default values all elements of the array");
441 ot->
name =
"Assign Value as Default";
442 ot->
idname =
"UI_OT_assign_default_button";
443 ot->
description =
"Set this property's current value as the new default";
483 ot->
name =
"Unset Property";
484 ot->
idname =
"UI_OT_unset_property_button";
485 ot->
description =
"Clear the property and use default or generated value in operators";
516 "'No-Operation', place holder preventing automatic override to ever affect the property"},
521 "Completely replace value from linked data by local one"},
526 "Store difference to linked data value"},
531 "Store factor to linked data value (useful e.g. for scale)"},
532 {0,
nullptr, 0,
nullptr,
nullptr},
592 if (opop ==
nullptr) {
621 ot->
name =
"Define Override Type";
622 ot->
idname =
"UI_OT_override_type_set_button";
623 ot->
description =
"Create an override operation, or set the type of an existing one";
635 ot->
srna,
"all",
true,
"All",
"Reset to default values all elements of the array");
641 "Type of override operation");
673 BLI_assert(
id !=
nullptr && id->override_library !=
nullptr);
679 BLI_assert_msg(0,
"Failed to create matching source (linked data) RNA pointer");
682 if (!all && index != -1) {
687 oprop,
nullptr,
nullptr, {}, {}, index, index,
false, &is_strict_find);
689 if (!is_strict_find) {
696 oprop, opop->
operation,
nullptr,
nullptr, {}, {}, idx, idx,
true,
nullptr,
nullptr);
721 ot->
name =
"Remove Override";
722 ot->
idname =
"UI_OT_override_remove_button";
734 ot->
srna,
"all",
true,
"All",
"Reset to default values all elements of the array");
744 if (owner_ptr.
data ==
nullptr || prop ==
nullptr) {
745 *r_owner_id = *r_id =
nullptr;
746 if (r_owner_ptr !=
nullptr) {
749 if (r_prop !=
nullptr) {
757 *r_id =
static_cast<ID *
>(idptr.
data);
758 if (r_owner_ptr !=
nullptr) {
759 *r_owner_ptr = owner_ptr;
761 if (r_prop !=
nullptr) {
771 if (owner_id ==
nullptr ||
id ==
nullptr) {
800 if (
ELEM(
nullptr, owner_id,
id)) {
807 if (id_override ==
nullptr) {
837 ot->
name =
"Make Library Override";
838 ot->
idname =
"UI_OT_override_idtemplate_make";
840 "Create a local override of the selected linked data-block, and its hierarchy of "
862 if (
ELEM(
nullptr, owner_id,
id)) {
886 ot->
name =
"Reset Library Override";
887 ot->
idname =
"UI_OT_override_idtemplate_reset";
888 ot->
description =
"Reset the selected local override to its linked reference values";
909 if (
ELEM(
nullptr, owner_id,
id)) {
924 bool do_remap_active =
false;
929 do_remap_active =
true;
932 if (do_remap_active) {
935 if (basact !=
nullptr) {
936 view_layer->
basact = basact;
964 ot->
name =
"Clear Library Override";
965 ot->
idname =
"UI_OT_override_idtemplate_clear";
967 "Delete the selected local override and relink its usages to the linked data-block if "
968 "possible, else reset it and mark it as non editable";
984 if (owner_id ==
nullptr ||
id ==
nullptr) {
997 uiItemO(layout,
IFACE_(
"Make"), ICON_NONE,
"UI_OT_override_idtemplate_make");
998 uiItemO(layout,
IFACE_(
"Reset"), ICON_NONE,
"UI_OT_override_idtemplate_reset");
999 uiItemO(layout,
IFACE_(
"Clear"), ICON_NONE,
"UI_OT_override_idtemplate_clear");
1006 mt = MEM_cnew<MenuType>(__func__);
1020#define NOT_NULL(assignment) ((assignment) != nullptr)
1021#define NOT_RNA_NULL(assignment) ((assignment).data != nullptr)
1034 *r_lb = std::move(lb);
1063 bool *r_use_path_from_id,
1064 std::optional<std::string> *r_path)
1066 *r_use_path_from_id =
false;
1067 *r_path = std::nullopt;
1071 bool ensure_list_items_contain_prop =
false;
1083 std::optional<std::string> idpath;
1157 printf(
"BoneColor is unexpectedly owned by %s '%s'\n",
1161 "expected BoneColor to be owned by the Armature "
1162 "(bone & edit bone) or the Object (pose bone)");
1172 *r_lb = list_of_things;
1178 if (
STREQ(prop_id,
"lock")) {
1187 ensure_list_items_contain_prop =
true;
1209 else if (
const std::optional<std::string> path_from_bone =
1214 *r_path = path_from_bone;
1218 std::optional<std::string> path;
1219 bNode *node =
nullptr;
1244 if (node_data->
type != node->type) {
1259 *r_use_path_from_id =
true;
1264 const short id_code =
GS(id->name);
1272 if (
ID *id_data =
static_cast<ID *
>(ob->
data)) {
1280 ID *id_data =
static_cast<ID *
>(ob->
data);
1290 id_data->
tag &= ~ID_TAG_DOIT;
1294 lb = std::move(new_lb);
1305 if (r_path->has_value()) {
1309 if (is_rna &&
STREQ(prop_id,
"lock")) {
1318 ensure_list_items_contain_prop =
true;
1322 return r_path->has_value();
1329 if (!r_path->has_value()) {
1334 ensure_list_items_contain_prop =
true;
1337 if (ensure_list_items_contain_prop) {
1357 &link, r_path->has_value() ? r_path->value().c_str() :
nullptr, &lptr, &lprop);
1359 if (lprop ==
nullptr) {
1386 bool use_path_from_id,
1397 if (use_path_from_id) {
1421 if (lprop ==
nullptr) {
1447 ignore_prop_eq =
false;
1452 ignore_prop_eq =
true;
1456 if ((lprop != prop) && !ignore_prop_eq) {
1492 if (
ptr.
data ==
nullptr || prop ==
nullptr) {
1496 bool success =
false;
1497 std::optional<std::string> path;
1498 bool use_path_from_id;
1510 path.has_value() ? path->c_str() :
nullptr,
1551 ot->
name =
"Copy to Selected";
1552 ot->
idname =
"UI_OT_copy_to_selected_button";
1554 "Copy the property's value from the active item to the same property of all selected items "
1555 "if the same property exists";
1585 if (!path.has_value()) {
1596 if (!is_array_prop) {
1608 for (
int i = 0; i < drivers.
size(); i++) {
1609 if (get_all || i == index) {
1618 bool fetched_at_least_one =
false;
1619 for (
const FCurve *driver : drivers) {
1620 fetched_at_least_one |= driver !=
nullptr;
1622 if (!fetched_at_least_one) {
1626 if (r_is_array_prop) {
1627 *r_is_array_prop = is_array_prop;
1634 const bool is_array_prop,
1643 if (!dst_path.has_value()) {
1652 int paste_count = 0;
1653 for (
int i = 0; i < src_drivers.
size(); i++) {
1654 if (!src_drivers[i]) {
1657 const int dst_index = is_array_prop ? i : -1;
1668 dst_ptr, dst_prop, dst_index,
nullptr,
nullptr, &driven,
nullptr);
1669 if (fcu && !driven) {
1736 copy_entire_array |= index == -1;
1739 bool is_array_prop =
false;
1741 &
ptr, prop, copy_entire_array, index, &is_array_prop);
1748 std::optional<std::string> path;
1749 bool use_path_from_id;
1752 C, &
ptr, prop, &target_properties, &use_path_from_id, &path))
1758 int total_copy_count = 0;
1759 for (
PointerRNA &target_prop : target_properties) {
1760 if (target_prop.data ==
ptr.
data) {
1771 path.has_value() ? path->c_str() :
nullptr,
1788 const int paste_count = paste_property_drivers(
1789 src_drivers.
as_span(), is_array_prop, &dst_ptr, dst_prop);
1790 if (paste_count == 0) {
1795 total_copy_count += paste_count;
1798 return total_copy_count > 0;
1822 ot->
name =
"Copy Driver to Selected";
1823 ot->
idname =
"UI_OT_copy_driver_to_selected_button";
1825 "Copy the property's driver from the active item to the same property "
1826 "of all selected items, if the same property exists";
1837 ot->
srna,
"all",
false,
"All",
"Copy to selected the drivers of all elements of the array");
1857 if (
ELEM(
ptr.
type, &RNA_EditBone, &RNA_PoseBone, &RNA_Bone)) {
1859 if (bone_name[0] !=
'\0') {
1860 target_type = &RNA_Bone;
1864 target_type = &RNA_Object;
1867 if (target_type ==
nullptr) {
1874 Base *base =
nullptr;
1876 if (id_type ==
ID_OB) {
1893 const bool reveal_hidden =
true;
1895 if (target_type == &RNA_Bone) {
1898 else if (target_type == &RNA_Object) {
1943 &
ptr, prop, str_buf,
sizeof(str_buf),
nullptr);
1953 if (str_ptr != str_buf) {
1982 ot->
name =
"Jump to Target";
1983 ot->
idname =
"UI_OT_jump_to_target_button";
2006struct uiEditSourceStore {
2011struct uiEditSourceButStore {
2013 int py_dbg_line_number;
2017static uiEditSourceStore *ui_editsource_info =
nullptr;
2021 return (ui_editsource_info !=
nullptr);
2024static void ui_editsource_active_but_set(
uiBut *but)
2028 ui_editsource_info = MEM_new<uiEditSourceStore>(__func__);
2029 ui_editsource_info->but_orig = *but;
2034static void ui_editsource_active_but_clear()
2037 MEM_delete(ui_editsource_info);
2038 ui_editsource_info =
nullptr;
2041static bool ui_editsource_uibut_match(
uiBut *but_a,
uiBut *but_b)
2064 uiEditSourceButStore *but_store = MEM_cnew<uiEditSourceButStore>(__func__);
2067 int line_number = -1;
2070 printf(
"comparing buttons: '%s' == '%s'\n", but->
drawstr, ui_editsource_info->but_orig.drawstr);
2075 if (line_number != -1) {
2076 STRNCPY(but_store->py_dbg_fn, fn);
2077 but_store->py_dbg_line_number = line_number;
2080 but_store->py_dbg_fn[0] =
'\0';
2081 but_store->py_dbg_line_number = -1;
2089 uiEditSourceButStore *but_store =
static_cast<uiEditSourceButStore *
>(
2097static int editsource_text_edit(
bContext *C,
2121 uiEditSourceButStore *but_store =
nullptr;
2132 ui_editsource_active_but_set(but);
2142 if (but_key && ui_editsource_uibut_match(&ui_editsource_info->but_orig, but_key)) {
2149 if (but_store->py_dbg_line_number != -1) {
2150 ret = editsource_text_edit(C, op, but_store->py_dbg_fn, but_store->py_dbg_line_number);
2154 op->
reports,
RPT_ERROR,
"Active button is not from a script, cannot edit source");
2163 ui_editsource_active_but_clear();
2177 ot->
name =
"Edit Source";
2179 ot->
description =
"Edit UI source code of the active button";
2182 ot->
exec = editsource_exec;
2205 ot->
name =
"Reload Translation";
2206 ot->
idname =
"UI_OT_reloadtranslation";
2226 if (region ==
nullptr) {
2227 region = region_prev;
2230 if (region ==
nullptr) {
2238 if (but ==
nullptr) {
2247 void *but_optype = but->
optype;
2260 ot->
name =
"Press Button";
2261 ot->
idname =
"UI_OT_button_execute";
2289 ot->
name =
"Clear Button String";
2290 ot->
idname =
"UI_OT_button_string_clear";
2337 uiBut *but =
nullptr;
2353 if (color_len == 4) {
2401 ot->
srna,
"color", 3,
nullptr, 0.0,
FLT_MAX,
"Color",
"Source color", 0.0, 1.0);
2403 ot->
srna,
"gamma",
false,
"Gamma Corrected",
"The source color is gamma corrected");
2454 ot->
srna,
"string",
nullptr, 0,
"String",
"The string value to drop into the button");
2472 return list !=
nullptr;
2510 ot->
name =
"List Filter";
2511 ot->
idname =
"UI_OT_list_start_filter";
2512 ot->
description =
"Start entering filter text for the list in focus";
2541 return view !=
nullptr;
2558 ot->
name =
"View Filter";
2559 ot->
idname =
"UI_OT_view_start_filter";
2560 ot->
description =
"Start entering filter text for the data-set in focus";
2581 if (region ==
nullptr) {
2598 *C, *region, *event, *drop_target, *
static_cast<const ListBase *
>(event->
customdata)))
2611 ot->
description =
"Drag and drop onto a data-set or item within the data-set";
2632 return view->supports_scrolling();
2638 int type =
event->type;
2639 bool invert_direction =
false;
2647 invert_direction =
true;
2652 std::optional<ViewScrollDirection> direction =
2653 [type, invert_direction]() -> std::optional<ViewScrollDirection> {
2656 return invert_direction ? ViewScrollDirection::DOWN : ViewScrollDirection::UP;
2658 return invert_direction ? ViewScrollDirection::UP : ViewScrollDirection::DOWN;
2660 return std::nullopt;
2668 view->scroll(*direction);
2676 ot->
name =
"View Scroll";
2699 if (region ==
nullptr) {
2719 ot->
name =
"Rename View Item";
2720 ot->
idname =
"UI_OT_view_item_rename";
2721 ot->
description =
"Rename the active item in the data-set view";
2741 if (ob ==
nullptr) {
2759 if (ma ==
nullptr) {
2769 const int target_slot =
RNA_int_get(&mat_slot,
"slot_index") + 1;
2788 ot->
name =
"Drop Material in Material slots";
2789 ot->
description =
"Drag material to Material slots in Properties";
2790 ot->
idname =
"UI_OT_drop_material";
AnimData * BKE_animdata_ensure_id(ID *id)
AnimData * BKE_animdata_from_id(const ID *id)
blender::Vector< PointerRNA > CTX_data_collection_get(const bContext *C, const char *member)
PointerRNA CTX_data_pointer_get_type_silent(const bContext *C, const char *member, StructRNA *type)
SpaceImage * CTX_wm_space_image(const bContext *C)
bScreen * CTX_wm_screen(const bContext *C)
PointerRNA CTX_data_pointer_get_type(const bContext *C, const char *member, StructRNA *type)
wmWindow * CTX_wm_window(const bContext *C)
Scene * CTX_data_scene(const bContext *C)
Main * CTX_data_main(const bContext *C)
void CTX_data_collection_remap_property(blender::MutableSpan< PointerRNA > collection_pointers, const char *propname)
void CTX_wm_region_set(bContext *C, ARegion *region)
ARegion * CTX_wm_region(const bContext *C)
ViewLayer * CTX_data_view_layer(const bContext *C)
FCurve * BKE_fcurve_copy(const FCurve *fcu)
FCurve * BKE_fcurve_find(ListBase *list, const char rna_path[], int array_index)
FCurve * BKE_fcurve_find_by_rna(PointerRNA *ptr, PropertyRNA *prop, int rnaindex, AnimData **r_adt, bAction **r_action, bool *r_driven, bool *r_special)
void BKE_fcurve_rnapath_set(FCurve &fcu, blender::StringRef rna_path)
void BKE_fcurve_free(FCurve *fcu)
const char * BKE_idtype_idcode_to_name(short idcode)
void BKE_view_layer_synced_ensure(const Scene *scene, ViewLayer *view_layer)
Object * BKE_view_layer_active_object_get(const ViewLayer *view_layer)
Base * BKE_view_layer_base_find(ViewLayer *view_layer, Object *ob)
void BKE_id_delete(Main *bmain, void *idv) ATTR_NONNULL()
void BKE_lib_override_library_property_operation_delete(IDOverrideLibraryProperty *liboverride_property, IDOverrideLibraryPropertyOperation *liboverride_property_operation)
IDOverrideLibraryPropertyOperation * BKE_lib_override_library_property_operation_get(IDOverrideLibraryProperty *liboverride_property, short operation, const char *subitem_refname, const char *subitem_locname, const std::optional< ID * > &subitem_refid, const std::optional< ID * > &subitem_locid, int subitem_refindex, int subitem_locindex, bool strict, bool *r_strict, bool *r_created)
IDOverrideLibraryPropertyOperation * BKE_lib_override_library_property_operation_find(IDOverrideLibraryProperty *liboverride_property, const char *subitem_refname, const char *subitem_locname, const std::optional< const ID * > &subitem_refid, const std::optional< const ID * > &subitem_locid, int subitem_refindex, int subitem_locindex, bool strict, bool *r_strict)
void BKE_lib_override_library_id_reset(Main *bmain, ID *id_root, bool do_reset_system_override)
bool BKE_lib_override_library_is_hierarchy_leaf(Main *bmain, ID *id)
void BKE_lib_override_library_property_delete(IDOverrideLibrary *liboverride, IDOverrideLibraryProperty *liboverride_property)
@ ID_REMAP_SKIP_INDIRECT_USAGE
void void BKE_libblock_remap(Main *bmain, void *old_idv, void *new_idv, int remap_flags) ATTR_NONNULL(1
General operations, lookup, etc. for materials.
void BKE_object_material_assign(struct Main *bmain, struct Object *ob, struct Material *ma, short act, int assign_type)
@ BKE_MAT_ASSIGN_USERPREF
void BKE_reportf(ReportList *reports, eReportType type, const char *format,...) ATTR_PRINTF_FORMAT(3
void BKE_report(ReportList *reports, eReportType type, const char *message)
ARegion * BKE_screen_find_region_xy(const bScreen *screen, int regiontype, const int xy[2]) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1
#define BLI_assert_msg(a, msg)
BLI_INLINE void * BLI_ghashIterator_getKey(GHashIterator *ghi) ATTR_WARN_UNUSED_RESULT
void BLI_ghashIterator_step(GHashIterator *ghi)
BLI_INLINE void * BLI_ghashIterator_getValue(GHashIterator *ghi) ATTR_WARN_UNUSED_RESULT
GHash * BLI_ghash_ptr_new(const char *info) ATTR_MALLOC ATTR_WARN_UNUSED_RESULT
bool BLI_ghash_remove(GHash *gh, const void *key, GHashKeyFreeFP keyfreefp, GHashValFreeFP valfreefp)
void * BLI_ghash_lookup(const GHash *gh, const void *key) ATTR_WARN_UNUSED_RESULT
void BLI_ghash_insert(GHash *gh, void *key, void *val)
void BLI_ghash_free(GHash *gh, GHashKeyFreeFP keyfreefp, GHashValFreeFP valfreefp)
void BLI_ghashIterator_init(GHashIterator *ghi, GHash *gh)
BLI_INLINE bool BLI_ghashIterator_done(const GHashIterator *ghi) ATTR_WARN_UNUSED_RESULT
BLI_INLINE bool BLI_listbase_is_empty(const struct ListBase *lb)
#define LISTBASE_FOREACH(type, var, list)
void BLI_addtail(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
void BLI_remlink(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
void srgb_to_linearrgb_v3_v3(float linear[3], const float srgb[3])
bool BLI_rctf_compare(const struct rctf *rect_a, const struct rctf *rect_b, float limit)
#define STRNCPY(dst, src)
void BLT_lang_set(const char *)
void DEG_id_tag_update(ID *id, unsigned int flags)
void DEG_relations_tag_update(Main *bmain)
#define ID_IS_OVERRIDE_LIBRARY_REAL(_id)
#define ID_CHECK_UNDO(id)
#define ID_IS_LINKED(_id)
#define ID_IS_EDITABLE(_id)
@ LIBOVERRIDE_OP_MULTIPLY
Object is a sort of wrapper for general info.
#define OB_DATA_SUPPORT_ID(_id_type)
void ED_imapaint_bucket_fill(bContext *C, const float color[3], wmOperator *op, const int mouse[2])
bool ED_operator_regionactive(bContext *C)
void ED_region_do_layout(bContext *C, ARegion *region)
void ED_region_do_draw(bContext *C, ARegion *region)
void ED_region_tag_redraw(ARegion *region)
void ED_undo_push(bContext *C, const char *str)
BLI_INLINE void IMB_colormanagement_srgb_to_scene_linear_v3(float scene_linear[3], const float srgb[3])
BLI_INLINE void IMB_colormanagement_scene_linear_to_srgb_v3(float srgb[3], const float scene_linear[3])
Read Guarded memory(de)allocation.
@ RNA_OVERRIDE_STATUS_OVERRIDABLE
@ RNA_OVERRIDE_STATUS_OVERRIDDEN
constexpr PointerRNA PointerRNA_NULL
bool UI_view_item_can_rename(const blender::ui::AbstractViewItem &item)
bool UI_textbutton_activate_rna(const bContext *C, ARegion *region, const void *rna_poin_data, const char *rna_prop_id)
uiList * UI_list_find_mouse_over(const ARegion *region, const wmEvent *event)
blender::ui::AbstractView * UI_region_view_find_at(const ARegion *region, const int xy[2], int pad)
bool UI_editsource_enable_check()
uiBut * UI_context_active_but_get(const bContext *C)
void UI_editsource_but_replace(const uiBut *old_but, uiBut *new_but)
void UI_but_execute(const bContext *C, ARegion *region, uiBut *but)
void UI_view_item_begin_rename(blender::ui::AbstractViewItem &item)
void UI_editsource_active_but_test(uiBut *but)
blender::ui::AbstractViewItem * UI_region_views_find_active_item(const ARegion *region)
uiBut * UI_context_active_but_prop_get(const bContext *C, PointerRNA *r_ptr, PropertyRNA **r_prop, int *r_index)
PointerRNA * UI_but_operator_ptr_ensure(uiBut *but)
void uiItemO(uiLayout *layout, const char *name, int icon, const char *opname)
uiBut * UI_but_active_drop_name_button(const bContext *C)
uiBut * UI_context_active_but_get_respect_popup(const bContext *C)
void UI_context_active_but_prop_get_templateID(const bContext *C, PointerRNA *r_ptr, PropertyRNA **r_prop)
void UI_context_active_but_prop_handle(bContext *C, bool handle_undo)
bool UI_but_active_drop_color(bContext *C)
void UI_screen_free_active_but_highlight(const bContext *C, bScreen *screen)
bool UI_but_flag_is_set(uiBut *but, int flag)
#define ND_LIB_OVERRIDE_CHANGED
constexpr int64_t size() const
int64_t remove_if(Predicate &&predicate)
void append(const T &value)
void resize(const int64_t new_size)
Span< T > as_span() const
virtual bool begin_filtering(const bContext &C) const
void ANIM_copy_as_driver(ID *target_id, const char *target_path, const char *var_name)
void UI_OT_eyedropper_color(wmOperatorType *ot)
void UI_OT_eyedropper_id(wmOperatorType *ot)
void UI_OT_eyedropper_depth(wmOperatorType *ot)
void UI_OT_eyedropper_driver(wmOperatorType *ot)
void UI_OT_eyedropper_grease_pencil_color(wmOperatorType *ot)
wmKeyMap * eyedropper_colorband_modal_keymap(wmKeyConfig *keyconf)
wmKeyMap * eyedropper_modal_keymap(wmKeyConfig *keyconf)
void ui_but_active_string_clear_and_exit(bContext *C, uiBut *but)
void ui_pan_to_scroll(const wmEvent *event, int *type, int *val)
void ui_but_set_string_interactive(bContext *C, uiBut *but, const char *value)
ID * ui_template_id_liboverride_hierarchy_make(bContext *C, Main *bmain, ID *owner_id, ID *id, const char **r_undo_push_label)
uiBut * ui_region_find_active_but(ARegion *region) ATTR_WARN_UNUSED_RESULT
void ui_rna_collection_search_update_fn(const bContext *C, void *arg, const char *str, uiSearchItems *items, bool is_first)
static bool ui_list_unhide_filter_options(uiList *list)
static void UI_OT_override_type_set_button(wmOperatorType *ot)
static int copy_to_selected_button_exec(bContext *C, wmOperator *op)
static bool override_type_set_button_poll(bContext *C)
static void UI_OT_override_idtemplate_reset(wmOperatorType *ot)
static void override_idtemplate_ids_get(bContext *C, ID **r_owner_id, ID **r_id, PointerRNA *r_owner_ptr, PropertyRNA **r_prop)
static void UI_OT_unset_property_button(wmOperatorType *ot)
static int assign_default_button_exec(bContext *C, wmOperator *)
static bool ui_view_focused_poll(bContext *C)
static bool ui_list_focused_poll(bContext *C)
static void UI_OT_button_execute(wmOperatorType *ot)
static bool override_remove_button_poll(bContext *C)
static bool ui_view_drop_poll(bContext *C)
static int ui_view_scroll_invoke(bContext *C, wmOperator *, const wmEvent *event)
@ UIOverride_Type_Replace
@ UIOverride_Type_Difference
static void ui_region_redraw_immediately(bContext *C, ARegion *region)
static int override_type_set_button_exec(bContext *C, wmOperator *op)
static int override_idtemplate_clear_exec(bContext *C, wmOperator *)
static bool reset_default_button_poll(bContext *C)
static int operator_button_property_finish(bContext *C, PointerRNA *ptr, PropertyRNA *prop)
static int copy_driver_to_selected_button_exec(bContext *C, wmOperator *op)
static bool override_idtemplate_menu_poll(const bContext *C_const, MenuType *)
static int button_string_clear_exec(bContext *C, wmOperator *)
static int ui_button_press_invoke(bContext *C, wmOperator *op, const wmEvent *event)
static bool copy_driver_to_selected_button_poll(bContext *C)
static void UI_OT_copy_data_path_button(wmOperatorType *ot)
static void UI_OT_reloadtranslation(wmOperatorType *ot)
static int reset_default_button_exec(bContext *C, wmOperator *op)
bool ui_jump_to_target_button_poll(bContext *C)
static int unset_property_button_exec(bContext *C, wmOperator *)
static int ui_list_start_filter_invoke(bContext *C, wmOperator *, const wmEvent *event)
static int copy_python_command_button_exec(bContext *C, wmOperator *)
static bool copy_data_path_button_poll(bContext *C)
static void UI_OT_copy_python_command_button(wmOperatorType *ot)
static void UI_OT_assign_default_button(wmOperatorType *ot)
static bool ui_view_scroll_poll(bContext *C)
static void UI_OT_override_idtemplate_clear(wmOperatorType *ot)
void ED_operatortypes_ui()
bool UI_drop_color_poll(bContext *C, wmDrag *drag, const wmEvent *)
static void UI_OT_list_start_filter(wmOperatorType *ot)
static bool copy_driver_to_selected_button(bContext *C, bool copy_entire_array, const bool poll)
static bool copy_to_selected_button_poll(bContext *C)
static int override_type_set_button_invoke(bContext *C, wmOperator *op, const wmEvent *)
static int override_idtemplate_reset_exec(bContext *C, wmOperator *)
static bool copy_to_selected_button(bContext *C, bool all, bool poll)
static int override_idtemplate_make_exec(bContext *C, wmOperator *)
void UI_drop_color_copy(bContext *, wmDrag *drag, wmDropBox *drop)
static AbstractView * get_view_focused(bContext *C)
static void UI_OT_view_start_filter(wmOperatorType *ot)
static void UI_OT_jump_to_target_button(wmOperatorType *ot)
static void UI_OT_drop_name(wmOperatorType *ot)
static void UI_OT_copy_to_selected_button(wmOperatorType *ot)
static int ui_view_item_rename_exec(bContext *C, wmOperator *)
static int ui_view_start_filter_invoke(bContext *C, wmOperator *, const wmEvent *event)
static void UI_OT_copy_driver_to_selected_button(wmOperatorType *ot)
static int override_remove_button_exec(bContext *C, wmOperator *op)
static int drop_name_invoke(bContext *C, wmOperator *op, const wmEvent *)
static void override_idtemplate_menu_draw(const bContext *, Menu *menu)
static void UI_OT_drop_material(wmOperatorType *ot)
static void UI_OT_view_scroll(wmOperatorType *ot)
static bool override_idtemplate_reset_poll(bContext *C)
static bool jump_to_target_button(bContext *C, bool poll)
static void UI_OT_override_remove_button(wmOperatorType *ot)
static void UI_OT_button_string_clear(wmOperatorType *ot)
static bool drop_name_poll(bContext *C)
bool UI_context_copy_to_selected_list(bContext *C, PointerRNA *ptr, PropertyRNA *prop, blender::Vector< PointerRNA > *r_lb, bool *r_use_path_from_id, std::optional< std::string > *r_path)
#define NOT_RNA_NULL(assignment)
static bool copy_python_command_button_poll(bContext *C)
static int copy_data_path_button_exec(bContext *C, wmOperator *op)
static void UI_OT_reset_default_button(wmOperatorType *ot)
void ED_keymap_ui(wmKeyConfig *keyconf)
User Interface Keymap.
static void UI_OT_override_idtemplate_make(wmOperatorType *ot)
static bool assign_default_button_poll(bContext *C)
static int ui_drop_material_exec(bContext *C, wmOperator *op)
static void UI_OT_view_drop(wmOperatorType *ot)
static void UI_OT_copy_as_driver_button(wmOperatorType *ot)
static int drop_color_invoke(bContext *C, wmOperator *op, const wmEvent *event)
static bool jump_to_target_ptr(bContext *C, PointerRNA ptr, const bool poll)
static bool override_idtemplate_clear_poll(bContext *C)
static EnumPropertyItem override_type_items[]
static int copy_as_driver_button_exec(bContext *C, wmOperator *op)
static void ui_context_fcurve_modifiers_via_fcurve(bContext *C, blender::Vector< PointerRNA > *r_lb, FModifier *source)
static bool ui_drop_material_poll(bContext *C)
static int reloadtranslation_exec(bContext *, wmOperator *)
static bool copy_as_driver_button_poll(bContext *C)
static int operator_button_property_finish_with_undo(bContext *C, PointerRNA *ptr, PropertyRNA *prop)
static int jump_to_target_button_exec(bContext *C, wmOperator *)
static void override_idtemplate_menu()
static void UI_OT_drop_color(wmOperatorType *ot)
bool UI_context_copy_to_selected_check(PointerRNA *ptr, PointerRNA *ptr_link, PropertyRNA *prop, const char *path, bool use_path_from_id, PointerRNA *r_ptr, PropertyRNA **r_prop)
static bool ui_view_item_rename_poll(bContext *C)
static void UI_OT_view_item_rename(wmOperatorType *ot)
static int ui_view_drop_invoke(bContext *C, wmOperator *, const wmEvent *event)
static bool override_idtemplate_make_poll(bContext *C)
static bool override_idtemplate_poll(bContext *C, const bool is_create_op)
static void ui_context_selected_bones_via_pose(bContext *C, blender::Vector< PointerRNA > *r_lb)
void MEM_freeN(void *vmemh)
bool node_find_node_try(bNodeTree *ntree, bNodeSocket *sock, bNode **r_node, int *r_sockindex)
bool jump_to_object(bContext *C, Object *ob, bool reveal_hidden)
Base * find_first_by_data_id(const Scene *scene, ViewLayer *view_layer, ID *id)
bool jump_to_bone(bContext *C, Object *ob, const char *bone_name, bool reveal_hidden)
blender::Vector< FCurve * > get_property_drivers(PointerRNA *ptr, PropertyRNA *prop, bool get_all, int index, bool *r_is_array_prop)
int paste_property_drivers(blender::Span< FCurve * > src_drivers, bool is_array_prop, PointerRNA *dst_ptr, PropertyRNA *dst_prop)
void UI_OT_eyedropper_colorramp(wmOperatorType *ot)
void UI_OT_eyedropper_colorramp_point(wmOperatorType *ot)
bool drop_target_apply_drop(bContext &C, const ARegion ®ion, const wmEvent &event, const DropTargetInterface &drop_target, const ListBase &drags)
void UI_OT_eyedropper_bone(wmOperatorType *ot)
std::unique_ptr< DropTargetInterface > region_views_find_drop_target_at(const ARegion *region, const int xy[2])
void PyC_FileAndNum_Safe(const char **r_filename, int *r_lineno)
PropertyRNA * RNA_struct_type_find_property(StructRNA *srna, const char *identifier)
bool RNA_property_array_check(PropertyRNA *prop)
bool RNA_struct_is_a(const StructRNA *type, const StructRNA *srna)
bool RNA_property_assign_default(PointerRNA *ptr, PropertyRNA *prop)
void RNA_string_set(PointerRNA *ptr, const char *name, const char *value)
bool RNA_property_reset(PointerRNA *ptr, PropertyRNA *prop, int index)
float RNA_property_float_get_index(PointerRNA *ptr, PropertyRNA *prop, int index)
void RNA_property_pointer_set(PointerRNA *ptr, PropertyRNA *prop, PointerRNA ptr_value, ReportList *reports)
void RNA_boolean_set(PointerRNA *ptr, const char *name, bool value)
bool RNA_property_is_set(PointerRNA *ptr, PropertyRNA *prop)
PropertyType RNA_property_type(PropertyRNA *prop)
char * RNA_property_string_get_alloc(PointerRNA *ptr, PropertyRNA *prop, char *fixedbuf, int fixedlen, int *r_len)
void RNA_int_set(PointerRNA *ptr, const char *name, int value)
PointerRNA RNA_property_pointer_get(PointerRNA *ptr, PropertyRNA *prop)
void RNA_float_get_array(PointerRNA *ptr, const char *name, float *values)
void RNA_property_update(bContext *C, PointerRNA *ptr, PropertyRNA *prop)
void RNA_string_get(PointerRNA *ptr, const char *name, char *value)
int RNA_int_get(PointerRNA *ptr, const char *name)
int RNA_property_array_dimension(const PointerRNA *ptr, PropertyRNA *prop, int length[])
char * RNA_string_get_alloc(PointerRNA *ptr, const char *name, char *fixedbuf, int fixedlen, int *r_len)
bool RNA_pointer_is_null(const PointerRNA *ptr)
int RNA_property_array_length(PointerRNA *ptr, PropertyRNA *prop)
const char * RNA_property_ui_name(const PropertyRNA *prop)
bool RNA_property_is_idprop(const PropertyRNA *prop)
bool RNA_property_editable(const PointerRNA *ptr, PropertyRNA *prop)
void RNA_property_float_set_array(PointerRNA *ptr, PropertyRNA *prop, const float *values)
PropertySubType RNA_property_subtype(PropertyRNA *prop)
bool RNA_boolean_get(PointerRNA *ptr, const char *name)
bool RNA_property_collection_lookup_string(PointerRNA *ptr, PropertyRNA *prop, const char *key, PointerRNA *r_ptr)
bool RNA_property_driver_editable(const PointerRNA *ptr, PropertyRNA *prop)
void RNA_enum_set(PointerRNA *ptr, const char *name, int value)
void RNA_float_set_array(PointerRNA *ptr, const char *name, const float *values)
PointerRNA RNA_pointer_create(ID *id, StructRNA *type, void *data)
int RNA_enum_get(PointerRNA *ptr, const char *name)
void RNA_property_unset(PointerRNA *ptr, PropertyRNA *prop)
const char * RNA_property_identifier(const PropertyRNA *prop)
PointerRNA RNA_id_pointer_create(ID *id)
IDOverrideLibraryPropertyOperation * RNA_property_override_property_operation_get(Main *bmain, PointerRNA *ptr, PropertyRNA *prop, const short operation, const int index, const bool strict, bool *r_strict, bool *r_created)
IDOverrideLibraryProperty * RNA_property_override_property_find(Main *bmain, PointerRNA *ptr, PropertyRNA *prop, ID **r_owner_id)
eRNAOverrideStatus RNA_property_override_library_status(Main *bmain, PointerRNA *ptr, PropertyRNA *prop, const int index)
bool RNA_property_copy(Main *bmain, PointerRNA *ptr, PointerRNA *fromptr, PropertyRNA *prop, int index)
PropertyRNA * RNA_def_string(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, const int maxlen, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_float_color(StructOrFunctionRNA *cont_, const char *identifier, const int len, const float *default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
PropertyRNA * RNA_def_enum(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, const int default_value, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, const bool default_value, const char *ui_name, const char *ui_description)
void RNA_def_property_flag(PropertyRNA *prop, PropertyFlag flag)
StructRNA RNA_PropertyGroup
std::optional< std::string > RNA_path_from_struct_to_idproperty(PointerRNA *ptr, const IDProperty *needle)
std::optional< std::string > RNA_path_from_real_ID_to_property_index(Main *bmain, const PointerRNA *ptr, PropertyRNA *prop, int index_dim, int index, ID **r_real_id)
std::optional< std::string > RNA_path_full_property_py_ex(const PointerRNA *ptr, PropertyRNA *prop, int index, bool use_fallback)
std::optional< std::string > RNA_path_resolve_from_type_to_property(const PointerRNA *ptr, PropertyRNA *prop, const StructRNA *type)
std::optional< std::string > RNA_path_full_struct_py(const PointerRNA *ptr)
std::optional< std::string > RNA_path_from_ID_to_property_index(const PointerRNA *ptr, PropertyRNA *prop, int index_dim, int index)
std::optional< std::string > RNA_path_from_ID_to_property(const PointerRNA *ptr, PropertyRNA *prop)
bool RNA_path_resolve_property(const PointerRNA *ptr, const char *path, PointerRNA *r_ptr, PropertyRNA **r_prop)
std::string RNA_path_from_ptr_to_property_index(const PointerRNA *ptr, PropertyRNA *prop, int index_dim, int index)
IDOverrideLibrary * override_library
struct MaterialGPencilStyle * gp_style
struct bNodeTree * node_group
uiButSearchUpdateFn items_update_fn
PropertyRNA * search_prop
bool(* poll)(bContext *C) ATTR_WARN_UNUSED_RESULT
int(* invoke)(bContext *C, wmOperator *op, const wmEvent *event) ATTR_WARN_UNUSED_RESULT
int(* exec)(bContext *C, wmOperator *op) ATTR_WARN_UNUSED_RESULT
struct ReportList * reports
struct wmEvent * eventstate
ccl_device_inline int mod(int x, int m)
void WM_draw_region_viewport_unbind(ARegion *region)
void WM_draw_region_viewport_bind(ARegion *region)
void WM_main_add_notifier(uint type, void *reference)
int WM_operator_name_call_ptr(bContext *C, wmOperatorType *ot, wmOperatorCallContext context, PointerRNA *properties, const wmEvent *event)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)
void WM_event_add_mousemove(wmWindow *win)
wmKeyMap * WM_keymap_ensure(wmKeyConfig *keyconf, const char *idname, int spaceid, int regionid)
ID * WM_operator_properties_id_lookup_from_name_or_session_uid(Main *bmain, PointerRNA *ptr, const ID_Type type)
void WM_operator_properties_id_lookup(wmOperatorType *ot, const bool add_name_prop)
void WM_operatortype_append(void(*opfunc)(wmOperatorType *))
wmOperatorType * WM_operatortype_find(const char *idname, bool quiet)
int WM_menu_invoke_ex(bContext *C, wmOperator *op, wmOperatorCallContext opcontext)
std::string WM_operator_pystring_ex(bContext *C, wmOperator *op, const bool all_args, const bool macro_args, wmOperatorType *ot, PointerRNA *opptr)
void WM_operator_properties_create_ptr(PointerRNA *ptr, wmOperatorType *ot)
void WM_operator_properties_free(PointerRNA *ptr)
void WM_clipboard_text_set(const char *buf, bool selection)