[Bf-blender-cvs] [dc2b562ace2] master: Splash: use red heart icon for development fund
Brecht Van Lommel
noreply at git.blender.org
Wed Jul 10 14:59:39 CEST 2019
Commit: dc2b562ace25e77907c12c7a68bdc680bcf9a7e9
Author: Brecht Van Lommel
Date: Wed Jul 10 12:40:18 2019 +0200
Branches: master
https://developer.blender.org/rBdc2b562ace25e77907c12c7a68bdc680bcf9a7e9
Splash: use red heart icon for development fund
Now that the development fund image will disappear from the splash, this
draws a little more attention to this link.
===================================================================
M release/datafiles/blender_icons.svg
A release/datafiles/blender_icons16/icon16_fund.dat
A release/datafiles/blender_icons32/icon32_fund.dat
M release/scripts/startup/bl_operators/wm.py
M release/scripts/startup/bl_ui/space_topbar.py
M source/blender/editors/include/UI_icons.h
M source/blender/editors/include/UI_resources.h
M source/blender/editors/interface/interface_icons.c
M source/blender/editors/interface/resources.c
===================================================================
diff --git a/release/datafiles/blender_icons.svg b/release/datafiles/blender_icons.svg
index ecbf6af70e0..3ed2da387ac 100644
--- a/release/datafiles/blender_icons.svg
+++ b/release/datafiles/blender_icons.svg
@@ -5284,6 +5284,12 @@
<path style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacin [...]
</g>
</g>
+ <path
+ inkscape:connector-curvature="0"
+ id="path5001"
+ d="m 408.48148,452.0625 c -1.71014,0.0728 -3.32227,1.4838 -3.32227,3.9375 0,2.05278 1.07076,4.01178 2.38672,5.71289 1.31595,1.70111 2.90024,3.15481 4.03125,4.16016 0.0914,0.0816 0.20954,0.12673 0.33203,0.12695 h 0.5 c 0.12249,-2.2e-4 0.24064,-0.0454 0.33203,-0.12695 1.13101,-1.00535 2.7153,-2.45905 4.03125,-4.16016 1.31596,-1.70111 2.38672,-3.66011 2.38672,-5.71289 0,-2.4537 -1.61213,-3.86473 -3.32227,-3.9375 -1.52139,-0.0647 -3.0532,0.927 -3.67773,2.69727 -0.62453,-1.77027 -2.156 [...]
+ style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:norma [...]
+ sodipodi:nodetypes="csccccccsccc" />
</g>
<g inkscape:groupmode="layer" id="layer2" inkscape:label="EMPTY ICON TRACKING" style="display:none">
<g id="g16331" style="fill:#ffcc00">
diff --git a/release/datafiles/blender_icons16/icon16_fund.dat b/release/datafiles/blender_icons16/icon16_fund.dat
new file mode 100644
index 00000000000..4e303bf6d75
Binary files /dev/null and b/release/datafiles/blender_icons16/icon16_fund.dat differ
diff --git a/release/datafiles/blender_icons32/icon32_fund.dat b/release/datafiles/blender_icons32/icon32_fund.dat
new file mode 100644
index 00000000000..5243d9418a0
Binary files /dev/null and b/release/datafiles/blender_icons32/icon32_fund.dat differ
diff --git a/release/scripts/startup/bl_operators/wm.py b/release/scripts/startup/bl_operators/wm.py
index 04a9a83e712..f2b885d0064 100644
--- a/release/scripts/startup/bl_operators/wm.py
+++ b/release/scripts/startup/bl_operators/wm.py
@@ -1789,7 +1789,7 @@ class WM_MT_splash(Menu):
"wm.url_open", text="Release Notes", icon='URL',
).url = "https://www.blender.org/download/releases/%d-%d/" % bpy.app.version[:2]
col2.operator(
- "wm.url_open", text="Development Fund", icon='URL'
+ "wm.url_open", text="Development Fund", icon='FUND'
).url = "https://fund.blender.org"
layout.separator()
diff --git a/release/scripts/startup/bl_ui/space_topbar.py b/release/scripts/startup/bl_ui/space_topbar.py
index cd0ef52e981..382e421eecd 100644
--- a/release/scripts/startup/bl_ui/space_topbar.py
+++ b/release/scripts/startup/bl_ui/space_topbar.py
@@ -368,7 +368,7 @@ class TOPBAR_MT_app_support(Menu):
layout = self.layout
layout.operator(
- "wm.url_open", text="Development Fund", icon='URL',
+ "wm.url_open", text="Development Fund", icon='FUND',
).url = "https://fund.blender.org"
layout.separator()
diff --git a/source/blender/editors/include/UI_icons.h b/source/blender/editors/include/UI_icons.h
index 3d2052f1fa9..47cf827ed66 100644
--- a/source/blender/editors/include/UI_icons.h
+++ b/source/blender/editors/include/UI_icons.h
@@ -45,6 +45,9 @@
#ifndef DEF_ICON_COLOR
# define DEF_ICON_COLOR DEF_ICON
#endif
+#ifndef DEF_ICON_FUND
+# define DEF_ICON_FUND DEF_ICON
+#endif
/* ICON_ prefix added */
DEF_ICON_COLOR(NONE)
@@ -289,7 +292,7 @@ DEF_ICON(DECORATE_LIBRARY_OVERRIDE)
DEF_ICON(DECORATE_UNLOCKED)
DEF_ICON(DECORATE_LOCKED)
DEF_ICON(DECORATE_OVERRIDE)
-DEF_ICON_BLANK(111)
+DEF_ICON_FUND(FUND)
DEF_ICON(TRACKER_DATA)
DEF_ICON(HEART)
DEF_ICON(ORPHAN_DATA)
@@ -1033,4 +1036,5 @@ DEF_ICON_COLOR(EVENT_RETURN)
#undef DEF_ICON_SHADING
#undef DEF_ICON_VECTOR
#undef DEF_ICON_COLOR
+#undef DEF_ICON_FUND
#undef DEF_ICON_BLANK
diff --git a/source/blender/editors/include/UI_resources.h b/source/blender/editors/include/UI_resources.h
index db6bb35560d..3b080b6df95 100644
--- a/source/blender/editors/include/UI_resources.h
+++ b/source/blender/editors/include/UI_resources.h
@@ -272,6 +272,7 @@ typedef enum ThemeColorID {
TH_ICON_OBJECT_DATA,
TH_ICON_MODIFIER,
TH_ICON_SHADING,
+ TH_ICON_FUND,
TH_SCROLL_TEXT,
diff --git a/source/blender/editors/interface/interface_icons.c b/source/blender/editors/interface/interface_icons.c
index 59889e74230..ea5ef94d90d 100644
--- a/source/blender/editors/interface/interface_icons.c
+++ b/source/blender/editors/interface/interface_icons.c
@@ -169,6 +169,7 @@ static const IconType icontypes[] = {
# define DEF_ICON_OBJECT_DATA(name) {ICON_TYPE_MONO_TEXTURE, TH_ICON_OBJECT_DATA},
# define DEF_ICON_MODIFIER(name) {ICON_TYPE_MONO_TEXTURE, TH_ICON_MODIFIER},
# define DEF_ICON_SHADING(name) {ICON_TYPE_MONO_TEXTURE, TH_ICON_SHADING},
+# define DEF_ICON_FUND(name) {ICON_TYPE_MONO_TEXTURE, TH_ICON_FUND},
# define DEF_ICON_VECTOR(name) {ICON_TYPE_VECTOR, 0},
# define DEF_ICON_COLOR(name) {ICON_TYPE_COLOR_TEXTURE, 0},
# define DEF_ICON_BLANK(name) {ICON_TYPE_BLANK, 0},
diff --git a/source/blender/editors/interface/resources.c b/source/blender/editors/interface/resources.c
index e281c6c9e9c..25116934b06 100644
--- a/source/blender/editors/interface/resources.c
+++ b/source/blender/editors/interface/resources.c
@@ -901,6 +901,12 @@ const uchar *UI_ThemeGetColorPtr(bTheme *btheme, int spacetype, int colorid)
case TH_ICON_SHADING:
cp = btheme->tui.icon_shading;
break;
+ case TH_ICON_FUND: {
+ /* Development fund icon color is not part of theme. */
+ static const char red[4] = {204, 48, 72, 255};
+ cp = red;
+ break;
+ }
case TH_SCROLL_TEXT:
cp = btheme->tui.wcol_scroll.text;
@@ -1377,12 +1383,14 @@ bool UI_GetIconThemeColor4ubv(int colorid, uchar col[4])
if (colorid == 0) {
return false;
}
-
- /* Only colored icons in outliner and popups, overall UI is intended
- * to stay monochrome and out of the way except a few places where it
- * is important to communicate different data types. */
- if (!((theme_spacetype == SPACE_OUTLINER && theme_regionid == RGN_TYPE_WINDOW) ||
- (theme_spacetype == SPACE_PROPERTIES && theme_regionid == RGN_TYPE_NAV_BAR))) {
+ else if (colorid == TH_ICON_FUND) {
+ /* Always color development fund icon. */
+ }
+ else if (!((theme_spacetype == SPACE_OUTLINER && theme_regionid == RGN_TYPE_WINDOW) ||
+ (theme_spacetype == SPACE_PROPERTIES && theme_regionid == RGN_TYPE_NAV_BAR))) {
+ /* Only colored icons in outliner and popups, overall UI is intended
+ * to stay monochrome and out of the way except a few places where it
+ * is important to communicate different data types. */
return false;
}
More information about the Bf-blender-cvs
mailing list