aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table/e-table-specification.c
Commit message (Collapse)AuthorAgeFilesLines
* new proto and virtual methodJP Rosevear2001-08-101-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-08-10 JP Rosevear <jpr@ximian.com> * gal/widgets/e-canvas-vbox.h: new proto and virtual method * gal/widgets/e-canvas-vbox.c (e_canvas_vbox_real_add_item_start): adds the the item to the beginning (e_canvas_vbox_add_item_start): call the virtual method 2001-08-10 JP Rosevear <jpr@ximian.com> * e-table.c (et_build_groups): add the items to the start or end based on where the click to add should be (e_table_setup_table): ditto (et_real_construct): read additional spec flag * e-table.h: new flag * e-table-specification.c (etsp_init): init new flag (e_table_specification_load_from_node): set click to add end flag (e_table_specification_save_to_node): write out flag * e-table-specification.h: new flag svn path=/trunk/; revision=11880
* #include <string.h> Same here. Kills warnings on newer gcc.Kjartan Maraas2001-05-251-0/+1
| | | | | | | | | 2001-05-25 Kjartan Maraas <kmaraas@gnome.org> * e-table-specification.c: #include <string.h> * e-table-state.c: Same here. Kills warnings on newer gcc. svn path=/trunk/; revision=9970
* (Make the alternating row colors a option in ETableSpecification insteadJason Leach2001-04-291-6/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* Fixed headers.Christopher James Lahey2001-04-041-6/+8
| | | | | | | | | | | | | 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
* Bumped the version number to 05.99.9.Christopher James Lahey2001-03-211-3/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* Changed e_table_selection_model_clear to e_selection_model_clear.Christopher James Lahey2001-02-281-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* Set policy of scrolled window to be automatic/automatic.Christopher James Lahey2001-02-141-0/+4
| | | | | | | | | | | | 2001-02-13 Christopher James Lahey <clahey@ximian.com> * e-table-scrolled.c (e_table_scrolled_real_construct): Set policy of scrolled window to be automatic/automatic. * e-table-specification.c, e-table-specification.h (etsp_init): Added a horizontal-scrolling attribute. svn path=/trunk/; revision=8208
* Made the contained %ETableItem have cursor_mode asChristopher James Lahey2001-01-301-0/+2
| | | | | | | | | | | | | | | | 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
* Made this conform to the new prototype for e_popup_menu_run.Christopher James Lahey2001-01-211-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* New function. (update_sort_config_dialog): Massive update to thisMiguel de Icaza2001-01-181-1/+0
| | | | | | | | | | | | | | | | | | | | 2001-01-18 Miguel de Icaza <miguel@gnu.org> * e-table-config.c (find_model_column_by_name): New function. (update_sort_config_dialog): Massive update to this function, it is almost complete now, it just needs a few cosmetic touchups. (config_sort_config_show): Get the main interaction working as well. (config_group_info_update): Beautify. (entry_changed): Do all the magic for the GUI for entries. (ascending_toggled): Implement callback. (configure_sort_dialog): Do also descending. (configure_sort_dialog): Hook up changed/toggled. * e-table-config.h: Put all the configuration stuff for sorting into its own structure to pass around funny functions. svn path=/trunk/; revision=7617
* Load frames.Miguel de Icaza2001-01-171-4/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-01-16 Miguel de Icaza <miguel@gnu.org> * e-table-config.c (configure_sort_dialog): Load frames. * Kill e-table-config-field.c * e-table-specification.c (e_table_specification_save_to_file): Specify version to xmlNewDoc. * e-table-state.c (e_table_state_save_to_string): Specify version to xmlNewDoc. * e-table-config.c (config_destroy): Destroy the copies. Unref the originals. (e_table_config_construct): Duplicate values of configuration here. (configure_sort_dialog): New function that populates the sort gtk combo boxes. * e-table.c (et_col_spec_to_col): Fixup use of title here. Do the actual translation here. * e-table-column-specification.c: Remove title_, it is now called title. Translation needs to take place elsewhere, not here * e-table-specification.c (e_table_specification_duplicate): Add preconditions here. (e_table_specification_save_to_node): ditto. (e_table_specification_save_to_string): ditto. (e_table_specification_save_to_file): ditto. * e-table-state.c (e_table_state_duplicate): Implement. * e-table-config.glade (dialog_sort): Change drop down menus to use GtkComboText widgets. * e-table-config.c (configure_dialog): New function, used to set up dialogs. svn path=/trunk/; revision=7563
* Added a bit of documentation. (config_sort_config_show,Christopher James Lahey2001-01-171-2/+2
| | | | | | | | | | | | | | | | | | 2001-01-16 Christopher James Lahey <clahey@helixcode.com> * e-table-config.c: Added a bit of documentation. (config_sort_config_show, config_group_config_show): gnome_dialog_set_parent on the config->dialog_toplevel instead of the config. * e-table-specification: Pass "1.0" instead of NULL to xmlNewDoc here. * e-table-state.c, e-table-state.h: Pass "1.0" instead of NULL to xmlNewDoc here. Make sure that sort_info is never NULL if this object exists. Added ETableStateDuplicate. svn path=/trunk/; revision=7542
* Document all entry points. (e_table_specification_save_to_file): ChangeMiguel de Icaza2001-01-161-71/+201
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-01-15 Miguel de Icaza <miguel@gnu.org> * e-table-specification.c: Document all entry points. (e_table_specification_save_to_file): Change prototype to return the number of bytes written. (e_table_specification_duplicate): Implement a function to duplicate nodes. (e_table_specification_save_to_node): Implement missing function. (e_table_specification_save_to_file): Enable. (e_table_specification_save_to_string): Enable. (e_table_specification_load_from_node): Just load the normal version of the click-to-add-message version, let other code translate it. (e_table_specification_load_from_string): Alter prototype to return success code. * e-table-specification.h: Do not store the translated version, store the plain version, so we can restore this later during the saving routines. * e-table.c (et_real_construct): Translate click to add message here. * e-table-header-item.c: Destroy config object if we are destroyed. svn path=/trunk/; revision=7518
* Added selection_mode argument.Christopher James Lahey2001-01-121-0/+12
| | | | | | | | | | | | | | | | 2001-01-11 Christopher James Lahey <clahey@helixcode.com> * e-table-selection-model.c, e-table-selection-model.h: Added selection_mode argument. * e-table-specification.c, e-table-specification.h: Added a selection_mode field that is set based on the selection-mode attribute in the ETableSpecification element. * e-table.c (et_real_construct): Set the selection model's selection mode based on the ETableSpecification. svn path=/trunk/; revision=7427
* Fixed the parity on the cursor-mode check.Christopher James Lahey2000-10-111-1/+1
| | | | | | | | | 2000-10-11 Christopher James Lahey <clahey@helixcode.com> * e-table-specification.c: Fixed the parity on the cursor-mode check. svn path=/trunk/; revision=5847
* Changed these to match the new ETable system.Christopher James Lahey2000-10-111-0/+196
2000-10-11 Christopher James Lahey <clahey@helixcode.com> * tests/test-tree-1.c, tests/test-tree-2.c, tests/test-tree-3.c: Changed these to match the new ETable system. * gal/Makefile.am: Added e-table-column-specification.lo, e-table-extras.lo, e-table-specification.lo, and e-table-state.lo. From gal/e-table/ChangeLog: 2000-10-11 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added e-table-column-specification.c, e-table-column-specification.h, e-table-extras.c, e-table-extras.h, e-table-specification.c, e-table-specification.h, e-table-state.c, and e-table-state.h. Removed some duplicated .h files. * e-cell-tree.c: Ref, sink, and unref the subcell instead of destroying it when done. * e-table-column-specification.c, e-table-column-specification.h: New class which describes a column without having a table get instantiated. * e-table-config.c: Changed get_specification to get_state to get this to compile. * e-table-defines.h, e-table-item.h: Moved the definition of ETableCursorMode from e-table-item.h to e-table-defines.h. * e-table-extras.c, e-table-extras.h: New class which acts as a set of 3 hash tables. All from char * and to alternately, ECells, GCompareFuncs, and GdkPxibufs. * e-table-scrolled.c, e-table-scrolled.h: Changed this to match the new ETable function declarations. * e-table-sort-info.c, e-table-sort-info.h: Added functions for saving to and loading from xml. * e-table-specification.c, e-table-specification.h: New class which describes a table without having to instantiate it. * e-table-state.c, e-table-state.h: New class which describes the state of a table without having to instantiate the table. * e-table.c, e-table.h: Changed this to accept both a state and a specification instead of just a specification. You then save only the state. The specification stays exactly the same. Also, you no longer need to pass in an ETableHeader. Most of the information contained in the ETableHeader are in the specification. However you may need to translate some of the strings in the specification to objects. If you need anything other than the builtin choices, you need to create an ETableExtras and pass it in. * e-tree-model.c: Removed an unused variable. svn path=/trunk/; revision=5837