diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-10-11 13:28:05 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-10-11 15:20:25 +0300 |
commit | 45477efd0e25293be8721bf949409b44f7ce0cc8 (patch) | |
tree | 2a9e5d927b316b59edeb197e66050745f67101ea /source/blender/editors/interface/interface_widgets.c | |
parent | d90eb356622931988f4b97c50d42c427f5868f20 (diff) |
UI: increase spacing between icon and text.
To avoid the icon and text blending together too much, which happens with
the new monochrome and slightly bigger icons.
Diffstat (limited to 'source/blender/editors/interface/interface_widgets.c')
-rw-r--r-- | source/blender/editors/interface/interface_widgets.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/interface/interface_widgets.c b/source/blender/editors/interface/interface_widgets.c index fba43afb609..92f5ad08f89 100644 --- a/source/blender/editors/interface/interface_widgets.c +++ b/source/blender/editors/interface/interface_widgets.c @@ -2079,6 +2079,7 @@ static void widget_draw_text_icon(uiFontStyle *fstyle, uiWidgetColors *wcol, uiB const BIFIconID icon = (but->flag & UI_HAS_ICON) ? but->icon + but->iconadd : ICON_NONE; int icon_size_init = is_tool ? ICON_DEFAULT_HEIGHT_TOOLBAR : ICON_DEFAULT_HEIGHT; const float icon_size = icon_size_init / (but->block->aspect / UI_DPI_FAC); + const float icon_padding = 2 * UI_DPI_FAC; #ifdef USE_UI_TOOLBAR_HACK if (is_tool) { @@ -2110,7 +2111,7 @@ static void widget_draw_text_icon(uiFontStyle *fstyle, uiWidgetColors *wcol, uiB but->block->aspect = aspect_orig; #endif - rect->xmin += icon_size; + rect->xmin += icon_size + icon_padding; } if (but->editstr || (but->drawflag & UI_BUT_TEXT_LEFT)) { |