Blender V4.3
uiBut Struct Reference

#include <interface_intern.hh>

Inherited by uiButColor, uiButColorBand, uiButCurveMapping, uiButCurveProfile, uiButDecorator, uiButHSVCube, uiButHotkeyEvent, uiButLabel, uiButNumber, uiButNumberSlider, uiButProgress, uiButScrollBar, uiButSearch, uiButSeparatorLine, uiButTab, and uiButViewItem.

Public Member Functions

 uiBut ()=default
 uiBut (const uiBut &other)=default
uiButoperator= (const uiBut &other)=default

Public Attributes

uiButnext = nullptr
uiButprev = nullptr
uiLayoutlayout = nullptr
int flag = 0
int flag2 = 0
int drawflag = 0
eButType type = eButType(0)
eButPointerType pointype = UI_BUT_POIN_NONE
short bit = 0
short bitnr = 0
short retval = 0
short strwidth = 0
short alignnr = 0
short ofs = 0
short pos = 0
short selsta = 0
short selend = 0
std::string str
std::string drawstr
char * placeholder = nullptr
rctf rect = {}
char * poin = nullptr
float hardmin = 0
float hardmax = 0
float softmin = 0
float softmax = 0
uchar col [4] = {0}
uiButIdentityCompareFunc identity_cmp_func = nullptr
uiButHandleFunc func = nullptr
void * func_arg1 = nullptr
void * func_arg2 = nullptr
std::function< void(bContext &)> apply_func
uiButHandleNFunc funcN = nullptr
void * func_argN = nullptr
uiButArgNFree func_argN_free_fn
uiButArgNCopy func_argN_copy_fn
const bContextStorecontext = nullptr
uiButCompleteFunc autocomplete_func = nullptr
void * autofunc_arg = nullptr
uiButHandleRenameFunc rename_func = nullptr
void * rename_arg1 = nullptr
void * rename_orig = nullptr
std::function< void(std::string &new_name)> rename_full_func = nullptr
std::string rename_full_new = ""
uiButHandleHoldFunc hold_func = nullptr
void * hold_argN = nullptr
const char * tip = nullptr
uiButToolTipFunc tip_func = nullptr
void * tip_arg = nullptr
uiFreeArgFunc tip_arg_free = nullptr
std::function< std::string(const uiBut *)> tip_label_func
uiButToolTipCustomFunc tip_custom_func = nullptr
const char * disabled_info = nullptr
BIFIconID icon = ICON_NONE
eUIEmbossType emboss = UI_EMBOSS
RadialDirection pie_dir = UI_RADIAL_NONE
bool changed = false
uchar unit_type = 0
short iconadd = 0
float search_weight = 0.0f
uiBlockCreateFunc block_create_func = nullptr
uiMenuCreateFunc menu_create_func = nullptr
uiMenuStepFunc menu_step_func = nullptr
PointerRNA rnapoin = {}
PropertyRNArnaprop = nullptr
int rnaindex = 0
wmOperatorTypeoptype = nullptr
PointerRNAopptr = nullptr
wmOperatorCallContext opcontext = WM_OP_INVOKE_DEFAULT
bool operator_never_call = false
uchar menu_key = 0
ListBase extra_op_icons = {nullptr, nullptr}
eWM_DragDataType dragtype = WM_DRAG_ID
short dragflag = 0
void * dragpoin = nullptr
const ImBufimb = nullptr
float imb_scale = 0
uiHandleButtonDataactive = nullptr
uiHandleButtonDatasemi_modal_state = nullptr
void * custom_data = nullptr
char * editstr = nullptr
doubleeditval = nullptr
floateditvec = nullptr
std::function< bool(const uiBut &)> pushed_state_func
IconTextOverlay icon_overlay_text = {}
uiBlockblock = nullptr

Detailed Description

Definition at line 174 of file interface_intern.hh.

Constructor & Destructor Documentation

◆ uiBut() [1/2]

uiBut::uiBut ( )
default

Referenced by operator=(), and uiBut().

◆ uiBut() [2/2]

uiBut::uiBut ( const uiBut & other)
default

Performs a mostly shallow copy for now. Only contained C++ types are deep copied.

References uiBut().

Member Function Documentation

◆ operator=()

uiBut & uiBut::operator= ( const uiBut & other)
default

Mostly shallow copy, just like copy constructor above.

References uiBut().

Member Data Documentation

◆ active

uiHandleButtonData* uiBut::active = nullptr

Active button data, set when the user is hovering or interacting with a button (UI_HOVER and UI_SELECT state mostly).

Definition at line 303 of file interface_intern.hh.

Referenced by button_activate_exit(), button_activate_init(), button_activate_state(), button_tooltip_timer_reset(), force_activate_view_item_but(), ui_apply_but_func(), ui_block_interaction_begin(), ui_but_active_free(), UI_but_active_only_ex(), ui_but_active_string_clear_and_exit(), ui_but_anim_decorate_cb(), ui_but_execute_begin(), ui_but_execute_end(), ui_but_extra_icons_update_from_old_but(), ui_but_extra_operator_icon_apply(), ui_but_free(), ui_but_is_editing(), ui_but_menu_direction(), ui_but_paste_text(), ui_but_pie_button_activate(), ui_but_pie_menu_apply(), ui_but_set_string_interactive(), ui_but_tooltip_init(), UI_but_tooltip_refresh(), UI_but_tooltip_timer_remove(), ui_but_update_from_old_block(), ui_but_update_old_active_from_new(), ui_but_update_view_for_active(), ui_context_button_active(), UI_context_update_anim_flag(), ui_do_but_HOTKEYEVT(), ui_do_but_TOG(), ui_do_button(), ui_handle_button_activate(), ui_handle_button_event(), ui_handle_button_over(), ui_handle_button_return_submenu(), ui_handle_menu_button(), ui_handle_menu_event(), ui_handle_menu_return_submenu(), ui_handle_menus_recursive(), ui_handler_region_menu(), ui_multibut_states_apply(), ui_multibut_states_tag(), ui_numedit_set_active(), ui_pie_handler(), UI_region_free_active_but_all(), UI_region_searchbox_region_get(), UI_screen_free_active_but_highlight(), widget_roundbox_set(), and with_but_active_as_semi_modal().

◆ alignnr

◆ apply_func

std::function<void(bContext &)> uiBut::apply_func

C++ version of func above. Allows storing arbitrary data in a type safe way, no void pointer arguments.

Definition at line 214 of file interface_intern.hh.

Referenced by ui_afterfunc_check(), ui_apply_but_func(), ui_but_equals_old(), UI_but_func_set(), and ui_popup_context_menu_for_button().

◆ autocomplete_func

uiButCompleteFunc uiBut::autocomplete_func = nullptr

◆ autofunc_arg

void* uiBut::autofunc_arg = nullptr

Definition at line 224 of file interface_intern.hh.

Referenced by UI_but_func_complete_set(), and ui_textedit_autocomplete().

◆ bit

short uiBut::bit = 0

Definition at line 184 of file interface_intern.hh.

Referenced by ui_apply_but_TOG(), ui_but_is_pushed_ex(), and ui_def_but().

◆ bitnr

short uiBut::bitnr = 0

Definition at line 184 of file interface_intern.hh.

Referenced by ui_apply_but_TOG(), ui_but_is_pushed_ex(), and ui_def_but().

◆ block

uiBlock* uiBut::block = nullptr

Definition at line 330 of file interface_intern.hh.

Referenced by button_activate_exit(), button_activate_init(), button_activate_state(), button_tooltip_timer_reset(), draw_emboss(), blender::ui::find_item_from_rename_button(), force_activate_view_item_but(), blender::ui::AbstractTreeViewItem::get_win_rect(), menu_items_from_ui_create_item_from_button(), ui_apply_but_func(), ui_apply_but_TEX(), ui_apply_but_undo(), ui_block_func_POPOVER(), ui_block_func_POPUP(), ui_block_open_begin(), ui_block_open_end(), ui_but_activate_event(), ui_but_add_search(), ui_but_anim_decorate_find_attached_button(), ui_but_anim_expression_create(), ui_but_anim_expression_set(), ui_but_change_type(), ui_but_contains_point_px(), ui_but_contains_point_px_icon(), ui_but_convert_to_unit_alt_name(), ui_but_drag_init(), ui_but_drag_multi_edit_get(), ui_but_event_property_operator_string(), ui_but_execute_begin(), ui_but_execute_end(), ui_but_extra_operator_icon_apply(), ui_but_extra_operator_icon_mouse_over_get(), ui_but_free(), UI_but_func_menu_search(), UI_but_func_search_set(), ui_but_get_fcurve(), ui_but_is_color_gamma(), ui_but_is_drag_toggle(), ui_but_is_unit(), ui_but_is_unit_radians(), ui_but_menu_step(), ui_but_rect_to_view(), ui_but_search_refresh(), ui_but_string_get_dynamic(), ui_but_string_get_ex(), ui_but_string_set(), ui_but_update_ex(), ui_but_update_from_old_block(), ui_but_update_view_for_active(), ui_colorpicker_create_mode_cb(), ui_colorpicker_hex_rna_cb(), ui_colorpicker_hsv_update_cb(), ui_colorpicker_rgba_update_cb(), UI_context_active_but_prop_handle(), ui_def_but(), ui_def_but_icon(), ui_def_but_rna__menu(), ui_do_but_ANY_drag_toggle(), ui_do_but_BLOCK(), ui_do_but_BUT(), ui_do_but_COLOR(), ui_do_but_HSVCIRCLE(), ui_do_but_HSVCUBE(), ui_do_but_SCROLL(), ui_do_but_TOG(), ui_draw_but(), ui_draw_but_COLORBAND(), ui_draw_but_CURVE(), ui_draw_but_CURVEPROFILE(), ui_draw_but_HSVCIRCLE(), ui_draw_but_HSVCUBE(), ui_get_but_scale_unit(), ui_get_but_step_unit(), ui_get_but_string_unit(), ui_handle_button_event(), ui_handle_button_over(), ui_handle_button_return_submenu(), ui_handle_list_event(), ui_handle_menu_button(), UI_key_event_operator_string(), ui_layer_but_cb(), ui_layout_introspect_button(), ui_multibut_states_create(), ui_multibut_states_tag(), ui_number_from_string_units_with_but(), ui_numedit_apply_snapf(), ui_numedit_but_NUM(), ui_numedit_but_SLI(), ui_numedit_but_TRACKPREVIEW(), ui_numedit_set_active(), ui_popup_block_position(), ui_popup_block_refresh(), ui_popup_close_cb(), ui_popup_context_menu_for_button(), UI_popup_menu_close_from_but(), ui_popup_menu_create_impl(), ui_search_menu_create_context_menu(), ui_search_menu_create_tooltip(), ui_searchbox_create_generic_ex(), ui_searchbox_region_layout_fn(), ui_text_clip_middle(), ui_text_clip_middle_protect_right(), ui_textedit_begin(), ui_textedit_set_cursor_pos(), UI_tooltip_create_from_button_or_extra_icon(), ui_tooltip_data_from_button_or_extra_icon(), ui_tooltip_data_from_tool(), widget_draw_extra_mask(), widget_draw_icon(), widget_draw_node_link_socket(), widget_draw_submenu_tria(), widget_draw_text_icon(), widget_menu_pie_itembut(), and widget_swatch().

◆ block_create_func

uiBlockCreateFunc uiBut::block_create_func = nullptr

◆ changed

bool uiBut::changed = false

◆ col

◆ context

◆ custom_data

◆ disabled_info

const char* uiBut::disabled_info = nullptr

info on why button is disabled, displayed in tooltip

Definition at line 249 of file interface_intern.hh.

Referenced by UI_but_disable(), ui_def_but(), and ui_tooltip_data_from_button_or_extra_icon().

◆ dragflag

◆ dragpoin

◆ dragtype

◆ drawflag

◆ drawstr

◆ editstr

◆ editval

double* uiBut::editval = nullptr

◆ editvec

◆ emboss

◆ extra_op_icons

◆ flag

int uiBut::flag = 0

Definition at line 179 of file interface_intern.hh.

Referenced by block_search_filter_tag_buttons(), blender::ui::bonedropper_poll(), button_activate_exit(), button_activate_init(), button_activate_state(), curvemap_buttons_layout(), datadropper_poll(), driverdropper_init(), drop_name_poll(), blender::ui::AbstractTreeViewItem::is_hovered(), menu_items_from_ui_create_item_from_button(), panel_remove_invisible_layouts_recursive(), template_common_search_menu(), template_ID(), ui_apply_but(), ui_apply_but_TEX(), ui_apply_but_undo(), ui_block_func_POPUP(), ui_block_interaction_begin(), ui_but_add_search(), ui_but_add_shortcut(), ui_but_anim_decorate_cb(), ui_but_anim_decorate_update_from_flag(), ui_but_anim_flag(), ui_but_context_poll_operator_ex(), ui_but_drag_multi_edit_get(), ui_but_draw_menu_icon(), ui_but_drawstr_len_without_sep_char(), ui_but_execute_end(), ui_but_find_select_in_enum(), UI_but_flag_disable(), UI_but_flag_enable(), UI_but_flag_is_set(), ui_but_icon(), ui_but_icon_extra_get(), ui_but_icon_extra_is_visible_bone_eyedropper(), ui_but_icon_extra_is_visible_search_eyedropper(), ui_but_icon_extra_is_visible_search_unlink(), ui_but_icon_extra_is_visible_text_clear(), ui_but_is_interactive_ex(), UI_but_is_utf8(), ui_but_list_row_text_activate(), UI_but_node_link_set(), UI_but_operator_set(), ui_but_override_flag(), ui_but_paste(), ui_but_set_string_interactive(), UI_but_string_get_label(), ui_but_submenu_enable(), ui_but_update_ex(), ui_but_update_from_old_block(), ui_but_update_old_active_from_new(), ui_but_update_select_flag(), ui_button_press_invoke(), UI_context_active_but_prop_get_filebrowser(), ui_context_button_active(), UI_context_update_anim_flag(), ui_def_but(), ui_def_but_icon(), ui_def_but_icon_clear(), ui_def_but_rna(), ui_def_but_rna__menu(), ui_do_but_BUT(), ui_do_but_textedit(), ui_do_button(), ui_drag_toggle_but_is_supported(), ui_drag_toggle_set(), ui_draw_but(), ui_draw_but_HSV_v(), ui_draw_but_HSVCIRCLE(), ui_draw_but_HSVCUBE(), ui_handle_button_event(), ui_handle_menu_event(), ui_handle_viewlist_items_hover(), ui_handler_region_menu(), ui_item_enum_expand_elem_exec(), ui_item_flag(), ui_layout_has_panel_label(), ui_layout_list_set_labels_active(), ui_multibut_add(), ui_multibut_restore(), ui_multibut_states_apply(), ui_multibut_states_create(), ui_multibut_states_tag(), ui_numedit_set_active(), ui_popup_context_menu_for_button(), ui_popup_context_menu_for_panel(), ui_popup_menu_memory__internal(), ui_searchbox_select(), ui_selectcontext_begin(), ui_selectcontext_end(), ui_textedit_begin(), ui_textedit_end(), ui_textedit_next_but(), ui_textedit_prev_but(), ui_textedit_set_cursor_pos(), ui_tooltip_data_from_button_or_extra_icon(), uiItemDecoratorR_prop(), uiItemFullO_ptr_ex(), uiItemL_(), uiItemPopoverPanel_ptr(), uiItemsFullEnumO_items(), uiLayoutListBox(), uiTemplateNodeLink(), uiTemplateTextureUser(), widget_draw_icon(), widget_draw_text(), widget_draw_text_icon(), and widget_preview_tile().

◆ flag2

int uiBut::flag2 = 0

◆ func

◆ func_arg1

void* uiBut::func_arg1 = nullptr

◆ func_arg2

void* uiBut::func_arg2 = nullptr

◆ func_argN

◆ func_argN_copy_fn

◆ func_argN_free_fn

◆ funcN

◆ hardmax

◆ hardmin

◆ hold_argN

void* uiBut::hold_argN = nullptr

Definition at line 237 of file interface_intern.hh.

Referenced by ui_but_free(), UI_but_func_hold_set(), and ui_item_menu_hold().

◆ hold_func

uiButHandleHoldFunc uiBut::hold_func = nullptr

Run an action when holding the button down.

Definition at line 236 of file interface_intern.hh.

Referenced by button_activate_state(), UI_but_func_hold_set(), ui_draw_but(), and ui_handle_button_event().

◆ icon

◆ icon_overlay_text

IconTextOverlay uiBut::icon_overlay_text = {}

Little indicator (e.g., counter) displayed on top of some icons.

Definition at line 327 of file interface_intern.hh.

Referenced by UI_but_icon_indicator_color_set(), UI_but_icon_indicator_number_set(), UI_but_icon_indicator_set(), uiTemplateStatusInfo(), and widget_draw_icon().

◆ iconadd

short uiBut::iconadd = 0

◆ identity_cmp_func

uiButIdentityCompareFunc uiBut::identity_cmp_func = nullptr

◆ imb

const ImBuf* uiBut::imb = nullptr

◆ imb_scale

float uiBut::imb_scale = 0

Definition at line 297 of file interface_intern.hh.

Referenced by UI_but_drag_attach_image(), and ui_but_drag_start().

◆ layout

uiLayout* uiBut::layout = nullptr

Pointer back to the layout item holding this button.

Definition at line 178 of file interface_intern.hh.

Referenced by UI_but_active_only_ex(), ui_but_change_type(), ui_layout_add_but(), and ui_layout_free().

◆ menu_create_func

◆ menu_key

uchar uiBut::menu_key = 0

When non-zero, this is the key used to activate a menu items (a-z always lower case).

Definition at line 289 of file interface_intern.hh.

Referenced by ui_pie_handler(), and widget_draw_text().

◆ menu_step_func

uiMenuStepFunc uiBut::menu_step_func = nullptr

◆ next

◆ ofs

◆ opcontext

◆ operator_never_call

bool uiBut::operator_never_call = false

Keep an operator attached but never actually call it through the button. See UI_but_operator_set_never_call().

Definition at line 286 of file interface_intern.hh.

Referenced by ui_apply_but_func(), and UI_but_operator_set_never_call().

◆ opptr

◆ optype

◆ pie_dir

RadialDirection uiBut::pie_dir = UI_RADIAL_NONE

direction in a pie menu, used for collision detection.

Definition at line 255 of file interface_intern.hh.

Referenced by ui_block_pie_dir_activate(), ui_but_contains_point_px(), ui_but_isect_pie_seg(), ui_but_pie_direction_string(), ui_litem_layout_radial(), and ui_pie_handler().

◆ placeholder

char* uiBut::placeholder = nullptr

◆ poin

◆ pointype

◆ pos

◆ prev

◆ pushed_state_func

std::function<bool(const uiBut &)> uiBut::pushed_state_func

Definition at line 324 of file interface_intern.hh.

Referenced by UI_but_func_pushed_state_set(), and ui_but_is_pushed_ex().

◆ rect

◆ rename_arg1

void* uiBut::rename_arg1 = nullptr

Definition at line 227 of file interface_intern.hh.

Referenced by ui_apply_but_func(), and UI_but_func_rename_set().

◆ rename_full_func

std::function<void(std::string &new_name)> uiBut::rename_full_func = nullptr

◆ rename_full_new

std::string uiBut::rename_full_new = ""

Definition at line 233 of file interface_intern.hh.

Referenced by ui_apply_but_func(), and ui_but_string_set().

◆ rename_func

uiButHandleRenameFunc uiBut::rename_func = nullptr

◆ rename_orig

void* uiBut::rename_orig = nullptr

Definition at line 228 of file interface_intern.hh.

Referenced by ui_apply_but_func(), and ui_apply_but_TEX().

◆ retval

◆ rnaindex

◆ rnapoin

PointerRNA uiBut::rnapoin = {}

Definition at line 274 of file interface_intern.hh.

Referenced by button_activate_exit(), button_matches_search_filter(), colorband_buttons_layout(), colorband_update_cb(), driverdropper_sample(), drop_color_invoke(), blender::ui::eyedropper_colorband_init(), eyedropper_get_property_button_under_mouse(), get_but_property_array_length(), handle_layer_buttons(), menu_items_from_ui_create_item_from_button(), menu_items_to_ui_button(), shortcut_property_from_rna(), template_keymap_item_properties(), ui_apply_but_autokey(), ui_apply_but_func(), ui_apply_but_undo(), ui_block_colorpicker(), ui_block_message_subscribe(), ui_but_anim_autokey(), ui_but_anim_expression_create(), ui_but_anim_flag(), ui_but_color_has_alpha(), ui_but_copy(), ui_but_copy_color(), ui_but_copy_numeric_array(), ui_but_event_property_operator_string(), ui_but_find_select_in_enum__cmp(), ui_but_get_fcurve(), ui_but_has_array_value(), ui_but_icon_extra_is_visible_search_eyedropper(), ui_but_is_compatible(), ui_but_is_pushed_ex(), ui_but_is_rna_undo(), ui_but_is_rna_valid(), ui_but_is_user_menu_compatible(), UI_but_is_userdef(), ui_but_menu_step(), UI_but_online_manual_id(), ui_but_override_flag(), ui_but_paste(), ui_but_placeholder_get(), ui_but_range_set_hard(), ui_but_range_set_soft(), UI_but_rna_enum_item_get(), ui_but_rna_equals_ex(), ui_but_set_float_array(), ui_but_string_get_dynamic(), ui_but_string_get_ex(), UI_but_string_get_rna_struct_identifier(), ui_but_string_set(), ui_but_update_ex(), ui_but_update_preferences_dirty(), ui_but_user_menu_add(), ui_but_user_menu_find(), ui_but_v3_get(), ui_but_v3_set(), ui_but_v4_get(), ui_but_v4_set(), ui_but_value_get(), ui_but_value_set(), ui_button_value_default(), ui_colorpicker_hex_rna_cb(), ui_colorpicker_hsv_update_cb(), ui_colorpicker_rgba_update_cb(), UI_context_active_but_prop_get_filebrowser(), ui_def_but_rna(), ui_def_but_rna__menu(), ui_do_but_COLOR(), ui_do_but_HSVCIRCLE(), ui_do_but_HSVCUBE(), ui_drag_toggle_but_pushed_state(), ui_handle_list_event(), ui_handle_menu_event(), ui_item_enum_expand_handle(), ui_keymap_but_cb(), ui_layer_but_cb(), ui_layout_introspect_button(), ui_list_activate_row_from_index(), ui_palette_set_active(), ui_popup_context_menu_for_button(), UI_region_active_but_prop_get(), ui_selectcontext_apply(), ui_selectcontext_begin(), UI_textbutton_activate_rna(), ui_tooltip_data_from_button_or_extra_icon(), uiItemFullR(), uiLayoutListBox(), uiLayoutSetContextFromBut(), uiTemplateComponentMenu(), uiTemplateCryptoPicker(), and widget_swatch().

◆ rnaprop

PropertyRNA* uiBut::rnaprop = nullptr

Definition at line 275 of file interface_intern.hh.

Referenced by button_matches_search_filter(), colorband_buttons_layout(), driverdropper_sample(), drop_color_invoke(), blender::ui::eyedropper_colorband_init(), eyedropper_get_property_button_under_mouse(), get_but_property_array_length(), handle_layer_buttons(), menu_items_from_ui_create_item_from_button(), menu_items_to_ui_button(), shortcut_get_operator_property(), shortcut_property_from_rna(), template_keymap_item_properties(), ui_afterfunc_check(), ui_apply_but_autokey(), ui_apply_but_func(), ui_apply_but_undo(), ui_block_colorpicker(), ui_block_message_subscribe(), ui_but_anim_autokey(), ui_but_anim_expression_create(), ui_but_anim_flag(), ui_but_build_drawstr_float(), ui_but_build_drawstr_int(), ui_but_color_has_alpha(), ui_but_contains_password(), ui_but_copy_color(), ui_but_copy_numeric_array(), ui_but_drag_init(), ui_but_event_property_operator_string(), ui_but_find_select_in_enum__cmp(), ui_but_get_fcurve(), ui_but_has_array_value(), ui_but_icon_extra_is_visible_bone_eyedropper(), ui_but_icon_extra_is_visible_search_eyedropper(), ui_but_is_bool(), ui_but_is_color_gamma(), ui_but_is_compatible(), ui_but_is_float(), ui_but_is_pushed_ex(), ui_but_is_rna_undo(), ui_but_is_rna_valid(), ui_but_is_user_menu_compatible(), UI_but_is_userdef(), UI_but_is_utf8(), ui_but_menu_step(), ui_but_menu_step_poll(), UI_but_online_manual_id(), ui_but_override_flag(), ui_but_paste_color(), ui_but_placeholder_get(), ui_but_range_set_hard(), ui_but_range_set_soft(), UI_but_rna_enum_item_get(), ui_but_rna_equals_ex(), ui_but_scale_type(), ui_but_search_refresh(), ui_but_set_float_array(), ui_but_string_eval_number(), ui_but_string_get_dynamic(), ui_but_string_get_ex(), UI_but_string_get_rna_label(), UI_but_string_get_rna_label_context(), UI_but_string_get_rna_property_identifier(), UI_but_string_get_rna_struct_identifier(), UI_but_string_get_rna_tooltip(), ui_but_string_set(), ui_but_text_password_hide(), UI_but_unit_type_get(), ui_but_update_ex(), ui_but_update_preferences_dirty(), ui_but_user_menu_add(), ui_but_user_menu_find(), ui_but_v3_get(), ui_but_v3_set(), ui_but_v4_get(), ui_but_v4_set(), ui_but_value_get(), ui_but_value_set(), ui_button_value_default(), ui_colorpicker_hex_rna_cb(), ui_colorpicker_hsv_update_cb(), ui_colorpicker_rgba_update_cb(), UI_context_active_but_prop_get_filebrowser(), ui_def_but_rna(), ui_def_but_rna__menu(), ui_do_but_COLOR(), ui_do_but_HSVCIRCLE(), ui_do_but_HSVCUBE(), ui_do_but_TAB(), ui_handle_button_event(), ui_handle_list_event(), ui_handle_menu_event(), ui_item_enum_expand_handle(), ui_layer_but_cb(), ui_layout_introspect_button(), ui_list_activate_row_from_index(), ui_multibut_states_create(), ui_popup_context_menu_for_button(), UI_region_active_but_prop_get(), ui_selectcontext_apply(), ui_selectcontext_begin(), UI_textbutton_activate_rna(), ui_tooltip_data_from_button_or_extra_icon(), uiItemFullR(), uiItemFullR_with_menu(), uiItemFullR_with_popover(), uiLayoutListBox(), uiLayoutSetContextFromBut(), uiTemplateComponentMenu(), uiTemplateCryptoPicker(), uiTemplateKeymapItemProperties(), widget_numslider(), and widget_swatch().

◆ search_weight

float uiBut::search_weight = 0.0f

Affects the order if this uiBut is used in menu-search.

Definition at line 263 of file interface_intern.hh.

Referenced by menu_items_from_ui_create_item_from_button(), and ui_layout_add_but().

◆ selend

◆ selsta

◆ semi_modal_state

uiHandleButtonData* uiBut::semi_modal_state = nullptr

Event handling only supports one active button at a time, but there are cases where that's not enough. A common one is to keep some filter button active to receive text input, while other buttons remain active for interaction.

Buttons that have semi_modal_state set will be temporarily activated for event handling. If they don't consume the event (for example text input events) the event will be forwarded to other buttons.

Currently only text buttons support this well.

Definition at line 315 of file interface_intern.hh.

Referenced by button_activate_exit(), button_activate_init(), foreach_semi_modal_but_as_active(), ui_but_extra_icons_update_from_old_but(), ui_but_free(), ui_but_semi_modal_state_free(), ui_but_update_from_old_block(), ui_but_update_old_active_from_new(), and with_but_active_as_semi_modal().

◆ softmax

◆ softmin

◆ str

◆ strwidth

◆ tip

◆ tip_arg

◆ tip_arg_free

◆ tip_custom_func

◆ tip_func

◆ tip_label_func

std::function<std::string(const uiBut *)> uiBut::tip_label_func

Function to override the label to be displayed in the tooltip.

Definition at line 244 of file interface_intern.hh.

Referenced by UI_but_func_tooltip_label_set(), UI_but_string_get_tooltip_label(), ui_but_update_old_active_from_new(), and ui_but_user_menu_add().

◆ type

eButType uiBut::type = eButType(0)

Definition at line 182 of file interface_intern.hh.

Referenced by blender::ui::bonedropper_init(), blender::ui::bonedropper_poll(), button_activate_exit(), button_activate_init(), button_activate_state(), button_matches_search_filter(), datadropper_poll(), depthdropper_poll(), depthdropper_test(), draw_emboss(), drop_color_invoke(), blender::ui::eyedropper_colorband_init(), blender::ui::eyedropper_colorband_poll(), blender::ui::find_item_from_rename_button(), jump_to_target_button(), menu_items_from_ui_create(), ui_apply_but(), ui_apply_but_BLOCK(), ui_apply_but_func(), ui_apply_but_TEX(), ui_apply_but_TOG(), ui_apply_but_undo(), UI_block_can_add_separator(), UI_block_is_empty_ex(), ui_block_open_begin(), ui_block_pie_dir_activate(), UI_but_active_drop_color(), UI_but_active_drop_name_button(), ui_but_add_search(), ui_but_can_align(), ui_but_change_type(), UI_but_context_menu_title_from_button(), ui_but_copy(), ui_but_drag_init(), ui_but_equals_old(), ui_but_event_property_operator_string(), ui_but_find_select_in_enum__cmp(), ui_but_free(), ui_but_free_type_specific(), UI_but_func_search_set(), UI_but_func_search_set_context_menu(), UI_but_func_search_set_listen(), UI_but_func_search_set_results_are_suggestions(), UI_but_func_search_set_sep_string(), UI_but_func_search_set_tooltip(), ui_but_get_float_precision(), ui_but_get_float_step_size(), ui_but_icon_extra_get(), ui_but_icon_extra_is_visible_bone_eyedropper(), ui_but_icon_extra_is_visible_search_eyedropper(), ui_but_icon_extra_is_visible_search_unlink(), ui_but_icon_extra_is_visible_text_clear(), ui_but_is_active_view_item(), ui_but_is_bool(), ui_but_is_compatible(), ui_but_is_cursor_warp(), ui_but_is_editable(), ui_but_is_editable_as_text(), ui_but_is_interactive_ex(), ui_but_is_listbox_with_row(), ui_but_is_listrow(), ui_but_is_popover_once_compat(), ui_but_is_pushed_ex(), ui_but_is_toggle(), ui_but_is_view_item_fn(), UI_but_label_alpha_factor_set(), ui_but_list_row_text_activate(), ui_but_mem_delete(), ui_but_menu_step_poll(), ui_but_new(), ui_but_next_non_separator(), UI_but_number_precision_set(), UI_but_number_slider_precision_set(), UI_but_number_slider_step_size_set(), UI_but_number_step_size_set(), ui_but_paste(), ui_but_pie_menu_apply(), ui_but_pie_menu_supported_apply(), ui_but_placeholder_get(), UI_but_rna_enum_item_get(), ui_but_rna_menu_convert_to_menu_type(), ui_but_rna_menu_convert_to_panel_type(), UI_but_search_preview_grid_size_set(), ui_but_set_float_array(), ui_but_set_string_interactive(), ui_but_string_get_dynamic(), ui_but_string_get_ex(), ui_but_string_get_maxncpy(), UI_but_string_get_rna_label(), UI_but_string_get_rna_label_context(), UI_but_string_get_rna_struct_identifier(), UI_but_string_get_rna_tooltip(), ui_but_string_set(), ui_but_supports_cycling(), UI_but_type_set_menu_from_pulldown(), ui_but_update_ex(), ui_but_update_from_old_block(), ui_but_update_old_active_from_new(), ui_but_v3_get(), ui_but_validate(), UI_but_view_item_draw_size_set(), UI_context_active_but_get_tab_ID(), ui_def_but(), ui_def_but_rna(), ui_def_but_rna__menu(), ui_do_but_COLOR(), ui_do_but_HOTKEYEVT(), ui_do_but_NUM(), ui_do_but_SLI(), ui_do_but_textedit(), ui_do_but_TOG(), ui_do_but_VIEW_ITEM(), ui_do_button(), ui_draw_but(), ui_handle_button_activate_by_type(), ui_handle_button_event(), ui_handle_button_return_submenu(), ui_handle_menu_button(), ui_handle_menu_event(), ui_handle_menus_recursive(), ui_handle_view_item_event(), ui_handle_viewlist_items_hover(), ui_handler_panel_region(), ui_handler_region_menu(), ui_item_array(), ui_item_is_radial_drawable(), UI_key_event_operator_string(), ui_keymap_but_cb(), ui_layout_introspect_button(), ui_list_contains_row(), ui_list_row_find_index(), ui_litem_layout_radial(), ui_numedit_begin(), ui_numedit_but_SLI(), ui_numedit_end(), ui_popup_block_position(), ui_popup_context_menu_for_button(), ui_popup_menu_create_impl(), ui_searchbox_apply(), ui_searchbox_autocomplete(), ui_searchbox_event(), ui_searchbox_update(), ui_text_clip_middle(), ui_text_clip_middle_protect_right(), UI_textbutton_activate_but(), UI_textbutton_activate_rna(), ui_textedit_begin(), ui_textedit_end(), ui_textedit_next_but(), ui_textedit_prev_but(), ui_textedit_set_cursor_pos(), UI_tooltip_create_from_button_or_extra_icon(), ui_tooltip_data_from_button_or_extra_icon(), ui_view_item_find_search_highlight(), uiItemFullR(), uiItemFullR_with_menu(), uiItemFullR_with_popover(), uiItemPopoverPanel_ptr(), uiLayoutSetTooltipFunc(), uiTemplateLayers(), widget_draw_icon(), widget_draw_text(), widget_draw_text_icon(), widget_icon_has_anim(), widget_list_itembut(), widget_roundbox_set(), and widget_swatch().

◆ unit_type

uchar uiBut::unit_type = 0

so buttons can support unit systems which are not RNA

Definition at line 259 of file interface_intern.hh.

Referenced by UI_but_unit_type_get(), UI_but_unit_type_set(), and ui_multibut_states_create().


The documentation for this struct was generated from the following file: