From 5425761290d94b208efea117e3b6a865e9157b92 Mon Sep 17 00:00:00 2001 From: Wolfgang Ulbrich Date: Wed, 6 Jan 2016 22:16:38 +0100 Subject: GTK3 icon-container: fix rendering of text on the desktop taken from: https://git.gnome.org/browse/nautilus/commit/?h=gnome-3-0&id=2e5f7a23350016c67bb9e9cca86a9fb2360d79e2 --- libcaja-private/caja-icon-canvas-item.c | 2 +- libcaja-private/caja-icon-container.c | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) (limited to 'libcaja-private') diff --git a/libcaja-private/caja-icon-canvas-item.c b/libcaja-private/caja-icon-canvas-item.c index b48583ba..1249cba6 100644 --- a/libcaja-private/caja-icon-canvas-item.c +++ b/libcaja-private/caja-icon-canvas-item.c @@ -2381,7 +2381,7 @@ draw_label_layout (CajaIconCanvasItem *item, int x, int y) { - GdkRGBA black = { 0, 0, 0, 0 }; + GdkRGBA black = { 0, 0, 0, 1 }; #else GdkDrawable *drawable, PangoLayout *layout, diff --git a/libcaja-private/caja-icon-container.c b/libcaja-private/caja-icon-container.c index 04ca88bf..4cf35d30 100644 --- a/libcaja-private/caja-icon-container.c +++ b/libcaja-private/caja-icon-container.c @@ -121,8 +121,8 @@ #define DEFAULT_NORMAL_ALPHA 0xff #define DEFAULT_PRELIGHT_ALPHA 0xff #if GTK_CHECK_VERSION(3,0,0) -#define DEFAULT_LIGHT_INFO_COLOR "AAAAFD" -#define DEFAULT_DARK_INFO_COLOR "33337F" +#define DEFAULT_LIGHT_INFO_COLOR "#AAAAFD" +#define DEFAULT_DARK_INFO_COLOR "#33337F" #else #define DEFAULT_LIGHT_INFO_COLOR 0xAAAAFD #define DEFAULT_DARK_INFO_COLOR 0x33337F @@ -9494,13 +9494,13 @@ setup_label_gcs (CajaIconContainer *container) if (!light_info_color) { light_info_color = g_malloc (sizeof (GdkRGBA)); - gdk_rgba_parse (light_info_color, DEFAULT_LIGHT_INFO_COLOR); + g_assert (gdk_rgba_parse (light_info_color, DEFAULT_LIGHT_INFO_COLOR)); } if (!dark_info_color) { - light_info_color = g_malloc (sizeof (GdkRGBA)); - gdk_rgba_parse (dark_info_color, DEFAULT_DARK_INFO_COLOR); + dark_info_color = g_malloc (sizeof (GdkRGBA)); + g_assert (gdk_rgba_parse (dark_info_color, DEFAULT_DARK_INFO_COLOR)); } gtk_style_context_get_color (style, GTK_STATE_FLAG_SELECTED, &color); @@ -9545,7 +9545,7 @@ setup_label_gcs (CajaIconContainer *container) { GdkRGBA tmp; - gdk_rgba_parse (&tmp, "EFEFEF"); + gdk_rgba_parse (&tmp, "#EFEFEF"); setup_gc_with_fg (container, LABEL_COLOR, &tmp); setup_gc_with_fg (container, LABEL_INFO_COLOR, light_info_color); } @@ -9553,7 +9553,7 @@ setup_label_gcs (CajaIconContainer *container) { GdkRGBA tmp; - gdk_rgba_parse (&tmp, "000000"); + gdk_rgba_parse (&tmp, "#000000"); setup_gc_with_fg (container, LABEL_COLOR, &tmp); setup_gc_with_fg (container, LABEL_INFO_COLOR, dark_info_color); } -- cgit v1.2.1