From cc23e4d8b4342d7df4821b17a58e6aee0d896687 Mon Sep 17 00:00:00 2001 From: Christopher James Lahey Date: Sun, 15 Apr 2001 00:45:10 +0000 Subject: Added widget/e-hsv-utils.lo. 2001-04-14 Christopher James Lahey * gal/Makefile.am: Added widget/e-hsv-utils.lo. * gal/widgets/Makefile.am: Added e-hsv-utils.c and e-hsv-utils.h. * gal/widgets/e-hsv-utils.c, gal/widgets/e-hsv-utils.h: Moved from gal/e-table/e-table-hsv-utils.c and gal/e-table/e-table-hsv-utils.h. Handle modifying hue saturation and value of colors. 2001-04-13 Christopher James Lahey * gal/widgets/e-selection-model.c (e_selection_model_do_something): Always emit the cursor changed signal. Even if it's changed to the same row/column. svn path=/trunk/; revision=9318 --- widgets/table/e-table-item.c | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) (limited to 'widgets') diff --git a/widgets/table/e-table-item.c b/widgets/table/e-table-item.c index 8f2cee1b20..8997ccd610 100644 --- a/widgets/table/e-table-item.c +++ b/widgets/table/e-table-item.c @@ -22,6 +22,7 @@ #include #include "e-table-subset.h" #include "e-cell.h" +#include "gal/widgets/e-hsv-utils.h" #include "gal/widgets/e-canvas.h" #include "gal/widgets/e-canvas-utils.h" #include "gal/util/e-util.h" @@ -1222,6 +1223,8 @@ eti_unrealize (GnomeCanvasItem *item) (*GNOME_CANVAS_ITEM_CLASS (eti_parent_class)->unrealize)(item); } + + static void eti_draw (GnomeCanvasItem *item, GdkDrawable *drawable, int x, int y, int width, int height) { @@ -1371,22 +1374,18 @@ eti_draw (GnomeCanvasItem *item, GdkDrawable *drawable, int x, int y, int width, else background = &canvas->style->bg [GTK_STATE_ACTIVE]; } else { + background = &canvas->style->base [GTK_STATE_NORMAL]; + } + #if 0 - if (row % 2) -#endif - background = &canvas->style->base [GTK_STATE_NORMAL]; -#if 0 - else { - free_background = TRUE; - background = gdk_color_copy (&canvas->style->base [GTK_STATE_NORMAL]); - background->red -= 25000; - background->green += 25000; - background->blue -= 25000; - - gdk_color_alloc (gtk_widget_get_colormap (GTK_WIDGET (canvas)), background); - } -#endif + if (row % 2) { + + } else { + free_background = TRUE; + e_hsv_tweak (background, 0.0f, 0.0f, -0.05f); + gdk_color_alloc (gtk_widget_get_colormap (GTK_WIDGET (canvas)), background); } +#endif gdk_gc_set_foreground (eti->fill_gc, background); gdk_draw_rectangle (drawable, eti->fill_gc, TRUE, -- cgit v1.2.3