[Bf-blender-cvs] [1882dfc47c1] blender2.8: UI: More opaque type icons in the Outliner
Pablo Vazquez
noreply at git.blender.org
Thu Jul 26 02:42:30 CEST 2018
Commit: 1882dfc47c18c9b715c36eb7a76d01a306a10580
Author: Pablo Vazquez
Date: Thu Jul 26 02:42:20 2018 +0200
Branches: blender2.8
https://developer.blender.org/rB1882dfc47c18c9b715c36eb7a76d01a306a10580
UI: More opaque type icons in the Outliner
Also always draw the counter of elements-per-type with a dark background
regardless of the active status. It being white when active affects
readability since the icon background itself is already highlighted.
Thanks devtalk forum for feedback.
===================================================================
M source/blender/editors/space_outliner/outliner_draw.c
===================================================================
diff --git a/source/blender/editors/space_outliner/outliner_draw.c b/source/blender/editors/space_outliner/outliner_draw.c
index 783a03f3993..e1049d02e37 100644
--- a/source/blender/editors/space_outliner/outliner_draw.c
+++ b/source/blender/editors/space_outliner/outliner_draw.c
@@ -1341,16 +1341,9 @@ static void tselem_draw_icon(
static void outliner_draw_iconrow_number(
const uiFontStyle *fstyle,
int offsx, int ys,
- const eOLDrawState active,
const int num_elements)
{
- float color[4] = {0.4f, 0.4f, 0.4f, 0.9f};
- copy_v3_fl(color, 0.2f);
- if (active != OL_DRAWSEL_NONE) {
- copy_v3_fl(color, 0.65f);
- color[3] = 1.0f;
- }
-
+ float color[4] = {0.0f, 0.0f, 0.0f, 1.0f};
float ufac = 0.25f * UI_UNIT_X;
float offset_x = (float) offsx + UI_UNIT_X * 0.35f;
@@ -1414,13 +1407,13 @@ static void outliner_draw_iconrow_doit(
}
/* No inlined icon should be clickable. */
- tselem_draw_icon(block, xmax, (float)*offsx, (float)ys, tselem, te, 0.5f * alpha_fac, false);
+ tselem_draw_icon(block, xmax, (float)*offsx, (float)ys, tselem, te, 0.8f * alpha_fac, false);
te->xs = *offsx;
te->ys = ys;
te->xend = (short)*offsx + UI_UNIT_X;
if (num_elements > 1) {
- outliner_draw_iconrow_number(fstyle, *offsx, ys, active, num_elements);
+ outliner_draw_iconrow_number(fstyle, *offsx, ys, num_elements);
}
(*offsx) += UI_UNIT_X;
}
More information about the Bf-blender-cvs
mailing list