From dcd4f312232db7d391b1dd969f271f9a65c540c1 Mon Sep 17 00:00:00 2001 From: Christopher James Lahey Date: Tue, 19 Dec 2000 15:58:24 +0000 Subject: Set the minimum width of newly created children. 2000-12-19 Christopher James Lahey * e-table-group-container.c (etgc_add): Set the minimum width of newly created children. (e_table_group_container_construct): Use function e_table_header_get_column_by_col_idx instead of e_table_header_get_column since we're passing in a col_idx. * e-table-header.c, e-table-header.h: New function e_table_header_get_column_by_col_idx which searches for a column in the ETableHeader with a certain model column (col_idx). * e-table-sorted-variable.c (etsv_compare), (etsv_sort), e-table-sorter.c (ets_sort): Use function e_table_header_get_column_by_col_idx instead of e_table_header_get_column since we're passing in a col_idx. svn path=/trunk/; revision=7079 --- widgets/table/e-table-group-container.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'widgets/table/e-table-group-container.c') diff --git a/widgets/table/e-table-group-container.c b/widgets/table/e-table-group-container.c index 5e2b86c800..194e744f8c 100644 --- a/widgets/table/e-table-group-container.c +++ b/widgets/table/e-table-group-container.c @@ -118,10 +118,9 @@ e_table_group_container_construct (GnomeCanvasGroup *parent, ETableGroupContaine ETableCol *col; ETableSortColumn column = e_table_sort_info_grouping_get_nth(sort_info, n); - if (column.column > e_table_header_count (full_header)) + col = e_table_header_get_column_by_col_idx(full_header, column.column); + if (col == NULL) col = e_table_header_get_column (full_header, e_table_header_count (full_header) - 1); - else - col = e_table_header_get_column (full_header, column.column); e_table_group_construct (parent, E_TABLE_GROUP (etgc), full_header, header, model); etgc->ecol = col; @@ -401,7 +400,9 @@ etgc_add (ETableGroup *etg, gint row) "cursor_mode", etgc->cursor_mode, "table_selection_model", etgc->table_selection_model, "length_threshold", etgc->length_threshold, + "minimum_width", etgc->minimum_width - GROUP_INDENT, NULL); + gtk_signal_connect (GTK_OBJECT (child), "cursor_change", GTK_SIGNAL_FUNC (child_cursor_change), etgc); gtk_signal_connect (GTK_OBJECT (child), "double_click", -- cgit v1.2.3