diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-10-27 18:51:26 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-10-27 18:57:56 +0300 |
commit | ae55523013642f2897e840f30ad62c74d31df3e0 (patch) | |
tree | c8f3af1b967ef05b1aee8a6c90a828c1dbc499b1 /source/blender/editors/include | |
parent | c036db9f57ff1bf5762e2b4dda802ee41cdbd115 (diff) |
UI: add utility to show icons for the keymap item
This is useful for drawing keymap items into the header or status bar
While these icons are available directly,
mapping them from the keymap item isn't trivial.
Diffstat (limited to 'source/blender/editors/include')
-rw-r--r-- | source/blender/editors/include/UI_interface.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/editors/include/UI_interface.h b/source/blender/editors/include/UI_interface.h index f5721c008b2..8f205173011 100644 --- a/source/blender/editors/include/UI_interface.h +++ b/source/blender/editors/include/UI_interface.h @@ -2021,6 +2021,12 @@ void uiTemplateEditModeSelection(uiLayout *layout, struct bContext *C); void uiTemplateReportsBanner(uiLayout *layout, struct bContext *C); void uiTemplateInputStatus(uiLayout *layout, struct bContext *C); void uiTemplateKeymapItemProperties(uiLayout *layout, struct PointerRNA *ptr); + +bool uiTemplateEventFromKeymapItem(struct uiLayout *layout, + const char *text, + const struct wmKeyMapItem *kmi, + bool text_fallback); + void uiTemplateComponentMenu(uiLayout *layout, struct PointerRNA *ptr, const char *propname, |