|
Blender V5.0
|
#include "BLI_string_ref.hh"#include "RNA_access.hh"#include "RNA_prototypes.hh"#include "BLT_translation.hh"#include "ANIM_action.hh"#include "UI_interface_layout.hh"#include "interface_intern.hh"#include "interface_templates_intern.hh"Go to the source code of this file.
Classes | |
| struct | TemplateSearch |
Functions | |
| static void | template_search_exec_fn (bContext *C, void *arg_template, void *item) |
| static uiBlock * | template_search_menu (bContext *C, ARegion *region, void *arg_template) |
| static void | template_search_add_button_searchmenu (const bContext *C, uiLayout *layout, uiBlock *block, TemplateSearch &template_search, const bool editable, const bool live_icon) |
| static void | template_search_add_button_name (uiBlock *block, PointerRNA *active_ptr, const StructRNA *type) |
| static void | template_search_add_button_operator (uiBlock *block, const char *const operator_name, const blender::wm::OpCallContext opcontext, const int icon, const bool editable, const std::optional< StringRefNull > button_text={}) |
| static void | template_search_buttons (const bContext *C, uiLayout *layout, TemplateSearch &template_search, const char *newop, const char *unlinkop, const std::optional< StringRef > text) |
| static PropertyRNA * | template_search_get_searchprop (PointerRNA *targetptr, PropertyRNA *targetprop, PointerRNA *searchptr, const char *const searchpropname) |
| static bool | template_search_setup (TemplateSearch &template_search, PointerRNA *ptr, const StringRefNull propname, PointerRNA *searchptr, const char *const searchpropname) |
| void | uiTemplateSearch (uiLayout *layout, const bContext *C, PointerRNA *ptr, const StringRefNull propname, PointerRNA *searchptr, const char *searchpropname, const char *newop, const char *unlinkop, const std::optional< StringRef > text) |
| void | uiTemplateSearchPreview (uiLayout *layout, bContext *C, PointerRNA *ptr, const StringRefNull propname, PointerRNA *searchptr, const char *searchpropname, const char *newop, const char *unlinkop, const int rows, const int cols, const std::optional< StringRef > text) |
|
static |
Definition at line 89 of file interface_template_search.cc.
References PointerRNA::data, ActionSlot::idtype, RNA_struct_find_property(), RNA_struct_name_property(), template_search_textbut_height(), template_search_textbut_width(), UI_icon_from_idcode(), uiDefAutoButR(), and wrap().
Referenced by template_search_buttons().
|
static |
Definition at line 116 of file interface_template_search.cc.
Referenced by template_search_buttons().
|
static |
Definition at line 64 of file interface_template_search.cc.
References but_func_argN_copy(), but_func_argN_free(), C, RNA_property_ui_description(), TemplateSearch::search_data, uiRNACollectionSearch::target_prop, uiRNACollectionSearch::target_ptr, template_add_button_search_menu(), template_search_menu(), and TemplateSearch::use_previews.
Referenced by template_search_buttons().
|
static |
Definition at line 164 of file interface_template_search.cc.
References uiLayout::block(), C, PointerRNA::data, uiLayout::decorator(), IFACE_, blender::wm::InvokeDefault, blender::wm::InvokeRegionWin, RNA_NO_INDEX, RNA_property_editable(), RNA_property_pointer_get(), RNA_property_pointer_type(), uiLayout::row(), TemplateSearch::search_data, uiRNACollectionSearch::target_prop, uiRNACollectionSearch::target_ptr, template_search_add_button_name(), template_search_add_button_operator(), template_search_add_button_searchmenu(), PointerRNA::type, UI_block_align_begin(), UI_block_align_end(), and uiItemL_respect_property_split().
Referenced by uiTemplateSearch(), and uiTemplateSearchPreview().
|
static |
Definition at line 32 of file interface_template_search.cc.
References C, RNA_pointer_create_discrete(), RNA_property_pointer_set(), RNA_property_pointer_type(), RNA_property_update(), TemplateSearch::search_data, uiRNACollectionSearch::target_prop, and uiRNACollectionSearch::target_ptr.
Referenced by template_search_menu().
|
static |
Definition at line 222 of file interface_template_search.cc.
References PointerRNA::data, PROP_COLLECTION, RNA_property_pointer_type(), RNA_property_type(), RNA_struct_find_property(), RNA_struct_identifier(), RNA_warning, and PointerRNA::type.
Referenced by template_search_setup().
Definition at line 43 of file interface_template_search.cc.
References C, PointerRNA::data, TemplateSearch::preview_cols, TemplateSearch::preview_rows, RNA_property_pointer_get(), TemplateSearch::search_data, uiRNACollectionSearch::target_prop, uiRNACollectionSearch::target_ptr, template_common_search_menu(), template_search_exec_fn(), and ui_rna_collection_search_update_fn().
Referenced by template_search_add_button_searchmenu().
|
static |
Definition at line 269 of file interface_template_search.cc.
References blender::StringRefNull::c_str(), PROP_POINTER, ptr, RNA_property_type(), RNA_struct_find_property(), RNA_struct_identifier(), RNA_warning, TemplateSearch::search_data, uiRNACollectionSearch::search_prop, uiRNACollectionSearch::search_ptr, uiRNACollectionSearch::target_prop, uiRNACollectionSearch::target_ptr, and template_search_get_searchprop().
Referenced by uiTemplateSearch(), and uiTemplateSearchPreview().
| void uiTemplateSearch | ( | uiLayout * | layout, |
| const bContext * | C, | ||
| PointerRNA * | ptr, | ||
| blender::StringRefNull | propname, | ||
| PointerRNA * | searchptr, | ||
| const char * | searchpropname, | ||
| const char * | newop, | ||
| const char * | unlinkop, | ||
| std::optional< blender::StringRef > | text = std::nullopt ) |
Search menu to pick an item from a collection. A version of uiTemplateID that works for non-ID types.
Definition at line 293 of file interface_template_search.cc.
References C, ptr, template_search_buttons(), and template_search_setup().
Referenced by nla_panel_actclip(), and nla_panel_animdata().
| void uiTemplateSearchPreview | ( | uiLayout * | layout, |
| bContext * | C, | ||
| PointerRNA * | ptr, | ||
| const StringRefNull | propname, | ||
| PointerRNA * | searchptr, | ||
| const char * | searchpropname, | ||
| const char * | newop, | ||
| const char * | unlinkop, | ||
| const int | rows, | ||
| const int | cols, | ||
| const std::optional< StringRef > | text ) |
Definition at line 309 of file interface_template_search.cc.
References C, TemplateSearch::preview_cols, TemplateSearch::preview_rows, ptr, template_search_buttons(), template_search_setup(), and TemplateSearch::use_previews.