diff options
author | Fabian Schempp <fabianschempp@googlemail.com> | 2021-06-25 08:57:24 +0300 |
---|---|---|
committer | Fabian Schempp <fabianschempp@googlemail.com> | 2021-06-25 08:57:24 +0300 |
commit | ae085e301c2aac0d6956609bfe93a90a19f0e235 (patch) | |
tree | 38b86749807915a6b6d46504a2acb90e41a4a77a /source/blender/editors/include/UI_interface.h | |
parent | 841df831e89dfc4011c323203c2efb8265dc1878 (diff) |
Spreadsheet: Dataset region for spreadsheet editor
This patch adds a left aligned sidebar to the spreadsheet editor. This
Sidebar can be used to navigate the geometry component types and
attribute domains. It also provides a quick overview of domain sizes.
It replaces the two dropdowns in the regions header.
Next step will be to add the domain cycling shortcut
using the CTRL + mouse wheel.
Reviewer: Dalai Felinto (dfelinto), Julian Eisel (Severin),
Hans Goudey (HooglyBoogly).
Differential Revision: https://developer.blender.org/D11046
Diffstat (limited to 'source/blender/editors/include/UI_interface.h')
-rw-r--r-- | source/blender/editors/include/UI_interface.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/source/blender/editors/include/UI_interface.h b/source/blender/editors/include/UI_interface.h index df65c602fc4..7553a2d373e 100644 --- a/source/blender/editors/include/UI_interface.h +++ b/source/blender/editors/include/UI_interface.h @@ -386,6 +386,7 @@ typedef enum { /** Resize handle (resize uilist). */ UI_BTYPE_GRIP = 57 << 9, UI_BTYPE_DECORATOR = 58 << 9, + UI_BTYPE_DATASETROW = 59 << 9, } eButType; #define BUTTYPE (63 << 9) @@ -516,7 +517,7 @@ typedef struct ARegion *(*uiButSearchTooltipFn)(struct bContext *C, /* Must return allocated string. */ typedef char *(*uiButToolTipFunc)(struct bContext *C, void *argN, const char *tip); -typedef int (*uiButPushedStateFunc)(struct bContext *C, void *arg); +typedef int (*uiButPushedStateFunc)(struct uiBut *but, const void *arg); typedef void (*uiBlockHandleFunc)(struct bContext *C, void *arg, int event); @@ -1612,6 +1613,13 @@ int UI_searchbox_size_x(void); /* check if a string is in an existing search box */ int UI_search_items_find_index(uiSearchItems *items, const char *name); +void UI_but_hint_drawstr_set(uiBut *but, const char *string); +void UI_but_datasetrow_indentation_set(uiBut *but, int indentation); +void UI_but_datasetrow_component_set(uiBut *but, uint8_t geometry_component_type); +void UI_but_datasetrow_domain_set(uiBut *but, uint8_t attribute_domain); +uint8_t UI_but_datasetrow_component_get(uiBut *but); +uint8_t UI_but_datasetrow_domain_get(uiBut *but); + void UI_but_node_link_set(uiBut *but, struct bNodeSocket *socket, const float draw_color[4]); void UI_but_number_step_size_set(uiBut *but, float step_size); @@ -1650,7 +1658,7 @@ void UI_but_focus_on_enter_event(struct wmWindow *win, uiBut *but); void UI_but_func_hold_set(uiBut *but, uiButHandleHoldFunc func, void *argN); -void UI_but_func_pushed_state_set(uiBut *but, uiButPushedStateFunc func, void *arg); +void UI_but_func_pushed_state_set(uiBut *but, uiButPushedStateFunc func, const void *arg); struct PointerRNA *UI_but_extra_operator_icon_add(uiBut *but, const char *opname, |