[gnumeric: 1/2] renamed go-color.h macros
- From: Jean Bréfort <jbrefort src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gnumeric: 1/2] renamed go-color.h macros
- Date: Sat, 5 Sep 2009 17:14:58 +0000 (UTC)
commit d05b1a23067bb2deb71342b441124877a575859a
Author: Jean Brefort <jean brefort normalesup org>
Date: Sat Sep 5 12:42:22 2009 +0200
renamed go-color.h macros
ChangeLog | 4 ++
plugins/excel/ChangeLog | 4 ++
plugins/excel/ms-chart.c | 16 +++++-----
plugins/excel/ms-excel-read.c | 16 +++++-----
plugins/excel/ms-excel-write.c | 8 ++--
plugins/excel/xlsx-read.c | 52 ++++++++++++++++----------------
plugins/excel/xlsx-write.c | 4 +-
plugins/html/ChangeLog | 8 +++++
plugins/html/html.c | 18 ++++++------
plugins/html/latex.c | 6 ++--
plugins/openoffice/ChangeLog | 5 +++
plugins/openoffice/openoffice-write.c | 12 ++++----
src/cell-draw.c | 10 ------
src/dialogs/ChangeLog | 4 ++
src/dialogs/dialog-autoformat.c | 2 +-
src/dialogs/dialog-cell-format.c | 6 ++--
src/dialogs/dialog-printer-setup.c | 14 ++++----
src/dialogs/dialog-sheet-order.c | 2 +-
src/gnm-pane.c | 14 ++++----
src/gnm-so-filled.c | 12 ++++----
src/gnm-so-line.c | 12 ++++----
src/gnm-so-polygon.c | 4 +-
src/gui-util.c | 8 ++--
src/item-bar.c | 8 ++--
src/item-cursor.c | 6 ++--
src/item-edit.c | 2 +-
src/item-grid.c | 2 +-
src/mstyle.c | 6 ++--
src/pattern.c | 6 ++--
src/sheet-object-cell-comment.c | 2 +-
src/style-color.c | 8 ++--
src/tools/ChangeLog | 18 +++++++++++
src/tools/scenarios.c | 8 ++--
src/wbc-gtk.c | 2 +-
34 files changed, 171 insertions(+), 138 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 4a5a9b7..103638d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2009-09-05 Jean Brefort <jean brefort normalesup org>
+
+ * all files: renamed go-color.h macros.
+
2009-09-04 Morten Welinder <terra gnome org>
* src/rendered-value.c (calc_indent): Drop zoom argument. All
diff --git a/plugins/excel/ChangeLog b/plugins/excel/ChangeLog
index b966940..ad51e02 100644
--- a/plugins/excel/ChangeLog
+++ b/plugins/excel/ChangeLog
@@ -1,5 +1,9 @@
2009-09-05 Jean Brefort <jean brefort normalesup org>
+ * all files: renamed go-color.h macros.
+
+2009-09-05 Jean Brefort <jean brefort normalesup org>
+
* ms-chart.c (end): don't use z values as x or y when there are no
labels or categories. [See #593937]
diff --git a/plugins/excel/ms-chart.c b/plugins/excel/ms-chart.c
index 6e867b1..b4b0aa7 100644
--- a/plugins/excel/ms-chart.c
+++ b/plugins/excel/ms-chart.c
@@ -200,7 +200,7 @@ BC_R(color) (guint8 const *data, char const *type)
guint16 const b = (bgr >> 16) & 0xff;
d (1, g_printerr ("%s %02x:%02x:%02x;\n", type, r, g, b););
- return GO_RGBA_TO_UINT (r, g, b, 0xff);
+ return GO_COLOR_FROM_RGB (r, g, b);
}
/****************************************************************************/
@@ -1079,7 +1079,7 @@ ms_chart_map_color (XLChartReadState const *s, guint32 raw, guint32 alpha)
r = (raw) & 0xff;
g = (raw >> 8) & 0xff;
b = (raw >> 16) & 0xff;
- res = GO_RGBA_TO_UINT (r, g, b, 0xff);
+ res = GO_COLOR_FROM_RGB (r, g, b);
}
return res;
}
@@ -3883,9 +3883,9 @@ static unsigned
chart_write_color (XLChartWriteState *s, guint8 *data, GOColor c)
{
guint32 abgr;
- abgr = GO_UINT_RGBA_R(c);
- abgr |= GO_UINT_RGBA_G(c) << 8;
- abgr |= GO_UINT_RGBA_B(c) << 16;
+ abgr = GO_COLOR_UINT_R(c);
+ abgr |= GO_COLOR_UINT_G(c) << 8;
+ abgr |= GO_COLOR_UINT_B(c) << 16;
GSF_LE_SET_GUINT32 (data, abgr);
return palette_get_index (&s->ewb->base, abgr & 0xffffff);
@@ -3907,8 +3907,8 @@ chart_write_AREAFORMAT (XLChartWriteState *s, GOStyle const *style, gboolean dis
#warning export images
case GO_STYLE_FILL_NONE:
pat = 0;
- fore = GO_RGBA_WHITE;
- back = GO_RGBA_WHITE;
+ fore = GO_COLOR_WHITE;
+ back = GO_COLOR_WHITE;
break;
case GO_STYLE_FILL_PATTERN: {
pat = style->fill.pattern.pattern + 1;
@@ -4902,7 +4902,7 @@ chart_write_axis (XLChartWriteState *s, GogAxis const *axis,
tick_color_index = chart_write_color (s, data+4, style->font.color); /* tick label color */
memset (data+8, 0, 16);
/* if font is black, set the auto color flag, otherwise, don't set */
- flags = (style->font.color == GO_RGBA_BLACK)? 0x03: 0x02;
+ flags = (style->font.color == GO_COLOR_BLACK)? 0x03: 0x02;
if (style->text_layout.auto_angle)
flags |= 0x20;
else if (style->text_layout.angle < -45)
diff --git a/plugins/excel/ms-excel-read.c b/plugins/excel/ms-excel-read.c
index 875242d..68317c7 100644
--- a/plugins/excel/ms-excel-read.c
+++ b/plugins/excel/ms-excel-read.c
@@ -346,9 +346,9 @@ ms_sheet_map_color (ExcelReadSheet const *esheet, MSObj const *obj, MSObjAttrID
GnmColor *c = excel_palette_get (esheet->container.importer,
(0x7ffffff & attr->v.v_uint));
- r = GO_UINT_RGBA_R (c->go_color);
- g = GO_UINT_RGBA_G (c->go_color);
- b = GO_UINT_RGBA_B (c->go_color);
+ r = GO_COLOR_UINT_R (c->go_color);
+ g = GO_COLOR_UINT_G (c->go_color);
+ b = GO_COLOR_UINT_B (c->go_color);
style_color_unref (c);
} else {
r = (attr->v.v_uint) & 0xff;
@@ -356,7 +356,7 @@ ms_sheet_map_color (ExcelReadSheet const *esheet, MSObj const *obj, MSObjAttrID
b = (attr->v.v_uint >> 16) & 0xff;
}
- return GO_RGBA_TO_UINT (r,g,b,0xff);
+ return GO_COLOR_FROM_RGBA (r,g,b,0xff);
}
/**
@@ -513,7 +513,7 @@ ms_sheet_realize_obj (MSContainer *container, MSObj *obj)
case 0x04: /* Arc */
style = go_style_new ();
style->line.color = ms_sheet_map_color (esheet, obj,
- MS_OBJ_ATTR_OUTLINE_COLOR, GO_RGBA_BLACK);
+ MS_OBJ_ATTR_OUTLINE_COLOR, GO_COLOR_BLACK);
style->line.width = ms_obj_attr_get_uint (obj->attrs,
MS_OBJ_ATTR_OUTLINE_WIDTH, 0) / 256.;
style->line.dash_type = ms_obj_attr_bag_lookup (obj->attrs, MS_OBJ_ATTR_OUTLINE_HIDE)
@@ -534,15 +534,15 @@ ms_sheet_realize_obj (MSContainer *container, MSObj *obj)
case 0x0E: /* Label */
style = go_style_new ();
style->line.color = ms_sheet_map_color (esheet, obj,
- MS_OBJ_ATTR_OUTLINE_COLOR, GO_RGBA_BLACK);
+ MS_OBJ_ATTR_OUTLINE_COLOR, GO_COLOR_BLACK);
style->line.width = ms_obj_attr_get_uint (obj->attrs,
MS_OBJ_ATTR_OUTLINE_WIDTH, 0) / 256.;
style->line.dash_type = ms_obj_attr_bag_lookup (obj->attrs, MS_OBJ_ATTR_OUTLINE_HIDE)
? GO_LINE_NONE : xl_pattern_to_line_type (ms_obj_attr_get_int (obj->attrs, MS_OBJ_ATTR_OUTLINE_STYLE, 1));
style->fill.pattern.back = ms_sheet_map_color (esheet, obj,
- MS_OBJ_ATTR_FILL_COLOR, GO_RGBA_WHITE);
+ MS_OBJ_ATTR_FILL_COLOR, GO_COLOR_WHITE);
style->fill.pattern.fore = ms_sheet_map_color (esheet, obj,
- MS_OBJ_ATTR_FILL_BACKGROUND, GO_RGBA_BLACK);
+ MS_OBJ_ATTR_FILL_BACKGROUND, GO_COLOR_BLACK);
style->fill.type = ms_obj_attr_bag_lookup (obj->attrs, MS_OBJ_ATTR_UNFILLED)
? GO_STYLE_FILL_NONE : GO_STYLE_FILL_PATTERN;
diff --git a/plugins/excel/ms-excel-write.c b/plugins/excel/ms-excel-write.c
index 50dfe92..d277228 100644
--- a/plugins/excel/ms-excel-write.c
+++ b/plugins/excel/ms-excel-write.c
@@ -135,9 +135,9 @@ static guint
go_color_to_bgr (GOColor const c)
{
guint32 abgr;
- abgr = GO_UINT_RGBA_R(c);
- abgr |= GO_UINT_RGBA_G(c) << 8;
- abgr |= GO_UINT_RGBA_B(c) << 16;
+ abgr = GO_COLOR_UINT_R(c);
+ abgr |= GO_COLOR_UINT_G(c) << 8;
+ abgr |= GO_COLOR_UINT_B(c) << 16;
return abgr;
}
@@ -2117,7 +2117,7 @@ excel_font_from_go_font (XLExportBase *ewb, GOFont const *font)
efont->underline = FALSE;
efont->strikethrough = FALSE;
efont->script = 0;
- efont->color = go_color_to_bgr (GO_RGBA_BLACK);
+ efont->color = go_color_to_bgr (GO_COLOR_BLACK);
efont->is_auto = FALSE;
return put_efont (efont, ewb);
diff --git a/plugins/excel/xlsx-read.c b/plugins/excel/xlsx-read.c
index 6b33484..c522fc8 100644
--- a/plugins/excel/xlsx-read.c
+++ b/plugins/excel/xlsx-read.c
@@ -444,7 +444,7 @@ attr_gocolor (GsfXMLIn *xin, xmlChar const **attrs,
guint8 const r = (rgb >> 16) & 0xff;
guint8 const g = (rgb >> 8) & 0xff;
guint8 const b = (rgb >> 0) & 0xff;
- *res = GO_RGBA_TO_UINT(r, g, b, 0xff);
+ *res = GO_COLOR_FROM_RGB (r, g, b);
}
return TRUE;
@@ -646,27 +646,27 @@ indexed_color (XLSXReadState *state, gint idx)
*/
if (idx == 1 || idx == 65)
- return GO_RGBA_WHITE;
+ return GO_COLOR_WHITE;
switch (idx) {
case 0: /* black */
case 64 : /* system text ? */
case 81 : /* tooltip text */
case 0x7fff : /* system text ? */
- return GO_RGBA_BLACK;
+ return GO_COLOR_BLACK;
case 1 : /* white */
case 65 : /* system back ? */
- return GO_RGBA_WHITE;
+ return GO_COLOR_WHITE;
case 80 : /* tooltip background */
- return GO_RGBA_YELLOW;
+ return GO_COLOR_YELLOW;
- case 2 : return GO_RGBA_RED;
- case 3 : return GO_RGBA_GREEN;
- case 4 : return GO_RGBA_BLUE;
- case 5 : return GO_RGBA_YELLOW;
- case 6 : return GO_RGBA_VIOLET;
- case 7 : return GO_RGBA_CYAN;
+ case 2 : return GO_COLOR_RED;
+ case 3 : return GO_COLOR_GREEN;
+ case 4 : return GO_COLOR_BLUE;
+ case 5 : return GO_COLOR_YELLOW;
+ case 6 : return GO_COLOR_VIOLET;
+ case 7 : return GO_COLOR_CYAN;
default :
break;
@@ -676,13 +676,13 @@ indexed_color (XLSXReadState *state, gint idx)
if (idx < 0 || (int) G_N_ELEMENTS (excel_default_palette_v8) <= idx) {
g_warning ("EXCEL: color index (%d) is out of range (8..%d). Defaulting to black",
idx + 8, (int)G_N_ELEMENTS (excel_default_palette_v8) + 8);
- return GO_RGBA_BLACK;
+ return GO_COLOR_BLACK;
}
/* TODO cache and ref */
- return GO_RGBA_TO_UINT (excel_default_palette_v8[idx].r,
+ return GO_COLOR_FROM_RGB (excel_default_palette_v8[idx].r,
excel_default_palette_v8[idx].g,
- excel_default_palette_v8[idx].b, 0xff);
+ excel_default_palette_v8[idx].b);
}
static GOColor
themed_color (GsfXMLIn *xin, gint idx)
@@ -716,7 +716,7 @@ themed_color (GsfXMLIn *xin, gint idx)
idx, (int) G_N_ELEMENTS (theme_elements));
}
- return GO_RGBA_BLACK;
+ return GO_COLOR_BLACK;
}
static GOFormat *
@@ -1527,7 +1527,7 @@ xlsx_draw_color_alpha (GsfXMLIn *xin, xmlChar const **attrs)
int val;
if (simple_int (xin, attrs, &val)) {
int level = 255 * val / 100000;
- state->gocolor = GO_UINT_RGBA_CHANGE_A (state->gocolor, level);
+ state->gocolor = GO_COLOR_CHANGE_A (state->gocolor, level);
}
}
@@ -2394,10 +2394,10 @@ hue_to_color (int m1, int m2, int h)
static GOColor
apply_tint (GOColor orig, float tint)
{
- int r = GO_UINT_RGBA_R (orig);
- int g = GO_UINT_RGBA_G (orig);
- int b = GO_UINT_RGBA_B (orig);
- int a = GO_UINT_RGBA_A (orig);
+ int r = GO_COLOR_UINT_R (orig);
+ int g = GO_COLOR_UINT_G (orig);
+ int b = GO_COLOR_UINT_B (orig);
+ int a = GO_COLOR_UINT_A (orig);
int maxC = b, minC = b, delta, sum, h, l, s, m1, m2;
if (fabs (tint) < .005)
@@ -2438,7 +2438,7 @@ apply_tint (GOColor orig, float tint)
if (s == 0) { /* achromatic case */
r = (l * RGBMAX) / HLSMAX;
- return GO_RGBA_TO_UINT(r, r, r, a);
+ return GO_COLOR_FROM_RGBA (r, r, r, a);
}
if (l <= (HLSMAX/2))
@@ -2451,7 +2451,7 @@ apply_tint (GOColor orig, float tint)
g = (hue_to_color (m1, m2, h )*RGBMAX + (HLSMAX/2)) / HLSMAX;
b = (hue_to_color (m1, m2, h - (HLSMAX/3))*RGBMAX + (HLSMAX/2)) / HLSMAX;
- return GO_RGBA_TO_UINT(r,g,b,a);
+ return GO_COLOR_FROM_RGBA (r,g,b,a);
}
static GnmColor *
@@ -2473,7 +2473,7 @@ elem_color (GsfXMLIn *xin, xmlChar const **attrs)
return NULL;
}
has_color = TRUE;
- c = GO_RGBA_TO_UINT(r,g,b,a);
+ c = GO_COLOR_FROM_RGBA (r,g,b,a);
} else if (attr_int (xin, attrs, "indexed", &indx)) {
has_color = TRUE;
c = indexed_color (state, indx);
@@ -2824,9 +2824,9 @@ xlsx_sheet_tabcolor (GsfXMLIn *xin, xmlChar const **attrs)
GnmColor *text_color, *color = elem_color (xin, attrs);
if (NULL != color) {
int contrast =
- GO_UINT_RGBA_R (color->go_color) +
- GO_UINT_RGBA_G (color->go_color) +
- GO_UINT_RGBA_B (color->go_color);
+ GO_COLOR_UINT_R (color->go_color) +
+ GO_COLOR_UINT_G (color->go_color) +
+ GO_COLOR_UINT_B (color->go_color);
if (contrast >= 0x180)
text_color = style_color_black ();
else
diff --git a/plugins/excel/xlsx-write.c b/plugins/excel/xlsx-write.c
index 65868bd..6c6aaae 100644
--- a/plugins/excel/xlsx-write.c
+++ b/plugins/excel/xlsx-write.c
@@ -104,8 +104,8 @@ xlsx_add_rgb (GsfXMLOut *xml, char const *id, GOColor c)
{
char buf [3 * 4 * sizeof (unsigned int) + 1];
sprintf (buf, "%02X%02X%02X%02X",
- GO_UINT_RGBA_A (c), GO_UINT_RGBA_R (c),
- GO_UINT_RGBA_G (c), GO_UINT_RGBA_B (c));
+ GO_COLOR_UINT_A (c), GO_COLOR_UINT_R (c),
+ GO_COLOR_UINT_G (c), GO_COLOR_UINT_B (c));
gsf_xml_out_add_cstr_unchecked (xml, id, buf);
}
static void
diff --git a/plugins/html/ChangeLog b/plugins/html/ChangeLog
index 90ba3d4..f9353e4 100644
--- a/plugins/html/ChangeLog
+++ b/plugins/html/ChangeLog
@@ -1,3 +1,11 @@
+2009-09-05 Jean Brefort <jean brefort normalesup org>
+
+ reviewed by: <delete if not using a buddy>
+
+ * html.c (html_get_text_color), (html_get_back_color),
+ (html_get_border_style): renamed go-color.h macros.
+ * latex.c (latex2e_write_multicolumn_cell): ditto.
+
2009-09-01 Andreas J. Guelzow <aguelzow pyrshep ca>
* html.c (cb_html_attrs_as_string): handle PANGO_ATTR_RISE
diff --git a/plugins/html/html.c b/plugins/html/html.c
index 2696d9c..cc01555 100644
--- a/plugins/html/html.c
+++ b/plugins/html/html.c
@@ -121,18 +121,18 @@ html_get_text_color (GnmCell *cell, GnmStyle const *style, guint *r, guint *g, g
if (fore == 0)
*r = *g = *b = 0;
else {
- *r = GO_UINT_RGBA_R (fore);
- *g = GO_UINT_RGBA_G (fore);
- *b = GO_UINT_RGBA_B (fore);
+ *r = GO_COLOR_UINT_R (fore);
+ *g = GO_COLOR_UINT_G (fore);
+ *b = GO_COLOR_UINT_B (fore);
}
}
static void
html_get_back_color (GnmStyle const *style, guint *r, guint *g, guint *b)
{
GnmColor const *color = gnm_style_get_back_color (style);
- *r = GO_UINT_RGBA_R (color->go_color);
- *g = GO_UINT_RGBA_G (color->go_color);
- *b = GO_UINT_RGBA_B (color->go_color);
+ *r = GO_COLOR_UINT_R (color->go_color);
+ *g = GO_COLOR_UINT_G (color->go_color);
+ *b = GO_COLOR_UINT_B (color->go_color);
}
/*****************************************************************************/
@@ -399,9 +399,9 @@ html_get_border_style (GnmBorder *border)
if (border->color) {
guint r, g, b;
- r = GO_UINT_RGBA_R (border->color->go_color);
- g = GO_UINT_RGBA_G (border->color->go_color);
- b = GO_UINT_RGBA_B (border->color->go_color);
+ r = GO_COLOR_UINT_R (border->color->go_color);
+ g = GO_COLOR_UINT_G (border->color->go_color);
+ b = GO_COLOR_UINT_B (border->color->go_color);
g_string_append_printf (text, " #%02X%02X%02X", r, g, b);
}
diff --git a/plugins/html/latex.c b/plugins/html/latex.c
index 4fc3ee1..78e7d05 100644
--- a/plugins/html/latex.c
+++ b/plugins/html/latex.c
@@ -979,9 +979,9 @@ latex2e_write_multicolumn_cell (GsfOutput *output, GnmCell *cell, int start_col,
if (fore == 0)
r = g = b = 0;
else {
- r = GO_UINT_RGBA_R (fore);
- g = GO_UINT_RGBA_G (fore);
- b = GO_UINT_RGBA_B (fore);
+ r = GO_COLOR_UINT_R (fore);
+ g = GO_COLOR_UINT_G (fore);
+ b = GO_COLOR_UINT_B (fore);
}
if (r != 0 || g != 0 || b != 0) {
char *locale;
diff --git a/plugins/openoffice/ChangeLog b/plugins/openoffice/ChangeLog
index dba909d..9b31b3c 100644
--- a/plugins/openoffice/ChangeLog
+++ b/plugins/openoffice/ChangeLog
@@ -1,3 +1,8 @@
+2009-09-05 Jean Brefort <jean brefort normalesup org>
+
+ * openoffice-write.c (gnm_xml_out_add_hex_color),
+ (odf_get_border_format): renamed go-color.h macros.
+
2009-09-03 Andreas J. Guelzow <aguelzow pyrshep ca>
* openoffice-read.c (oo_prop_list_has_multi_series): new
diff --git a/plugins/openoffice/openoffice-write.c b/plugins/openoffice/openoffice-write.c
index 74f26c3..b71bfab 100644
--- a/plugins/openoffice/openoffice-write.c
+++ b/plugins/openoffice/openoffice-write.c
@@ -415,9 +415,9 @@ gnm_xml_out_add_hex_color (GsfXMLOut *o, char const *id, GnmColor const *c)
else {
char *color;
color = g_strdup_printf ("#%.2x%.2x%.2x",
- GO_UINT_RGBA_R (c->go_color),
- GO_UINT_RGBA_G (c->go_color),
- GO_UINT_RGBA_B (c->go_color));
+ GO_COLOR_UINT_R (c->go_color),
+ GO_COLOR_UINT_G (c->go_color),
+ GO_COLOR_UINT_B (c->go_color));
gsf_xml_out_add_cstr_unchecked (o, id, color);
g_free (color);
}
@@ -597,9 +597,9 @@ odf_get_border_format (GnmBorder *border)
g_string_append_printf (str, "%.3fcm ", w);
g_string_append (str, border_type);
g_string_append_printf (str, " #%.2x%.2x%.2x",
- GO_UINT_RGBA_R (color->go_color),
- GO_UINT_RGBA_G (color->go_color),
- GO_UINT_RGBA_B (color->go_color));
+ GO_COLOR_UINT_R (color->go_color),
+ GO_COLOR_UINT_G (color->go_color),
+ GO_COLOR_UINT_B (color->go_color));
return g_string_free (str, FALSE);
}
diff --git a/src/cell-draw.c b/src/cell-draw.c
index 4ed999d..ed12385 100644
--- a/src/cell-draw.c
+++ b/src/cell-draw.c
@@ -315,16 +315,6 @@ cell_draw (GnmCell const *cell, cairo_t *cr,
width, height);
cairo_save (cr);
-#if 0
- gdk_gc_set_clip_rectangle (gc, &rect);
- if (cell->pos.col == 3 && cell->pos.row == 10) {
- GdkColor col = { 0, 0, 0xffff, 0 };
- gdk_gc_set_rgb_fg_color (gc, &col);
- gdk_draw_rectangle (drawable, gc, TRUE,
- rect.x, rect.y,
- rect.width, rect.height);
- }
-#endif
/*
* HACK -- do not clip rotated cells. This gives an
diff --git a/src/dialogs/ChangeLog b/src/dialogs/ChangeLog
index c7cb8de..8488276 100644
--- a/src/dialogs/ChangeLog
+++ b/src/dialogs/ChangeLog
@@ -1,3 +1,7 @@
+2009-09-05 Jean Brefort <jean brefort normalesup org>
+
+ * all files: renamed go-color.h macros.
+
2009-09-03 Jean Brefort <jean brefort normalesup org>
* dialog-printer-setup.c (margin_preview_page_destroy),
diff --git a/src/dialogs/dialog-autoformat.c b/src/dialogs/dialog-autoformat.c
index 54e5290..0bd3f13 100644
--- a/src/dialogs/dialog-autoformat.c
+++ b/src/dialogs/dialog-autoformat.c
@@ -338,7 +338,7 @@ previews_load (AutoFormatState *state, int topindex)
NULL);
style = go_styled_object_get_style (GO_STYLED_OBJECT (state->selrect));
style->line.width = 3.;
- style->line.color = GO_RGBA_RED;
+ style->line.color = GO_COLOR_RED;
style->fill.pattern.back = 0;
gtk_frame_set_shadow_type (state->frame[i], GTK_SHADOW_IN);
diff --git a/src/dialogs/dialog-cell-format.c b/src/dialogs/dialog-cell-format.c
index 6a8e113..fd851d7 100644
--- a/src/dialogs/dialog-cell-format.c
+++ b/src/dialogs/dialog-cell-format.c
@@ -390,7 +390,7 @@ setup_color_pickers (FormatState *state,
cg = go_color_group_fetch (color_group,
wb_control_view (WORKBOOK_CONTROL (state->wbcg)));
combo = go_combo_color_new (NULL, default_caption,
- def_sc ? def_sc->go_color : GO_RGBA_BLACK, cg);
+ def_sc ? def_sc->go_color : GO_COLOR_BLACK, cg);
go_combo_box_set_title (GO_COMBO_BOX (combo), caption);
/* Connect to the sample canvas and redraw it */
@@ -1298,7 +1298,7 @@ draw_border_preview (FormatState *state)
goc_polyline_get_type (),
"points", points,
NULL)));
- style->line.color = GO_RGBA_TO_UINT (0xa1, 0xa1, 0xa1, 0xff); /* gray63 */
+ style->line.color = GO_COLOR_FROM_RGBA (0xa1, 0xa1, 0xa1, 0xff); /* gray63 */
style->line.width = 0.;
}
goc_points_unref (points);
@@ -2475,7 +2475,7 @@ fmt_dialog_impl (FormatState *state, FormatDialogPosition_t pageno)
fmt_dialog_init_input_msg_page (state);
fmt_dialog_init_conditions_page (state);
- default_border_color = GO_GDK_TO_UINT (GTK_WIDGET (state->dialog)->style->black);
+ default_border_color = GO_COLOR_FROM_GDK (GTK_WIDGET (state->dialog)->style->black);
if (pageno == FD_CURRENT)
pageno = fmt_dialog_page;
diff --git a/src/dialogs/dialog-printer-setup.c b/src/dialogs/dialog-printer-setup.c
index e7d19dc..a04189b 100644
--- a/src/dialogs/dialog-printer-setup.c
+++ b/src/dialogs/dialog-printer-setup.c
@@ -54,7 +54,7 @@
#define PAGE_Y (PREVIEW_Y - PREVIEW_MARGIN_Y)
#define MARGIN_COLOR_DEFAULT 0xa9a9a9ff /* dark gray */
-#define MARGIN_COLOR_ACTIVE GO_RGBA_RED
+#define MARGIN_COLOR_ACTIVE GO_COLOR_RED
#define HF_PREVIEW_X 350
#define HF_PREVIEW_Y 75
@@ -432,8 +432,8 @@ margin_preview_page_create (PrinterSetupState *state)
"width", (double) x2-x1,
"height", (double) y2-y1,
NULL)));
- style->fill.pattern.back = GO_RGBA_BLACK;
- style->line.color = GO_RGBA_BLACK;
+ style->fill.pattern.back = GO_COLOR_BLACK;
+ style->line.color = GO_COLOR_BLACK;
style->line.width = 1.;
style = go_styled_object_get_style (
@@ -444,8 +444,8 @@ margin_preview_page_create (PrinterSetupState *state)
"width", (double) x2-x1,
"height", (double) y2-y1,
NULL)));
- style->fill.pattern.back = GO_RGBA_WHITE;
- style->line.color = GO_RGBA_BLACK;
+ style->fill.pattern.back = GO_COLOR_WHITE;
+ style->line.color = GO_COLOR_BLACK;
style->line.width = 1.;
goc_item_invalidate (pi->group);
@@ -1878,7 +1878,7 @@ create_hf_preview_canvas (PrinterSetupState *state, gboolean header)
"width", width,
"height", height + (header ? -shadow: shadow),
NULL)));
- gostyle->fill.pattern.back = GO_RGBA_BLACK;
+ gostyle->fill.pattern.back = GO_COLOR_BLACK;
gostyle->line.width = 0.;
gostyle->line.color = 0;
@@ -1890,7 +1890,7 @@ create_hf_preview_canvas (PrinterSetupState *state, gboolean header)
"width", width,
"height", height,
NULL)));
- gostyle->fill.pattern.back = GO_RGBA_WHITE;
+ gostyle->fill.pattern.back = GO_COLOR_WHITE;
gostyle->line.width = 0.;
gostyle->line.color = 0;
diff --git a/src/dialogs/dialog-sheet-order.c b/src/dialogs/dialog-sheet-order.c
index 3189523..5000123 100644
--- a/src/dialogs/dialog-sheet-order.c
+++ b/src/dialogs/dialog-sheet-order.c
@@ -290,7 +290,7 @@ color_equal (const GdkColor *color_a, const GnmColor *color_gb)
if (color_gb == NULL)
return color_a == NULL;
/* FIXME: What about ->is_auto? */
- return color_a && GO_GDK_TO_UINT (*color_a) == color_gb->go_color;
+ return color_a && GO_COLOR_FROM_GDK (*color_a) == color_gb->go_color;
}
static void
diff --git a/src/gnm-pane.c b/src/gnm-pane.c
index 199358b..5c69f7c 100644
--- a/src/gnm-pane.c
+++ b/src/gnm-pane.c
@@ -1988,19 +1988,19 @@ gnm_pane_size_guide_start (GnmPane *pane, gboolean vert, int colrow, int width)
/* cheat for now and differentiate between col/row resize and frozen panes
* using the width. Frozen pane guides do not require a start line */
if (width == 1) {
- style->line.color = GO_RGBA_BLACK;
+ style->line.color = GO_COLOR_BLACK;
pane->size_guide.start = goc_item_new (pane->action_items,
GOC_TYPE_LINE,
"x0", x0, "y0", y0,
"x1", x1, "y1", y1,
NULL);
style = go_styled_object_get_style (GO_STYLED_OBJECT (pane->size_guide.start));
- style->line.color = GO_RGBA_BLACK;
+ style->line.color = GO_COLOR_BLACK;
style->line.width = width;
} else {
style->line.pattern = GO_PATTERN_GREY25;
- style->line.color = GO_RGBA_WHITE;
- style->line.fore = GO_RGBA_BLACK;
+ style->line.color = GO_COLOR_WHITE;
+ style->line.fore = GO_COLOR_BLACK;
}
}
@@ -2693,7 +2693,7 @@ control_point_enter_notify (GocItem *item, G_GNUC_UNUSED double x, G_GNUC_UNUSED
idx = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (item), "index"));
if (idx != 8) {
GOStyle *style = go_styled_object_get_style (GO_STYLED_OBJECT (item));
- style->fill.pattern.back = GO_RGBA_GREEN;
+ style->fill.pattern.back = GO_COLOR_GREEN;
goc_item_invalidate (item);
gnm_pane_display_obj_size_tip (pane, so);
}
@@ -2714,7 +2714,7 @@ control_point_leave_notify (GocItem *item, G_GNUC_UNUSED double x, G_GNUC_UNUSED
idx = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (item), "index"));
if (idx != 8) {
GOStyle *style = go_styled_object_get_style (GO_STYLED_OBJECT (item));
- style->fill.pattern.back = GO_RGBA_WHITE;
+ style->fill.pattern.back = GO_COLOR_WHITE;
goc_item_invalidate (item);
gnm_pane_clear_obj_size_tip (pane);
}
@@ -2857,7 +2857,7 @@ set_acetate_coords (GnmPane *pane, SheetObject *so, GocItem **ctrl_pts,
style->line.width = 1.;
style->line.auto_color = FALSE;
style->line.color = 0;
- style->line.fore = GO_RGBA_BLACK;
+ style->line.fore = GO_COLOR_BLACK;
ctrl_pts [9] = goc_item_new (pane->action_items,
GOC_TYPE_RECTANGLE,
"style", style,
diff --git a/src/gnm-so-filled.c b/src/gnm-so-filled.c
index 78bad6e..0f146aa 100644
--- a/src/gnm-so-filled.c
+++ b/src/gnm-so-filled.c
@@ -137,10 +137,10 @@ sof_default_style (void)
GOStyle *res = go_style_new ();
res->interesting_fields = GO_STYLE_OUTLINE | GO_STYLE_FILL;
res->line.width = 0; /* hairline */
- res->line.color = GO_RGBA_BLACK;
+ res->line.color = GO_COLOR_BLACK;
res->line.dash_type = GO_LINE_SOLID; /* anything but 0 */
res->fill.type = GO_STYLE_FILL_PATTERN;
- go_pattern_set_solid (&res->fill.pattern, GO_RGBA_WHITE);
+ go_pattern_set_solid (&res->fill.pattern, GO_COLOR_WHITE);
return res;
}
@@ -252,10 +252,10 @@ gnm_so_filled_draw_cairo (SheetObject const *so, cairo_t *cr,
/* Draw the line */
cairo_set_line_width (cr, (style->line.width)? style->line.width: 1.);
cairo_set_source_rgba (cr,
- GO_UINT_RGBA_R(style->line.color),
- GO_UINT_RGBA_B(style->line.color),
- GO_UINT_RGBA_G(style->line.color),
- GO_UINT_RGBA_A(style->line.color));
+ GO_COLOR_UINT_R(style->line.color),
+ GO_COLOR_UINT_B(style->line.color),
+ GO_COLOR_UINT_G(style->line.color),
+ GO_COLOR_UINT_A(style->line.color));
cairo_stroke (cr);
/* Draw the text. */
if (*(sof->text) != '\0') {
diff --git a/src/gnm-so-line.c b/src/gnm-so-line.c
index 11b9c55..ec0a20d 100644
--- a/src/gnm-so-line.c
+++ b/src/gnm-so-line.c
@@ -51,7 +51,7 @@ typedef struct {
static void
go_arrow_init (GOArrow *res, double a, double b, double c)
{
- res->color = GO_RGBA_BLACK;
+ res->color = GO_COLOR_BLACK;
res->a = a;
res->b = b;
res->c = c;
@@ -126,7 +126,7 @@ sol_default_style (void)
GOStyle *res = go_style_new ();
res->interesting_fields = GO_STYLE_LINE;
res->line.width = 0; /* hairline */
- res->line.color = GO_RGBA_BLACK;
+ res->line.color = GO_COLOR_BLACK;
res->line.dash_type = GO_LINE_SOLID; /* anything but 0 */
return res;
}
@@ -225,10 +225,10 @@ gnm_so_line_draw_cairo (SheetObject const *so, cairo_t *cr,
cairo_set_line_width (cr, (style->width)? style->width: 1.);
cairo_set_source_rgba (cr,
- GO_UINT_RGBA_R(style->color),
- GO_UINT_RGBA_B(style->color),
- GO_UINT_RGBA_G(style->color),
- GO_UINT_RGBA_A(style->color));
+ GO_COLOR_UINT_R(style->color),
+ GO_COLOR_UINT_B(style->color),
+ GO_COLOR_UINT_G(style->color),
+ GO_COLOR_UINT_A(style->color));
if (sol->end_arrow.c > 0.) {
double phi;
diff --git a/src/gnm-so-polygon.c b/src/gnm-so-polygon.c
index 1460b13..8734e56 100644
--- a/src/gnm-so-polygon.c
+++ b/src/gnm-so-polygon.c
@@ -121,11 +121,11 @@ sop_default_style (void)
GOStyle *res = go_style_new ();
res->interesting_fields = GO_STYLE_OUTLINE | GO_STYLE_FILL;
res->line.width = 0; /* hairline */
- res->line.color = GO_RGBA_BLACK;
+ res->line.color = GO_COLOR_BLACK;
res->line.dash_type = GO_LINE_SOLID; /* anything but 0 */
res->line.join = CAIRO_LINE_JOIN_ROUND;
res->fill.type = GO_STYLE_FILL_PATTERN;
- go_pattern_set_solid (&res->fill.pattern, GO_RGBA_WHITE);
+ go_pattern_set_solid (&res->fill.pattern, GO_COLOR_WHITE);
return res;
}
diff --git a/src/gui-util.c b/src/gui-util.c
index 5bed9cc..8219552 100644
--- a/src/gui-util.c
+++ b/src/gui-util.c
@@ -607,10 +607,10 @@ go_combo_color_get_style_color (GtkWidget *go_combo_color)
GnmColor *sc = NULL;
guint16 r, g, b;
GOColor color = go_combo_color_get_color (GO_COMBO_COLOR (go_combo_color), NULL);
- if (GO_UINT_RGBA_A (color) >= 0x80) {
- r = GO_UINT_RGBA_R (color); r |= (r << 8);
- g = GO_UINT_RGBA_G (color); g |= (g << 8);
- b = GO_UINT_RGBA_B (color); b |= (b << 8);
+ if (GO_COLOR_UINT_A (color) >= 0x80) {
+ r = GO_COLOR_UINT_R (color); r |= (r << 8);
+ g = GO_COLOR_UINT_G (color); g |= (g << 8);
+ b = GO_COLOR_UINT_B (color); b |= (b << 8);
sc = style_color_new_i16 (r, g, b);
}
return sc;
diff --git a/src/item-bar.c b/src/item-bar.c
index 00b5e9d..134b0dd 100644
--- a/src/item-bar.c
+++ b/src/item-bar.c
@@ -243,21 +243,21 @@ ib_draw_cell (ItemBar const * const ib, cairo_t *cr,
case COL_ROW_NO_SELECTION:
shadow = GTK_SHADOW_OUT;
font = ib->normal_font;
- color = GO_GDK_TO_UINT (widget->style->bg[GTK_STATE_ACTIVE]);
+ color = GO_COLOR_FROM_GDK (widget->style->bg[GTK_STATE_ACTIVE]);
ascent = ib->normal_font_ascent;
break;
case COL_ROW_PARTIAL_SELECTION:
shadow = GTK_SHADOW_OUT;
font = ib->bold_font;
- color = GO_GDK_TO_UINT (widget->style->dark[GTK_STATE_PRELIGHT]);
+ color = GO_COLOR_FROM_GDK (widget->style->dark[GTK_STATE_PRELIGHT]);
ascent = ib->bold_font_ascent;
break;
case COL_ROW_FULL_SELECTION:
shadow = GTK_SHADOW_IN;
font = ib->bold_font;
- color = GO_GDK_TO_UINT (widget->style->dark[GTK_STATE_NORMAL]);
+ color = GO_COLOR_FROM_GDK (widget->style->dark[GTK_STATE_NORMAL]);
ascent = ib->bold_font_ascent;
break;
}
@@ -326,7 +326,7 @@ item_bar_draw_region (GocItem const *item, cairo_t *cr, double x_0, double y_0,
int shadow;
int first_line_offset = 1;
GtkStyle *style = gtk_widget_get_style (canvas);
- GOColor color = GO_GDK_TO_UINT (style->text[GTK_STATE_NORMAL]);
+ GOColor color = GO_COLOR_FROM_GDK (style->text[GTK_STATE_NORMAL]);
goc_canvas_c2w (item->canvas, x_0, y_0, &x0, &y0);
goc_canvas_c2w (item->canvas, x_1, y_1, &x1, &y1);
diff --git a/src/item-cursor.c b/src/item-cursor.c
index 268432c..d229a39 100644
--- a/src/item-cursor.c
+++ b/src/item-cursor.c
@@ -146,8 +146,8 @@ item_cursor_realize (GocItem *item)
if (ic->style == ITEM_CURSOR_DRAG || ic->style == ITEM_CURSOR_AUTOFILL) {
GOPattern pat;
cairo_t *cr = gdk_cairo_create (gtk_widget_get_window (GTK_WIDGET (item->canvas)));
- pat.fore = GO_RGBA_BLACK;
- pat.back = GO_RGBA_WHITE;
+ pat.fore = GO_COLOR_BLACK;
+ pat.back = GO_COLOR_WHITE;
pat.pattern = GO_PATTERN_GREY50;
ic->stipple = go_pattern_create_cairo_pattern (&pat, cr);
cairo_destroy (cr);
@@ -1264,7 +1264,7 @@ item_cursor_init (ItemCursor *ic)
ic->auto_fill_handle_at_top = FALSE;
ic->auto_fill_handle_at_left = FALSE;
ic->drag_button = -1;
- ic->color = GO_RGBA_BLACK;
+ ic->color = GO_COLOR_BLACK;
}
GSF_CLASS (ItemCursor, item_cursor,
diff --git a/src/item-edit.c b/src/item-edit.c
index d90c34f..dd374ba 100644
--- a/src/item-edit.c
+++ b/src/item-edit.c
@@ -109,7 +109,7 @@ item_edit_draw (GocItem const *item, cairo_t *cr)
cairo_set_source_rgba (cr, 1., 1., 0.878431373, 1.);
cairo_fill (cr);
- color = GO_GDK_TO_UINT (gtk_widget_get_style (GTK_WIDGET (item->canvas))->black);
+ color = GO_COLOR_FROM_GDK (gtk_widget_get_style (GTK_WIDGET (item->canvas))->black);
cairo_set_source_rgba (cr, GO_COLOR_TO_CAIRO (color));
cairo_move_to (cr, left, top);
pango_cairo_show_layout (cr, ie->layout);
diff --git a/src/item-grid.c b/src/item-grid.c
index 3d67be7..f0906a8 100644
--- a/src/item-grid.c
+++ b/src/item-grid.c
@@ -417,7 +417,7 @@ item_grid_draw_region (GocItem const *item, cairo_t *cr, double x_0, double y_0,
/* Fill entire region with default background (even past far edge) */
cairo_save (cr);
/* FIXME: we previously used gs_white */
- cairo_set_source_rgba (cr, GO_COLOR_TO_CAIRO (GO_RGBA_WHITE));
+ cairo_set_source_rgba (cr, GO_COLOR_TO_CAIRO (GO_COLOR_WHITE));
cairo_rectangle (cr, x0, y0, width, height);
cairo_fill (cr);
cairo_restore (cr);
diff --git a/src/mstyle.c b/src/mstyle.c
index 475cd54..2cef59f 100644
--- a/src/mstyle.c
+++ b/src/mstyle.c
@@ -1808,9 +1808,9 @@ gnm_style_dump_color (GnmColor *color, GnmStyleElement elem)
{
if (color)
g_printerr ("\t%s: %hx:%hx:%hx\n", gnm_style_element_name [elem],
- GO_UINT_RGBA_R (color->go_color),
- GO_UINT_RGBA_G (color->go_color),
- GO_UINT_RGBA_B (color->go_color));
+ GO_COLOR_UINT_R (color->go_color),
+ GO_COLOR_UINT_G (color->go_color),
+ GO_COLOR_UINT_B (color->go_color));
else
g_printerr ("\t%s: (NULL)\n", gnm_style_element_name [elem]);
}
diff --git a/src/pattern.c b/src/pattern.c
index 7e767a5..75ebbad 100644
--- a/src/pattern.c
+++ b/src/pattern.c
@@ -118,9 +118,9 @@ gnumeric_background_set_gtk (GnmStyle const *mstyle, cairo_t *context)
double f = grey[pattern];
cairo_set_source_rgb (context,
- GO_DOUBLE_RGBA_R (c) * f,
- GO_DOUBLE_RGBA_G (c) * f,
- GO_DOUBLE_RGBA_B (c) * f);
+ GO_COLOR_DOUBLE_R (c) * f,
+ GO_COLOR_DOUBLE_G (c) * f,
+ GO_COLOR_DOUBLE_B (c) * f);
}
/* This is a special case where the user has selected
diff --git a/src/sheet-object-cell-comment.c b/src/sheet-object-cell-comment.c
index c6a030e..6e8817e 100644
--- a/src/sheet-object-cell-comment.c
+++ b/src/sheet-object-cell-comment.c
@@ -259,7 +259,7 @@ cell_comment_new_view (SheetObject *so, SheetObjectViewContainer *container)
GO_STYLED_OBJECT (goc_item_new (GOC_GROUP (view),
GOC_TYPE_POLYGON, NULL)));
style->line.dash_type = GO_LINE_NONE;
- style->fill.pattern.back = GO_RGBA_RED;
+ style->fill.pattern.back = GO_COLOR_RED;
return gnm_pane_object_register (so, view, FALSE);
}
diff --git a/src/style-color.c b/src/style-color.c
index 81b85cf..e8e42ab 100644
--- a/src/style-color.c
+++ b/src/style-color.c
@@ -66,7 +66,7 @@ style_color_new_gdk (GdkColor const *c)
GnmColor *
style_color_new_i8 (guint8 red, guint8 green, guint8 blue)
{
- return style_color_new_go (GO_RGBA_TO_UINT (red, green, blue, 0xff));
+ return style_color_new_go (GO_COLOR_FROM_RGBA (red, green, blue, 0xff));
}
GnmColor *
@@ -125,7 +125,7 @@ style_color_auto_font (void)
static GnmColor *color = NULL;
if (!color)
- color = style_color_new_uninterned (GO_RGBA_BLACK, TRUE);
+ color = style_color_new_uninterned (GO_COLOR_BLACK, TRUE);
return style_color_ref (color);
}
@@ -138,7 +138,7 @@ style_color_auto_back (void)
static GnmColor *color = NULL;
if (!color)
- color = style_color_new_uninterned (GO_RGBA_WHITE, TRUE);
+ color = style_color_new_uninterned (GO_COLOR_WHITE, TRUE);
return style_color_ref (color);
}
@@ -151,7 +151,7 @@ style_color_auto_pattern (void)
static GnmColor *color = NULL;
if (!color)
- color = style_color_new_uninterned (GO_RGBA_BLACK, TRUE);
+ color = style_color_new_uninterned (GO_COLOR_BLACK, TRUE);
return style_color_ref (color);
}
diff --git a/src/tools/ChangeLog b/src/tools/ChangeLog
index 7f1f380..b2e93cd 100644
--- a/src/tools/ChangeLog
+++ b/src/tools/ChangeLog
@@ -1,3 +1,21 @@
+2009-09-05 Jean Brefort <jean brefort normalesup org>
+
+ * scenarios.c (summary_cb), (scenario_summary): renamed go-color.h macros.
+
+2009-09-05 Jean Brefort <jean brefort normalesup org>
+
+ * ms-chart.c (end): don't use z values as x or y when there are no
+ labels or categories. [See #593937]
+
+2009-09-04 Jean Brefort <jean brefort normalesup org>
+
+ * ms-chart.c (axis), (xl_axis_get_elem), (valuerange): use gnm_go_data
+ instead of simple go_data [#594068],
+ (end): don't require x and y values for surfaces.
+
+2009-09-01 Jean Brefort <jean brefort normalesup org>
+
+
2009-08-30 Morten Welinder <terra gnome org>
* Release 1.9.11
diff --git a/src/tools/scenarios.c b/src/tools/scenarios.c
index db657d5..0b1255c 100644
--- a/src/tools/scenarios.c
+++ b/src/tools/scenarios.c
@@ -570,7 +570,7 @@ summary_cb (int col, int row, GnmValue *v, summary_cb_t *p)
/* Set the colors. */
dao_set_colors (&p->dao, 2 + p->col, 3 + *index,
2 + p->col, 3 + *index,
- style_color_new_go (GO_RGBA_BLACK),
+ style_color_new_go (GO_COLOR_BLACK),
style_color_new_gdk (&gs_light_gray));
} else {
@@ -593,7 +593,7 @@ summary_cb (int col, int row, GnmValue *v, summary_cb_t *p)
/* Set the colors. */
dao_set_colors (&p->dao, 2 + p->col, 3 + p->row,
2 + p->col, 3 + p->row,
- style_color_new_go (GO_RGBA_BLACK),
+ style_color_new_go (GO_COLOR_BLACK),
style_color_new_gdk (&gs_light_gray));
/* Insert row number into the hash table. */
@@ -724,10 +724,10 @@ scenario_summary (WorkbookControl *wbc,
dao_set_cell (&cb.dao, 0, 0, _("Scenario Summary"));
dao_set_colors (&cb.dao, 0, 0, cb.col + 1, 1,
- style_color_new_go (GO_RGBA_WHITE),
+ style_color_new_go (GO_COLOR_WHITE),
style_color_new_gdk (&gs_dark_gray));
dao_set_colors (&cb.dao, 0, 2, 0, 2 + cb.row,
- style_color_new_go (GO_RGBA_BLACK),
+ style_color_new_go (GO_COLOR_BLACK),
style_color_new_gdk (&gs_light_gray));
dao_set_align (&cb.dao, 1, 1, cb.col + 1, 1, HALIGN_RIGHT,
diff --git a/src/wbc-gtk.c b/src/wbc-gtk.c
index 5536c41..6829631 100644
--- a/src/wbc-gtk.c
+++ b/src/wbc-gtk.c
@@ -2804,7 +2804,7 @@ cb_fore_color_changed (GOActionComboColor *a, WBCGtk *wbcg)
c = go_action_combo_color_get_color (a, &is_default);
if (wbcg_is_editing (wbcg)) {
- GOColor c2 = is_default ? GO_RGBA_BLACK : c;
+ GOColor c2 = is_default ? GO_COLOR_BLACK : c;
wbcg_edit_add_markup (wbcg, go_color_to_pango (c2, TRUE));
return;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]