Commit Graph

152 Commits

Author SHA1 Message Date
8b6b6f01bf Make a key press stop the tooltip timeout.
2001-05-11  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c (eti_event): Make a key press stop the tooltip
	timeout.

	* e-table-state.c (e_table_state_load_from_node): Make the default
	expansion be one so that if the user doesn't specify any
	expansions they get a uniform expansion.

svn path=/trunk/; revision=9769
2001-05-11 20:07:14 +00:00
2d3c06b3a4 (Make the alternating row colors a option in ETableSpecification instead
2001-04-28  Jason Leach  <jasonleach@usa.net>

	(Make the alternating row colors a option in ETableSpecification
	instead of a compiled in #define)

	* e-table-specification.c (e_table_specification_load_from_node):
	Read in the "alternating-row-colors=bool" option for
	ETableSpecifications.  Default value is true so unless it is
	specified to be false, row colors will alternate.
	(e_table_specification_save_to_node): Save the alternating row
	color options here.

	* e-table.c (et_build_groups): Pass down the alternating row
	colors through to the ETableGroup.

	* e-table-group-container.[ch]: Handle the new alternating row
	colors
	option here, passing it to ETableItem.

	* e-table-group-leaf.[ch]: Here too.

	* e-table-item.c (eti_get_cell_background_color): Got rid of the
	#define ALTERNATE_COLORS, replaced with truth check for
	ETableItem::alternating_row_colors.

	* e-tree.c: Make ETree recognize alternating row color options as
	well.

svn path=/trunk/; revision=9622
2001-04-29 01:14:50 +00:00
44c7d23144 Added get_cell_geometry method.
2001-04-23  Christopher James Lahey  <clahey@ximian.com>

	* e-table-group-container.c, e-table-group-leaf.c,
	e-table-group.c, e-table-group-.h: Added get_cell_geometry method.

	* e-table-item.c, e-table-item.h: Added
	e_table_item_get_cell_geometry.

	* e-table.c, e-table.h: Added e_table_get_cell_geometry.

svn path=/trunk/; revision=9532
2001-04-24 01:30:48 +00:00
270a8bdda8 Submit a signal even if there are no extras.
2001-04-19  Christopher James Lahey  <clahey@ximian.com>

	* e-table-header.c (eth_calc_widths): Submit a signal even if
	there are no extras.

	* e-table-item.c (eti_request_column_width): Don't compute widths
	if our cells aren't realized yet.

	* e-tree.c: Call e_table_header_update_horizontal whenever our
	data changes.

svn path=/trunk/; revision=9465
2001-04-20 02:00:23 +00:00
40e3cd8538 Turned off information expanders (tooltips) in ETable by default. Turn
2001-04-19  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c: Turned off information expanders (tooltips) in
	ETable by default.  Turn them back on with the environment
	variable GAL_DO_TOOLTIPS.

svn path=/trunk/; revision=9462
2001-04-19 23:37:00 +00:00
2c9c9695d6 Turned on tooltips and alternating colors.
2001-04-16  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c: Turned on tooltips and alternating colors.

svn path=/trunk/; revision=9393
2001-04-16 22:40:52 +00:00
bf3357b91e Set the background color to the specified tooltip->background. Set the
2001-04-15  Christopher James Lahey  <clahey@ximian.com>

	* e-cell-text.c (ect_show_tooltip): Set the background color to
	the specified tooltip->background.  Set the foreground color to
	the specified tooltip->foreground.

	* e-table-item.c (eti_get_cell_background_color,
	eti_get_cell_foreground_color): Added these functions.
	(eti_draw, _do_tooltip): Use these new functions.

	* e-table-tooltip.h: Added foreground and background colors to
	this structure.

	* e-tree.c, e-tree.h (e_tree_get_tooltip): Added this function.

svn path=/trunk/; revision=9338
2001-04-16 02:12:44 +00:00
55b44f1c46 Added /* #defines */ at the top. Fixed ALTERNATE_COLORS to be an #ifdef
2001-04-15  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c: Added /* #defines */ at the top.  Fixed
	ALTERNATE_COLORS to be an #ifdef instead of an #if.

	* e-cell-text.c (ect_show_tooltip): Set "strikeout" argument on
	created tooltip.

svn path=/trunk/; revision=9328
2001-04-15 16:52:41 +00:00
9e995f6b8e Use e_canvas_hide_tooltip and e_canvas_popup_tooltip.
2001-04-15  Christopher James Lahey  <clahey@ximian.com>

	* e-cell-text.c (tooltip_event): Use e_canvas_hide_tooltip and
	e_canvas_popup_tooltip.

	* e-table-item.c: Cleaned this up.  Removed some #if 0 and
	replaced others with #ifdefs.

	* e-table-tooltip.h: Removed some unnecessary fields.

svn path=/trunk/; revision=9326
2001-04-15 16:20:02 +00:00
1e4ac4feb6 Cleaned this up. Removed some #if 0 and replaced others with #ifdefs.
2001-04-15  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c: Cleaned this up.  Removed some #if 0 and
	replaced others with #ifdefs.

svn path=/trunk/; revision=9321
2001-04-15 13:07:49 +00:00
61353c59dc Set "bold" argument on created tooltip. Adjusted position of displayed
2001-04-15  Christopher James Lahey  <clahey@ximian.com>

	* e-cell-text.c (ect_show_tooltip): Set "bold" argument on created
	tooltip.  Adjusted position of displayed tooltip.

	* e-cell-tree.c (offset_of_node): Changed it so that this function
	handles knowing whether on not to indent non expandable first
	level nodes.  This makes things more consistent.

	* e-table-item.c (eti_realize): Cleaned up the ETableItem code to
	properly hide tooltips when going off the screen.

	* e-table-tooltip.h: Added a visibility_count field to ETableTooltip.

svn path=/trunk/; revision=9320
2001-04-15 13:03:26 +00:00
cc23e4d8b4 Added widget/e-hsv-utils.lo.
2001-04-14  Christopher James Lahey  <clahey@ximian.com>

	* 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  <clahey@ximian.com>

	* 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
2001-04-15 00:45:10 +00:00
0f85f30ab1 Upped the version number to 0.6.99.0. Upped the so number to 6.
2001-04-12  Christopher James Lahey  <clahey@ximian.com>

	* configure.in: Upped the version number to 0.6.99.0.  Upped the
	so number to 6.

	* docs/etablexml.txt: Made some updates here.

	* tests/test-tree-1.c, tests/test-tree-3.c: Added NULL, NULL to
	the call to e_tree_memory_callbacks_new.

From gal/e-table/ChangeLog:

2001-04-12  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c (eti_cursor_change): Only move the screen to show
	the cursor if there are no changes pending.  Updated the commented
	out code for alternating colors a bit.

	* e-table-model.c, e-table-model.h: Added
	e_table_model_has_change_pending.

	* e-tree-memory-callbacks.c, e-tree-memory-callbacks.h: Added
	has_get_node_by_id and get_node_by_id.

	* e-tree-model.c, e-tree-model.h: Added
	e_tree_model_has_get_node_by_id and e_tree_model_get_node_by_id.
	Added e_tree_model_has_change_pending.

	* e-tree-selection-model.c: Handle the selection and cursor
	properly across the tree changing.

	* e-tree-sorted.c: Implemented has_get_node_by_id and
	get_node_by_id, and has_changes_pending.

	* e-tree-table-adapter.c: Implemented has_changes_pending.  Fixed
	an array underflow.

svn path=/trunk/; revision=9289
2001-04-13 00:40:49 +00:00
6905c1b233 Put debugging stuff in d().
2001-04-10  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c: Put debugging stuff in d().

svn path=/trunk/; revision=9220
2001-04-11 02:13:05 +00:00
f37767da8e Changed resizeable to resizable in ETableCol for consistency.
2001-04-09  Christopher James Lahey  <clahey@ximian.com>

	* e-table-col.c, e-table-col.h, e-table-header-item.c,
	e-table-header.c, e-table-item.c: Changed resizeable to resizable
	in ETableCol for consistency.

	* e-tree-selection-model.c (etsm_row_of_node): Return -1 here if
	the path isn't found.
	(etsm_sorted_node_changed): If cursor_row is -1, make cursor_col
	-1 as well.

svn path=/trunk/; revision=9211
2001-04-10 03:22:33 +00:00
48200fbd57 Fixed headers.
2001-04-04  Christopher James Lahey  <clahey@ximian.com>

	* e-table-config.c, e-table-item.c, e-table-memory.c,
	e-table-sort-info.c, e-table-specification.c, e-tree-sorted.c:
	Fixed headers.

	* e-table-config.c, e-table-specification.c: Replaced strcasecmp
	with g_strcasecmp.

svn path=/trunk/; revision=9174
2001-04-04 12:13:38 +00:00
08940ce6f6 Fix headers. Ditto. Ditto. Ditto. Ditto. Ditto. Ditto. Ditto. Ditto.
2001-04-04  Kjartan Maraas  <kmaraas@gnome.org>

	* e-cell-date.c: Fix headers.
	* e-cell-number.c: Ditto.
	* e-cell-pixbuf.[ch]: Ditto.
	* e-cell-size.c: Ditto.
	* e-cell-text.c: Ditto.
	* e-cell-tree.c: Ditto.
	* e-table-click-to-add.[ch]: Ditto.
	* e-table-column-specification.h: Ditto.
	* e-table-config-field.c: Ditto.
	* e-table-config.[ch]: Ditto.
	* e-table-example-2.c: Ditto.
	* e-table-field-chooser-dialog.[ch]: Ditto.
	* e-table-field-chooser-item.c: Ditto.
	* e-table-field-chooser.h: Ditto.
	* e-table-group-container.c: Ditto.
	* e-table-item.c: Ditto
	* e-table-memory.c: Ditto.
	* e-table-selection-model.c: Ditto.
	* e-table-sorter.c: Ditto.
	* e-table-subset-variable.c: Ditto.
	* e-table.c: Ditto.
	* e-tree-memory.c: Ditto.
	* e-tree-model.c: Ditto.
	* e-tree-selection-model.[ch]: Ditto.
	* e-tree-sorted-variable.c: Ditto.
	* e-tree-sorted.c: Ditto.
	* e-tree-table-adapter.c: Ditto.
	* e-tree.[ch]: Same here.

svn path=/trunk/; revision=9164
2001-04-04 05:24:34 +00:00
90ed53edb0 Made these use GTK_TYPE_GDK_EVENT whenever sending an event through the
2001-03-30  Christopher James Lahey  <clahey@ximian.com>

	* e-table-group.c, e-table-header-item.c, e-table-item.c,
	e-table.c, e-tree.c: Made these use GTK_TYPE_GDK_EVENT whenever
	sending an event through the signal system instead of
	GTK_TYPE_POINTER.

	* e-table.c, e-tree.c (set_header_canvas_width): Check that none
	of the variables we're going to need are NULL before executing
	this function.

svn path=/trunk/; revision=9042
2001-03-30 10:30:28 +00:00
0e347fdbe1 Changed the signal "table_selection_model" to just be "selection_model"
2001-03-30  Christopher James Lahey  <clahey@ximian.com>

	* e-table-group-container.c, e-table-group-container.h,
	e-table-group-leaf.c, e-table-group-leaf.h, e-table-item.c,
	e-table-item.h, e-table.c, e-tree.c: Changed the signal
	"table_selection_model" to just be "selection_model" everywhere
	and made it be ESelectionModels instead of ETableSelectionModels
	for generality.

	* e-table-item.c (eti_event): Make right arrow and left arrow
	accessible as events that can be caught.

	* e-tree-sorted.c, e-tree-sorted.h (e_tree_sorted_orig_position):
	Added this function.

svn path=/trunk/; revision=9041
2001-03-30 08:52:04 +00:00
320e990197 Ignore these signals if we aren't realized yet.
2001-03-23  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c (eti_cursor_change, eti_cursor_activated): Ignore
	these signals if we aren't realized yet.

svn path=/trunk/; revision=8917
2001-03-23 15:46:50 +00:00
e4affa9382 Made this not create the new font until realize instead of at new_view
2001-03-23  Christopher James Lahey  <clahey@ximian.com>

	* e-cell-text.c: Made this not create the new font until realize
	instead of at new_view time.

	* e-table-item.c: Don't request heights or do other things that
	you aren't allowed to do before realization unless you're
	realized.

svn path=/trunk/; revision=8915
2001-03-23 06:46:46 +00:00
451c410dec Bumped the version number to 05.99.9.
2001-03-20  Christopher James Lahey  <clahey@ximian.com>

	* configure.in: Bumped the version number to 05.99.9.

From gal/e-table/ChangeLog:

2001-03-20  Christopher James Lahey  <clahey@ximian.com>

	* e-table-click-to-add.c: Turn on the vertical grid.

	* e-table-group-container.c, e-table-group-container.h,
	e-table-group-leaf.c, e-table-group-leaf.h, e-table-item.c,
	e-table-item.h: Replaced the "drawgrid" argument with
	"horizontal_draw_grid" and "vertical_draw_grid" arguments.

	* e-table-specification.c, e-table-specifcation: Replaced the
	draw_grid setting with the horizontal_draw_grid and
	vertical_draw_grid settings.  If the draw-grid property is set in
	a ETableSpecification it is still obeyed and overrides the
	vertical-draw-grid and horizontal-draw-grid properties.

	* e-table.c, e-table.h, e-tree.c, e-tree.h: Deal with the
	horizontal_draw_grid and vertical_draw_grid changes.

	* e-tree-model.h: Added a missing include.

svn path=/trunk/; revision=8846
2001-03-20 16:22:30 +00:00
1510304c2d Deal with proxy_node_changed being called on a different root node than
2001-03-19  Christopher James Lahey  <clahey@ximian.com>

	* e-tree-sorted.c (ets_proxy_node_changed): Deal with
	proxy_node_changed being called on a different root node than the
	one we have in our tree.

	* e-tree-table-adapter.c: Did some general clean up here.

	* Merged branch:

2001-03-19  Christopher James Lahey  <clahey@ximian.com>

	* e-tree-sorted.c (find_child_path): Added this function to allow
	us to find paths that have been removed from the source.
	(ets_proxy_node_removed): Fixed the memmove here a bit.  Call
	find_child_path.

	* e-tree-table-adapter.c (find_node): Check that the passed in
	path isn't NULL.

2001-03-19  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c (eti_reflow): Get width from header object
	instead of calculating it ourselves.

	* e-table-selection-model.c: Turn off selection saving since it's
	so slow.

	* e-table.c (e_table_set_state_object): Set the width of the newly
	created header object.

	* e-tree.c (e_tree_set_state_object): Set the width of the newly
	created header object.
	(tree_canvas_size_allocate): Don't bother setting the dimensions
	of the white background twice.

2001-03-18  Christopher James Lahey  <clahey@ximian.com>

	* e-table-selection-model.c, e-table-selection-model.h: Made
	ETableSelectionModel save the cursor properly across changed
	signals if has_save_id is true.

2001-03-18  Christopher James Lahey  <clahey@ximian.com>

	* e-table-selection-model.c, e-table-selection-model.h: Made
	ETableSelectionModel save selection properly across changed
	signals if has_save_id is true.

	* e-tree-memory.c: A couple of typos.

2001-03-18  Christopher James Lahey  <clahey@ximian.com>

	* e-tree-memory.c, e-tree-sorted.c: Send pre_changes properly.

2001-03-18  Christopher James Lahey  <clahey@ximian.com>

	* e-tree-table-adapter.c: Send pre_changes when performing
	set_expanded or root_node_set_visible.

2001-03-18  Christopher James Lahey  <clahey@ximian.com>

	* e-tree-sorted.c (ets_is_expandable): When the API requests
	whether the object is expandable and it isn't, make sure to send a
	signal when it becomes expandable.

	* e-tree-table-adapter.c: Made it so that in a number of cases
	where it doesn't need to create an empty hash table node if the
	current tree node has no children, it doesn't.

2001-03-18  Christopher James Lahey  <clahey@ximian.com>

	* e-tree-memory-callbacks.c, e-tree-memory-callbacks.h
	(etmc_has_save_id, etmc_get_save_id): Added has_save_id and
	get_save_id to the list of methods supported by
	e_tree_memory_callbacks.

	* e-tree-table-adapter.c, e-tree-table-adapter.h: Added saving of
	expanded nodes.

2001-03-18  Christopher James Lahey  <clahey@ximian.com>

	* e-table-model.c, e-table-model.h (e_table_model_get_save_id):
	Changed row_save_id to get_save_id to be consistent with ETree.

	* e-tree-model.c, e-tree-model.h: Added "pre_change" signal.
	Added has_save_id and get_save_id methods.

	* e-tree-sorted.c: Proxy pre_change signal.  Implemented
	has_save_id and get_save_id.  If the base model doesn't provide
	has_save_id then we g_strdup_printf the pointer of the base model
	ETreePath as the save_id.

	* e-tree-table-adapter.c: Proxy pre_change signal.  If base model
	has_save_id, then use the results of get_save_id as the key for
	the hash table of node attributes.  Otherwise use the pointer as
	before.

2001-03-17  Christopher James Lahey  <clahey@ximian.com>

	* e-tree-sorted.c (ets_sort_idle): Fixed it so that all nodes get
	sorted properly instead of just the top node.

2001-03-17  Christopher James Lahey  <clahey@ximian.com>

	* e-table-sorting-utils.c (e_table_sorting_utils_tree_sort): Made
	tree sorting faster by using a cache.

	* e-tree-sorted.c: Added commented out debugging g_prints.

2001-03-17  Christopher James Lahey  <clahey@ximian.com>

	* e-tree-sorted.c: Switched to using GMemChunks.

2001-03-17  Christopher James Lahey  <clahey@ximian.com>

	* e-tree-sorted.c (resort_node): Made it so that children of a
	node that's being sorted don't send changed signals.

2001-03-17  Christopher James Lahey  <clahey@ximian.com>

	* e-table-sorting-utils.c, e-table-sorting-utils.h: Switched to
	using e_sort and e_search instead of qsort and a linear search.
	Added the tree functions e_table_sorting_utils_tree_sort,
	e_table_sorting_utils_tree_check_position, and
	e_table_sorting_utils_tree_insert.

	* e-tree-sorted.c: Made this actually do sorting.

	* e-tree-table-adapter.c (etta_proxy_node_changed): The old_size
	needs to be the number of visible children + 1 to include the top
	node.

	* e-tree.c (e_tree_set_state_object): Set the sort_info on the
	ETreeSorted when you get a new sort_info.

2001-03-16  Christopher James Lahey  <clahey@ximian.com>

	* Makefile.am: Added e-tree-sorted.c and e-tree-sorted.h.

	* e-table-item.c (eti_realize_cell_views): Only realize the cells
	if they're not realized already and if the canvas is realized.

	* e-table-sorted.c (ets_proxy_model_cell_changed): Matched the
	change to the signature of e_table_sorting_utils_affects_sort.

	* e-table-sorting-utils.c, e-table-sorting-utils.h
	(e_table_sorting_utils_affects_sort): Changed the signature of
	this function to not take the ETableModel source since it doesn't
	use it and we need to use this function for ETreeSorted which
	doesn't have an ETableModel.

	* e-tree-memory.c (etmm_get_expanded_default): Actually implement
	the get_expanded_default for this tree.

	* e-tree-model.h: Cleaned up the indentation here.

	* e-tree-sorted.c, e-tree-sorted.h: New class meant to be used for
	sorting trees.  It doesn't actually sort yet.  It simply acts as
	an ETreeProxy which is the hardest part of making ETreeSorted.

	* e-tree.c, e-tree.h: Made this use an ETreeSorted.

2001-03-14  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c, e-table-item.h, e-table-selection-model.c,
	e-table-selection-model.h, e-table-sorted.c, e-table-sorted.h,
	e-table-subset.c, e-table-subset.h, e-table.c, e-table.h: Switch
	to handling e_table_model_rows_inserted instead of
	e_table_model_row_inserted and e_table_model_rows_deleted instead
	of e_table_model_row_deleted.

	* e-table-model.c, e-table-model.h: Replaced the signals
	"model_row_inserted" and "model_row_deleted" with
	"model_rows_inserted" and "model_rows_deleted" so that when
	multiple rows are inserted or deleted at the same time they can be
	handled properly.

	* e-tree-table-adapter.c: Call "model_rows_inserted" and
	"model_rows_deleted" instead of "model_changed" when inserting or
	deleting multiple rows.

2001-03-14  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c (e_table_item_row_diff): Made this not count the
	pixel between rows if it isn't there.

2001-03-14  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c (eti_header_structure_changed): Properly attach &
	realize cell views here.

2001-03-13  Christopher James Lahey  <clahey@ximian.com>

	* e-tree-table-adapter.c (etta_proxy_node_removed): Check that
	parent_node and parent aren't NULL before making function calls on
	them.

2001-03-13  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c (confirm_height_cache): Fixed a height cache
	miscalculation.

	* e-tree-table-adapter.c (find_first_child_node): Made the
	semantics of this mean that find_first_child_node(adapter, -1)
	means return the first node in the tree.

2001-03-13  Christopher James Lahey  <clahey@ximian.com>

	* e-table-extras.c: Added a "string-integer" comparison function
	to the default %ETableExtras so you can do comparisons based on
	integer value even if you using strings for the data (this lets
	you do editable numbers, for instance.)

	* e-table-item.c: Rearranged it a bit so that if you have
	draw_grid off it doesn't add space for the horizontal lines, nor
	leave them the background color.

	* e-table-model.c, e-table-model.h: Added the row_save_id and
	has_save_id methods to %ETableModel.

	* e-tree.c, e-tree.h: Replaced e_tree_compute_location with
	e_tree_get_cell_at.

2001-03-08  Christopher James Lahey  <clahey@ximian.com>

	* Makefile.am: Added e-table/e-table-utils.c,
	e-table/e-tree-memory-callbacks.c, e-table/e-tree-memory.c,
	e-table/e-tree-scrolled.c, e-table/e-tree-table-adapter.c, and
	e-table/e-tree.c.  Removed e-table/e-tree-simple.c.  Added
	e-table/e-table-utils.h, e-table/e-tree-memory-callbacks.h,
	e-table/e-tree-memory.h, e-table/e-tree-scrolled.h,
	e-table/e-tree-table-adapter.h, and e-table/e-tree.h.  Removed
	e-table/e-tree-simple.h.

	* e-cell-tree.c: Updated this for the new tree.

	* e-table-item.c: Added some redraw requests where appropriate.

	* e-table-item.h: Fixed an incorrect class method declaration.

	* e-table-model.c, e-table-model.h: Removed
	e_table_model_has_sort_group and e_table_model_row_sort_group.

	* e-table-scrolled.h: Removed unused headers.

	* e-table-simple.c, e-table-simple.h: Rearranged this a bit.

	* e-table-sorter.c, e-table-sorting-utils.c,
	e-table-sorting-utils.h: Removed sort group stuff.  Added the
	function e_table_sorting_utils_check_position.

	* e-table-utils.c, e-table-utils.h: Utility functions for ETable
	and ETree.

	* e-table.c: Moved some of the functionality from here to
	e-table-utils.c so that it can be reused by ETree.

	* e-tree-memory-callbacks.c, e-tree-memory-callbacks.h: Class to
	implement an ETreeMemory as callbacks instead of overriding the
	class.

	* e-tree-memory.c, e-tree-memory.h: ETreeModel that stores a tree
	of physical nodes.

	* e-tree-model.c, e-tree-model.h: Removed most of the
	functionality from here to the classes ETreeMemory and
	ETreeTableAdapter.  This is now just a simple virtualized tree
	class.

	* e-tree-scrolled.c, e-tree-scrolled.h: New class.  An ETree in an
	EScrollFrame.

	* e-tree-simple.c: Small change.  This is no longer used.

	* e-tree-table-adapter.c, e-tree-table-adapter.h: ETableModel that
	represents an ETreeModel as a table.

	* e-tree.c, e-tree.h: New super class kind of like ETable but for
	trees.

End of branch

svn path=/trunk/; revision=8837
2001-03-20 04:43:42 +00:00
d7f5b9e1a8 Update arguments to e_canvas_item_grab_focus. (eti_cursor_change): Ditto,
* e-table-item.c (eti_event): Update arguments to
	e_canvas_item_grab_focus.
	(eti_cursor_change): Ditto, but pass FALSE! Fixes the problem of
	the Evolution message list stealing your focus when new mail
	arrives. Ha!

svn path=/trunk/; revision=8746
2001-03-15 22:48:28 +00:00
6a8d4951dc Changed e_table_selection_model_clear to e_selection_model_clear.
2001-02-27  Christopher James Lahey  <clahey@ximian.com>

	* gal/e-text/e-completion-view.c: Changed
	e_table_selection_model_clear to e_selection_model_clear.

	* tests/test-tree-3.c: Changed E_TABLE_CURSOR_LINE to
	E_CURSOR_LINE.

From gal/e-table/ChangeLog:

2001-02-27  Christopher James Lahey  <clahey@ximian.com>

	* e-table-click-to-add.c, e-table-group-container.c,
	e-table-group-container.h, e-table-group-leaf.c,
	e-table-group-leaf.h, e-table-item.c, e-table-item.h,
	e-table-specification.c, e-table-specification.h, e-table.c,
	e-table.h: Changed a lot of the ETableSelectionModels to
	ESelectionModels, a lot of the ETableSorters to ESorters, all the
	ETableCursorModes to ECursorModes, and all of the
	ETableForeachFuncs into EForeachFuncs.

	* e-table-defines.h: Moved ETableForeachFunc and ETableCursorMode
	to e-selection-model.h.

	* e-table-selection-model.c, e-table-selection-model.h: Made this
	a subclass of ESelectionModel which simple connects to an
	ETableModel.

	* e-table-sorter.c, e-table-sorter.h: Made this a subclass of
	ESorter so that implements the same semantics it used to.

svn path=/trunk/; revision=8422
2001-02-28 03:36:29 +00:00
e65ce47c20 new abstract ECell subclass to be used as base class for popup ECells.
2001-02-25  Damon Chaplin  <damon@ximian.com>

	* e-cell-popup.c: new abstract ECell subclass to be used as base class
	for popup ECells.

	* e-cell-combo.c: subclass of ECellPopup which pops up a simple list
	of strings.

	* e-table-item.c: Renamed eti_row_diff() to e_table_item_row_diff() and
	made public, since the ECellPopup subclasses need it.

	* Makefile.am: added e-cell-popup.[hc] and e-cell-combo.[hc]

svn path=/trunk/; revision=8387
2001-02-25 19:29:40 +00:00
9aca6f5902 Fix the crash when ETableItems are destroyed.
2001-02-13  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c (eti_destroy): Fix the crash when ETableItems are
	destroyed.

svn path=/trunk/; revision=8207
2001-02-13 18:39:39 +00:00
c2f71c6730 Let e_canvas_item_show_area_delayed deal with a delayed area show instead
2001-02-11  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c (eti_cursor_change): Let
	e_canvas_item_show_area_delayed deal with a delayed area show
	instead of dealing with it ourselves.

svn path=/trunk/; revision=8169
2001-02-11 05:53:32 +00:00
9a8b904d09 Make this not error out if ecol is not found, but simply return -1.
2001-02-04  Christopher James Lahey  <clahey@ximian.com>

	* e-table-item.c (view_to_model_col): Make this not error out if
	ecol is not found, but simply return -1.
	(eti_event): Don't call view_to_model_col here as we already have
	a model column.

svn path=/trunk/; revision=7960
2001-02-04 20:00:00 +00:00
82de3a557c make the segfault caused by double clicking into a critical warning until
2001-01-31  Larry Ewing  <lewing@ximian.com>

	* e-table-item.c (view_to_model_col): make the segfault caused by
	double clicking into a critical warning until it can be fixed.

svn path=/trunk/; revision=7927
2001-01-31 23:24:30 +00:00
da03d43325 Made the contained %ETableItem have cursor_mode as
2001-01-30  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-click-to-add.c (etcta_event): Made the contained
	%ETableItem have cursor_mode as %E_TABLE_CURSOR_SPREADSHEET.

	* e-table-defines.h, e-table-item.c, e-table-specification.c:
	Added a new cursor mode E_TABLE_CURSOR_SPREADSHEET.  This is
	accessed using cursor_mode="spreadsheet" in your specification
	xml, as well as by the click_to_add item.  It is identical to
	E_TABLE_CURSOR_SIMPLE, except that tab goes to the next item in
	the table instead of to the next widget.

svn path=/trunk/; revision=7910
2001-01-30 11:37:34 +00:00
8ee392b8a3 Made carriage return finish editing.
2001-01-30  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-click-to-add.c (etcta_event): Made carriage return
	finish editing.

	* e-table-item.c (eti_event): Made carriage return key press
	signal go out before sending it to the selection model.

svn path=/trunk/; revision=7909
2001-01-30 11:14:18 +00:00
b924182143 Made the scrolling to show the current roll happen in a time out.
2001-01-28  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-item.c, e-table-item.h: Made the scrolling to show the
	current roll happen in a time out.

svn path=/trunk/; revision=7875
2001-01-28 12:38:29 +00:00
a7a767287f Make home and end keys move to the beginning and end of the row if cursor
2001-01-27  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-item.c (eti_event): Make home and end keys move to the
	beginning and end of the row if cursor mode is set to
	E_TABLE_CURSOR_SIMPLE.  Otherwise have %ETableSelectionModel
	handle them.

	* e-table-selection-model.c, e-table-selection-model.h: Added a
	"cursor_mode" argument.
	(e_table_selection_model_key_press): Made home and end keys move
	the beginning and end of the table if cursor_mode is
	E_TABLE_CURSOR_MODE_LINE.

	* e-table.c: Set the cursor-mode argument of our
	%ETableSelectionModel.

svn path=/trunk/; revision=7864
2001-01-27 22:21:10 +00:00
133b44558c Make ETable stop editing when it looses focus.
2001-01-27  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-item.c (eti_event): Make ETable stop editing when it
	looses focus.

	* e-table.c (et_canvas_button_press): Make ETable stop editing if
	you click on an unhandled area of the table canvas (The white area
	at the bottom for instance.)

svn path=/trunk/; revision=7849
2001-01-27 06:43:39 +00:00
9c73622d38 Documented. Added a "cursor_activated" signal. Removed some unused
2001-01-25  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-group-container.c, e-table-group-leaf.c,
	e-table-group.c, e-table-group.h, e-table-item.c, e-table-item.h:
	Documented.  Added a "cursor_activated" signal.  Removed some
	unused functions (e_table_group_get_count and
	e_table_group_get_ecol).

	* e-table-selection-model.c, e-table-selection-model.h: Added a
	"cursor_activated" signal.  Call it when the user changes the
	selection to match the cursor.

	* e-table.c, e-table.h: Added a "cursor_activated" signal.  Fixed
	the e_table_compute_location function to take into account the
	scrolled position.

svn path=/trunk/; revision=7808
2001-01-25 14:48:39 +00:00
7d1cbbaa10 Made this conform to the new prototype for e_popup_menu_run.
2001-01-21  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-header-item.c (ethi_header_context_menu): Made this
	conform to the new prototype for e_popup_menu_run.

	* e-table-item.c, e-table-item.h: Documented.
	(e_table_item_is_row_selected): Removed this function.
	(eti_draw): Changed this so that if the ETableItem is in
	cursor-mode="row", the cursor is draw all the way across the row.
	(eti_cursor_move_up, eti_cursor_move_down): Commented these out
	since they're no longer used.
	(_do_tooltip, eti_event): Commented out tooltips.
	(eti_event): Made it so that we call the key_press function in the
	%ETableSelectionModel on each key press.

	* e-table-selection-model.c, e-table-selection-model.h:
	Documented.  Added a function e_table_selection_model_key_press
	that does whatever behavior is correct for the user having pressed
	the given key.  Changed the behavior of this to better match
	windows (use selection-mode="browse").

	* e-table-specification.c, e-table-specification.h: Added a
	draw_focus variable.

	* e-table.c: Decide whether to draw the focus based on the
	ETableSpecification.  Removed the argument for setting whether to
	draw the focus.

svn path=/trunk/; revision=7673
2001-01-21 05:46:49 +00:00
ac063e3d36 Rename from Helix Code -> Ximian
svn path=/trunk/; revision=7520
2001-01-15 23:32:09 +00:00
f368ce16ae Commented out an unused variable to fix a warning.
2000-12-14  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-item.c (eti_realize): Commented out an unused variable
	to fix a warning.

svn path=/trunk/; revision=7014
2000-12-14 17:54:19 +00:00
a918af2dc3 Added eti_visibility_notify. Didn't get it to work properly, so it's #if
2000-12-13  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-item.c (eti_realize): Added eti_visibility_notify.
	Didn't get it to work properly, so it's #if 0ed out.

svn path=/trunk/; revision=6991
2000-12-14 03:07:28 +00:00
d8619d03cd Changed the background color of the tooltips to light gray.
2000-12-13  Christopher James Lahey  <clahey@helixcode.com>

	* e-cell-text.c (ect_show_tooltip): Changed the background color
	of the tooltips to light gray.

	* e-table-item.c (eti_event): Changed the tooltip timeout to 100
	milliseconds.

svn path=/trunk/; revision=6988
2000-12-14 01:54:37 +00:00
565e65690d remove the silly logic - we pop up a tooltip regardless of where the mouse
2000-12-13  Chris Toshok  <toshok@helixcode.com>

	* e-cell-tree.c (ect_show_tooltip): remove the silly logic - we
	pop up a tooltip regardless of where the mouse cursor hovers.
	just make sure it appears in the right place.
	(ect_event): reverse the change we make to the event after passing
	it to our subcell.  this fixes the problem of the tree reacting
	twice to events (once with flags == 0, and once with flags ==
	E_CELL_EDITING).

	* e-table-item.c (eti_event): destroy the tooltip window on a
	motion event.  this can (and does) happen when we get a tooltip on
	a tree cell and the cursor isn't over the area where the tooltip
	pops up.

svn path=/trunk/; revision=6979
2000-12-13 23:32:24 +00:00
a000f7480b New function to calculate the extra pixels per column header.
2000-12-13  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-header-utils.c, e-table-header-utils.h
	(e_table_header_width_extras): New function to calculate the extra
	pixels per column header.

	* e-table-header.c, e-table-header.h: Added a "width_extras"
	argument which is used to calculate the correct minimum widths for
	each column header after adding padding.

	* e-table-item.c (_do_tooltip): Destroy the old tooltip window
	when creating the new one.
	(eti_event): Destroy the old tooltip window if the person presses
	a key.  Don't handle the tab key.

	* e-table.c (et_state_to_header): Set the ETableHeader's
	width_extras argument.

svn path=/trunk/; revision=6978
2000-12-13 22:34:36 +00:00
1443cce12e Emit double_click signal with the model column, not the view column.
* e-table-item.c (eti_event): Emit double_click signal with the
	model column, not the view column.

svn path=/trunk/; revision=6909
2000-12-11 16:59:53 +00:00
3018f79188 Added the actions parameter to ect_event. Added an actions field to
2000-12-09  Christopher James Lahey  <clahey@helixcode.com>

	* e-cell-text.c: Added the actions parameter to ect_event.  Added
	an actions field to CellEdit.  Handle CellEdit properly in the
	ect_event function to do grabbing and ungrabbing when
	appropriate.  Set the actions field in CellEdit when appropriate
	in e_cell_text_view_command.

	* e-cell-toggle.c, e-cell-tree.c, e-cell.c, e-cell.h: Added a
	ECellActions enum, a ECellActions actions parameter to
	e_cell_event and added the actions parameter to all the handlers
	of the event method including having ECellTree pass it on to its
	child cell.

	* e-table-header-item.c: Use the NULL cursor instead of the
	E_CURSORS_ARROW cursor.

	* e-table-item.c, e-table-item.h: Added grabbed_row and
	grabbed_col fields to ETableItem (-1 on either means ungrabbed.)
	Pay attention to them in the find_cell function.  Handle the
	actions parameter of e_cell_event and grab or ungrab the pointer
	to a given cell if requested.  This is done using the new function
	eti_e_cell_event (which is internal to e-table-item.c,) instead of
	the old e_cell_event function call.  Fake an ungrabbed table when
	calling find_cell from within the compute_location method.

svn path=/trunk/; revision=6889
2000-12-09 22:20:52 +00:00
640883f04d Add column and GdkEvent * parameters to the double click signal.
2000-12-07  Christopher James Lahey  <clahey@helixcode.com>

	* e-table-group-container.c, e-table-group-leaf.c,
	e-table-group.c, e-table-group.h, e-table-item.c, e-table.c,
	e-table.h: Add column and GdkEvent * parameters to the double
	click signal.

	* e-table-header-item: Unref the ETableFullHeader when we're done
	with it.

	* e-table-scrolled.c, e-table-scrolled.h: Remove all of the
	proxies and add a function e_table_scrolled_get_table and a gtk
	argument "table".

svn path=/trunk/; revision=6850
2000-12-07 23:28:30 +00:00
517cb96a31 pass along the column's width to e_cell_show_tooltip.
2000-12-06  Chris Toshok  <toshok@helixcode.com>

	* e-table-item.c (_do_tooltip): pass along the column's width to
	e_cell_show_tooltip.

	* e-cell-text.c (ect_show_tooltip): add col_width argument, and
	set cell.width = col_width - 8 (to mimic what happens in
	build_current_cell, but with a possibly altered width).

	* e-cell.c (e_cell_show_tooltip): add col_width argument, and pass
	along to virtual function.
	(ec_show_tooltip): add col_width argument.

	* e-cell.h: change prototype of e_cell_show_tooltip to include a
	width parameter.

	* e-cell-tree.c (ect_show_tooltip): send the width - the subcell's
	offset to e_cell_show_tooltip.

svn path=/trunk/; revision=6831
2000-12-06 23:25:06 +00:00
620dda2c36 Adapted these to accept the new flags parameter to e_cell_event.
2000-12-06  Christopher James Lahey  <clahey@helixcode.com>

	* e-cell-text.c, e-cell-toggle.c, e-cell-tree.c: Adapted these to
	accept the new flags parameter to e_cell_event.

	* e-cell.c, e-cell.h: Added a flags parameter to e_cell_event.

	* e-table-item.c: Send all e_cell_event calls a E_CELL_EDITABLE
	flag.  Add a new e_cell_event to the button press event that
	happens before selecting the appropriate row and which does not
	have the E_CELL_EDITABLE flag set.

svn path=/trunk/; revision=6823
2000-12-06 21:37:15 +00:00
f70c74f371 Federico gets into pixel-perfect neurosis. Xmag is my best friend.
2000-12-01  Federico Mena Quintero  <federico@helixcode.com>

	Federico gets into pixel-perfect neurosis.  Xmag is my best friend.

	* e-table-item.c (eti_draw): Set the focus_gc stipple origin to
	match the upper-left corner of the focus rectangle.  This way
	focusing will look consistent even among rows/columns with odd
	pixel sizes.  Also, make the focus rectangle span the whole cell;
	there was one blank pixel column to the left of the rectangle.

	* e-table-header-utils.c: New file with utilities for drawing
	header buttons.  This is so that ETableHeaderItem and
	ETableFieldChooserItem can share the same code.
	(e_table_header_compute_height): New function to compute the
	height of a column button.
	(make_composite_pixmap): New function to composite a pixbuf
	against a solid background and make a pixmap out of the result.
	This does some ultra-fancy fading-out of the original pixbuf if
	the destination area is smaller than the source.
	(compute_elision_length): New function to compute the elision
	length in O(n log n) instead of O(n^2), for n = strlen (str).
	(e_table_header_draw_button): New function to draw a header
	button.
	(e_table_draw_elided_string): New function to draw a string elided
	to a maximum width.

	* e-table-defines.h (HEADER_PADDING): Made the default padding be
	1; now a header button's height is
	content_height + 2 * (HEADER_PADDING + style->ythickness).  This
	is the correct way to measure button heights.

	* e-table-field-chooser-item.c (etfci_find_button): Use
	e_table_header_compute_height().
	(etfci_reflow): Likewise.
	(etfci_draw): Use e_table_header_draw_button().
	(etfci_start_drag): Likewise.
	(etfci_draw): Likewise.
	(etfci_start_drag): Likewise.
	(etfci_button_height): Removed function.
	(draw_button): Removed function.

	* e-table-header-item.c (draw_button): Removed function.
	(e_table_header_item_get_height): Use e_table_header_compute_height().
	(ethi_draw): e_table_header_draw_button().
	(ethi_start_drag): Likewise.
	(make_shaped_window_from_xpm): Fixed misspelling in function name.
	(draw_button): Removed function.

	* Makefile.am: Added e-table-header-utils.[ch].

svn path=/trunk/; revision=6766
2000-12-02 17:35:22 +00:00
f7069251d4 Save the children - Federico
svn path=/trunk/; revision=6652
2000-11-22 18:28:44 +00:00