aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table/e-table-group-container.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@helixcode.com>2000-05-27 04:38:49 +0800
committerChris Lahey <clahey@src.gnome.org>2000-05-27 04:38:49 +0800
commit628ca43584542f85ffc3b6a1617af489607a8dea (patch)
tree71039a6aca0bd45f0650b29120f55cc8eb522a8e /widgets/table/e-table-group-container.c
parent7434b2831bd5604c6ee939c604cec5a91205b4d2 (diff)
downloadgsoc2013-evolution-628ca43584542f85ffc3b6a1617af489607a8dea.tar
gsoc2013-evolution-628ca43584542f85ffc3b6a1617af489607a8dea.tar.gz
gsoc2013-evolution-628ca43584542f85ffc3b6a1617af489607a8dea.tar.bz2
gsoc2013-evolution-628ca43584542f85ffc3b6a1617af489607a8dea.tar.lz
gsoc2013-evolution-628ca43584542f85ffc3b6a1617af489607a8dea.tar.xz
gsoc2013-evolution-628ca43584542f85ffc3b6a1617af489607a8dea.tar.zst
gsoc2013-evolution-628ca43584542f85ffc3b6a1617af489607a8dea.zip
Made "drawgrid", "drawfocus", "spreadsheet", and "length_threshold"
2000-05-26 Christopher James Lahey <clahey@helixcode.com> * e-table-group-container.c, e-table-group-container.h, e-table-group-leaf.c, e-table-group-leaf.h, e-table.c, e-table.h: Made "drawgrid", "drawfocus", "spreadsheet", and "length_threshold" arguments set from the ETable effect all the end ETableItems. * e-table-header.c: Made column resize a bit less bumpy. svn path=/trunk/; revision=3223
Diffstat (limited to 'widgets/table/e-table-group-container.c')
-rw-r--r--widgets/table/e-table-group-container.c63
1 files changed, 63 insertions, 0 deletions
diff --git a/widgets/table/e-table-group-container.c b/widgets/table/e-table-group-container.c
index e7771f86de..6c69d1765d 100644
--- a/widgets/table/e-table-group-container.c
+++ b/widgets/table/e-table-group-container.c
@@ -34,6 +34,10 @@ enum {
ARG_WIDTH,
ARG_MINIMUM_WIDTH,
ARG_FROZEN,
+ ARG_TABLE_DRAW_GRID,
+ ARG_TABLE_DRAW_FOCUS,
+ ARG_MODE_SPREADSHEET,
+ ARG_LENGTH_THRESHOLD,
};
typedef struct {
@@ -330,6 +334,12 @@ etgc_add (ETableGroup *etg, gint row)
NULL);
child = e_table_group_new (GNOME_CANVAS_GROUP (etgc), etg->full_header,
etg->header, etg->model, etgc->sort_info, etgc->n + 1);
+ gnome_canvas_item_set(GNOME_CANVAS_ITEM(child),
+ "drawgrid", etgc->draw_grid,
+ "drawfocus", etgc->draw_focus,
+ "spreadsheet", etgc->mode_spreadsheet,
+ "length_threshold", etgc->length_threshold,
+ NULL);
gtk_signal_connect (GTK_OBJECT (child), "row_selection",
GTK_SIGNAL_FUNC (child_row_selection), etgc);
child_node->child = child;
@@ -455,6 +465,45 @@ etgc_set_arg (GtkObject *object, GtkArg *arg, guint arg_id)
NULL);
}
break;
+ case ARG_LENGTH_THRESHOLD:
+ etgc->length_threshold = GTK_VALUE_INT (*arg);
+ for (list = etgc->children; list; list = g_list_next (list)) {
+ ETableGroupContainerChildNode *child_node = (ETableGroupContainerChildNode *)list->data;
+ gtk_object_set (GTK_OBJECT(child_node->child),
+ "length_threshold", GTK_VALUE_INT (*arg),
+ NULL);
+ }
+ break;
+
+ case ARG_TABLE_DRAW_GRID:
+ etgc->draw_grid = GTK_VALUE_BOOL (*arg);
+ for (list = etgc->children; list; list = g_list_next (list)) {
+ ETableGroupContainerChildNode *child_node = (ETableGroupContainerChildNode *)list->data;
+ gtk_object_set (GTK_OBJECT(child_node->child),
+ "draw_grid", GTK_VALUE_BOOL (*arg),
+ NULL);
+ }
+ break;
+
+ case ARG_TABLE_DRAW_FOCUS:
+ etgc->draw_focus = GTK_VALUE_BOOL (*arg);
+ for (list = etgc->children; list; list = g_list_next (list)) {
+ ETableGroupContainerChildNode *child_node = (ETableGroupContainerChildNode *)list->data;
+ gtk_object_set (GTK_OBJECT(child_node->child),
+ "draw_focus", GTK_VALUE_BOOL (*arg),
+ NULL);
+ }
+ break;
+
+ case ARG_MODE_SPREADSHEET:
+ etgc->mode_spreadsheet = GTK_VALUE_BOOL (*arg);
+ for (list = etgc->children; list; list = g_list_next (list)) {
+ ETableGroupContainerChildNode *child_node = (ETableGroupContainerChildNode *)list->data;
+ gtk_object_set (GTK_OBJECT(child_node->child),
+ "mode_spreadsheet", GTK_VALUE_BOOL (*arg),
+ NULL);
+ }
+ break;
default:
break;
}
@@ -508,6 +557,15 @@ etgc_class_init (GtkObjectClass *object_class)
e_group_class->set_focus = etgc_set_focus;
e_group_class->get_focus_column = etgc_get_focus_column;
+ gtk_object_add_arg_type ("ETableGroupContainer::drawgrid", GTK_TYPE_BOOL,
+ GTK_ARG_WRITABLE, ARG_TABLE_DRAW_GRID);
+ gtk_object_add_arg_type ("ETableGroupContainer::drawfocus", GTK_TYPE_BOOL,
+ GTK_ARG_WRITABLE, ARG_TABLE_DRAW_FOCUS);
+ gtk_object_add_arg_type ("ETableGroupContainer::spreadsheet", GTK_TYPE_BOOL,
+ GTK_ARG_WRITABLE, ARG_MODE_SPREADSHEET);
+ gtk_object_add_arg_type ("ETableGroupContainer::length_threshold", GTK_TYPE_INT,
+ GTK_ARG_WRITABLE, ARG_LENGTH_THRESHOLD);
+
gtk_object_add_arg_type ("ETableGroupContainer::frozen", GTK_TYPE_BOOL,
GTK_ARG_READWRITE, ARG_FROZEN);
gtk_object_add_arg_type ("ETableGroupContainer::height", GTK_TYPE_DOUBLE,
@@ -606,6 +664,11 @@ etgc_init (GtkObject *object)
container->children = FALSE;
e_canvas_item_set_reflow_callback (GNOME_CANVAS_ITEM(object), etgc_reflow);
+
+ container->draw_grid = 1;
+ container->draw_focus = 1;
+ container->mode_spreadsheet = 1;
+ container->length_threshold = -1;
}
E_MAKE_TYPE (e_table_group_container, "ETableGroupContainer", ETableGroupContainer, etgc_class_init, etgc_init, PARENT_TYPE);