1999-09-30 Miguel de Icaza * src/Gnumeric-value.idl: New file, move the value structure definition here. * src/Gnumeric.idl: Add new interface for data access. * src/value-sheet.c: New file. Moved here the value code that uses a Sheet directly. (value_dump): moved here. (value_cellrange_get_as_string): ditto. (encode_cellref): ditto. (value_area_get_width): ditto. (value_area_get_height): ditto. (value_area_get_x_y): ditto. (constants_init): ditto. (value_area_foreach): ditto (wrapper_foreach_cell_in_area_callback): ditto. (value_area_fetch_x_y): ditto. 1999-10-04 Jody Goldberg * src/workbook.c (sheet_action_delete_sheet) : Use a workbook_expr_relocate to invalidate references to the contents of the deleted sheet. * src/sheet.c (sheet_destroy_contents) : Renamed from sheet_destroy_columns_and_rows. Delete the cells directly from the hash. Don't use a range. * src/cellspan.c (row_destroy_span) : Set deleted span hash to NULL. * src/sheet.c (sheet_destroy_columns_and_rows) : Wipe all row spans in one stage to avoid looking them up one by one. 1999-10-03 Jody Goldberg * src/dialogs/dialog-delete-cells.c (dialog_delete_cells) : Specify the app as the parent. * src/dialogs/dialog-insert-cells.c (dialog_insert_cells) : Ditto. * src/expr.[ch] : (cell_ref_restore_absolute, cell_in_range, do_expr_tree_invalidate_references, expr_tree_invalidate_references, fixup_calc_new_cellref, do_expr_tree_fixup_references, expr_tree_fixup_references) : Delete. (cellref_relocate) : Rewrite to support intersheet, moves, invalidation, and references to and from moving cells. (expr_relocate) : Use new cellref_relocate. * src/workbook.[ch] (workbook_fixup_references, workbook_invalidate_references) : Delete. (workbook_expr_relocate) : Replace with. 1999-10-02 Jody Goldberg * src/{selection.c, collect.c, complex.c } : Add include config.h. So that we get the right #defines when including Workbook in a bonobo envirnoment. From : Jon K Hellan * src/dialogs/{col-width, dialog-zoom, names, row-height, sheet-rename, summary}.glade : Dialogs made with glade pop up for a moment in one position before being moved to the proper place. This is fixed by setting "Visible" to False in Glade. * src/print.c (print_page) : Make func pointer match new signature for sheet_col_get_info. 1999-10-01 Jody Goldberg * src/cell.h : Add ColRowCollection, a structure to store a segmented array of ColRowInfo *, and some of the other useful information, like max_element, and default_style. Rename data to 'spans' to facilitate removing dependancies on old name. Renumbered the CELL_ flags now that CELL_ERROR is gone. * plugins/* : Switch to ColRowCollection. * src/print.c : Ditto. * src/value.c : Ditto. * src/xml-io.c : Ditto. * src/dialogs/dialog-cell-format.c : Ditto, and use sheet_foreach_colrow. * src/sheet-view.c : Ditto. Use sheet_{row,col}_fetch and document why they are called. (sheet_view_scrollbar_display) : ifdef out untill some one wants it. src/dialogs/dialog-solver.c : Add include "tools.h" * src/sheet.[ch] : Massive reorg. Rows and Cols are no longer in lists they are in segmented arrays. Cols don't have lists of cells in them. All the insert/delete row/col code was redone and simplified. The Shift row/col is broken pending the merge with the new copy code. * src/cellspan.c : Switch from 'data' to 'spans' * src/clipboard.c : Use boolean, not integer '1' * src/corba-sheet.c : Switch to ColRowcollection. (Sheet_cell_get_background) : #ifdef until this is implemented. * src/embeddable-grid.c (grid_view_new) : Add a cast to silent warning. * src/item-grid.c (item_grid_draw_cell) : Paint the borders After contents. They still don't work, but this is slightly better. * src/expr.c (do_expr_tree_fixup_references) : Partial patch that fixes the common case and probably breaks the uncommon. Refs to cells/ranges on the current sheet have sheet == NULL. The destination specifies the sheet, so only references on a different sheet were fixed. When I rework this code for use by the 'move' operation I'll fix it. * src/gnumeric-sheet.c (move_cursor) : Move the cursor before making the area visible, Reset the selection after the motion. 1999-09-27 Jody Goldberg * src/item-grid.c (item_grid_draw) : Don't attempt to paint past SHEET_MAX_{ROWS,COLS}. * src/gnumeric-sheet.c (gnumeric_sheet_compute_visible_ranges) : Ditto. (move_cursor) : Set the cursor before making the area visible so that the scrollbars know the real position. 1999-09-26 Miguel de Icaza * src/print-preview.c (print_preview_new): Removed warning/ 1999-09-26 Morten Welinder * src/cell.c (cell_relocate): Plug leak. 1999-09-26 Michael Meeks * src/workbook.c (workbook_do_destroy): rename name clean. * src/sheet.c (sheet_destroy): add name clean. * configure.in: Add vital conditional for libole2. * src/xml-io.c (xml_write_names): Write from a GList. (xml_workbook_write): pass a GList. (xml_read_names): add sheet arg. (xml_workbook_read): upd. name read. (xml_sheet_read): add sheet name read. (xml_sheet_write): write names. Clean several redundant forward references. * src/main.c: make startup_files const. * src/expr-name.c: Major API hack for scoped names. (expr_name_add, expr_name_create, expr_name_lookup): add docs + scoped names. (expr_name_value): setup correct 'wb' for parsing. * src/parser.y (try_symbol): Add comment + hard code to workbook scope. 1999-09-26 Miguel de Icaza * src/sheet-object.c (sheet_set_mode_type): Protect Bonobo code from being included if we dont have Bonobo. * src/Makefile.am: reverted changes from the libole2 code. 1999-09-26 Michael Meeks * src/Makefile.am (gnumeric_libs): Fix so gnumeric compiles. 1999-09-26 Jody Goldberg * src/clipboard.c (clipboard_copy_cell_range) : use boolean. 1999-09-26 Miguel de Icaza * src/sheet-object.c (sheet_button_release): Load content from bonobo objects here. (sheet_view_object_unrealize): Keep the bookkeeping of realized objects in the GnomeCanvasItem destroy handler. * src/sheet-object-bonobo.c (sheet_object_bonobo_load_from_file): New base class for SheetObjectContainer and SheetObjectBonobo * src/sheet-object-container.c: Redid for reusing the new hierarchy SheetObjectBonobo hierarchy. 1999-09-25 Miguel de Icaza * src/sheet-object.c (create_object): handle SHEET_MODE_CREATE_CANVAS_ITEM. * src/sheet.h (Sheet::mode_data): new field to keep per-mode data during the lifetime of the mode. * src/sheet-object-item.c: New sheet-object type. This one is used for embedding Bonobo-based CanvasItems. 1999-09-25 Lauris Kaplinski * configure.in: add et to ALL_LINGUAS * gnumeric.desktop: added Estonian strings 1999-09-25 Michael Meeks * src/dialogs/dialog-zoom.c (dialog_zoom): Correct glade name. (dialog_zoom_impl): use moveto after we know the final list size. (custom_selected): simplify. (radio_toggled): ditto. (select_sheet_cb): create. (dialog_zoom_impl): use update_zoom_but & complicate significantly :-) (update_zoom_buttons): create. 1999-09-25 Jody Goldberg * src/plugin.c (plugin_load) : Enable the error box when loading a plugin fails. * src/item-grid.c (item_grid_draw) : Paint an empty only if the cell does not exist. VALUE_EMPTY cells should be treated as std cells when drawing the background. (item_grid_draw_cell) : Draw the contents before the border. 1999-09-24 Morten Welinder * src/widgets/gtk-combo-box.c (gtk_combo_box_finalize): Plug leak. 1999-09-24 Jody Goldberg * src/expr.c (do_expr_decode_tree) : Handle missing arguments. 1999-09-23 Morten Welinder * src/widgets/widget-color-combo.c (color_combo_construct): Now non-static since Miguel decided to prototype it. * src/regression.c (linear_regression, exponential_regression): Change to multi-dimensional regression. (Too bad linear_solve does not handle it yet.) All callers changed. * src/widgets/widget-color-combo.c (color_clicked): Plug leak. (color_combo_select_color): Plug leak. (emit_change): Plug leak. 1999-09-23 Miguel de Icaza * src/widgets/widget-color-combo.c (color_combo_new): Install the Excel color table. 1999-09-23 Morten Welinder * configure.in (gnome-print): back to 0.8. 1999-09-23 Miguel de Icaza * src/style.c (style_font_new_simple): Be defensive at font-loading time. Basically, gnome-fonts might be allocated with a NULL gdk_font. Maybe we need to revise this strategy 1999-09-23 Morten Welinder * configure.in (gnome-print): only require 0.7 -- that's the latest cvs version. * gnumeric.spec.in (Requires): Ditto. * configure.in (gnome-print): fix test. 1999-09-23 Miguel de Icaza * gnumeric.gnorba (location_info): Dropped the IDL: prefix from the gnorba file, and use "GOADID:" now. * src/widgets/widget-color-combo.c (color_combo_class_init): Fixed memory leaks. * src/style.h: Keep the original colors handy here. * src/print-cell.c (print_cell_range, print_empty_cell): We now paint empty cells. Now we paint the background for the cell. * src/print-cell.c * src/item-grid.c (item_grid_paint_empty_cell): Style leak fix. * src/print-cell.c (print_cell): Changed the way borders are printed to improve code reusability. * src/print-info.c (save_formats): New format name to fix in an upgradable fashion. (load_formats): ditto. (print_info_new): The defaults to load should use [PAGE] not [NUM], which explains why it was never being shown. * src/print-preview.c (print_preview_print_done): Close the context here so we have information available in the ->size field. 1999-09-23 Morten Welinder * src/regression.c (exponential_regression): Fix thingo. * src/widgets/widget-color-combo.c (color_table_setup): Static. (color_combo_construct): Static. (color_table_setup): really break out. 1999-09-23 Rodrigo Stulzer Lopes * configure.in: add pt_BR to ALL_LINGUAS 1999-09-23 Miguel de Icaza * src/print.c (print_page): Setup the rotation for each page. 1999-09-23 Jody Goldberg * src/xml-io.c (xml_set_print_unit) : Suppress warning. * src/dialogs/dialog-zoom.c (dialog_zoom_impl) : Set the spinbox value when we start with a custom zoom factor, round correctly. Set the parent to be gnumeric. 1999-09-22 Jody Goldberg * src/xml-io.c (xml_write_sheet_object) : Avoid warning about unhandled object types. * src/sheet-object.c (control_point_handle_event) : unused variable. 1999-09-22 Miguel de Icaza * src/item-grid.c (item_grid_paint_empty_cell): I am now using a gc for the empty cells (as the default gc is used and abused by the cell-draw code, better to keep our own). TODO: queue an update on the regions with changed style. Wonder why this is not being done automatically. Need to check. * src/widgets/widget-color-combo.c (color_combo_construct): Fix visuals for working with Imlib properly. 1999-09-22 Jody Goldberg * src/dialog/dialog-zoom.c : rewrite. 1999-09-21 Morten Welinder * src/widgets/widget-font-selector.c (reload_preview): Spelling fix. 1999-09-21 Miguel de Icaza * src/sheet.c (cell_is_homogeneous): Set size here to get correct feedback results. * src/workbook-format-toolbar.c (change_font_in_selection_cmd): Simplified to use apply_style_to_selection (apply_style_to_selection): Big nice wrapper. (change_font_size_in_selection_cmd): Implement. * src/pixmaps.h: Removed GNUMERIC_TEST_ACTIVE_OBJECT for release. * src/workbook-format-toolbar.c: More toolbar work, now we have color selectors for foreground and background. * src/workbook.c: Split the format toolbar * src/workbook-format-toolbar.[ch]: Now they contain the format-toolbar code. * src/sheet-object-graphic.c (sheet_object_filled_realize): Width is now in points, not pixels. * src/widgets/gtk-combo-box.[ch]: New files, they implement an extensible ComboBox for Gtk. * src/widgets/color-combo.[ch]: New files, they implement the ColorCombo box. 1999-09-21 Michael Meeks * src/sheet-object-container.c (make_container_item): Add widget_handle. (sheet_object_container_destroy): clean. * src/sheet-object-widget.c (sheet_object_widget_realize): add widget handling hook. * src/sheet-object.c (sheet_object_event): renamed to canvas_event. (control_point_handle_event): use gdouble for x,y & remove duff w2w & dx*zoom code. * src/sheet-object.h: add various signals + a type. * src/sheet-object-widget.c (sheet_object_widget_construct): set press. * src/sheet-object.c (sheet_object_event, sheet_object_make_current): remove redundant 'Sheet' argument. (control_point_handle_event): Add make_current to button press. (sheet_object_start_editing): clean + setup cursor data. (control_point_handle_event): Use sizing cursors. (sheet_object_event): Add 'press' cursor. (sheet_object_widget_event, sheet_object_widget_handle): handlers to pass events around. * src/sheet-object-container.c (user_activation_request_cb): update make_current. * src/cursors.h: Add new cursors. * src/cursors.c: ditto. 1999-09-21 Morten Welinder * src/functions/fn-stat.c (gnumeric_logest): Add some meat. * src/regression.c (general_linear_regression): Renamed from general_regression. (exponential_regression): New function. 1999-09-21 Jukka-Pekka Iivonen * samples/statfuns.xls: Updated the second PERCENTRANK test. * src/functions/fn-stat.c: Added stubs for LOGEST and GROWTH. 1999-09-20 Morten Welinder * src/expr.c (do_expr_decode_tree): Plug leak. * src/functions/fn-stat.c (gnumeric_linest): Handle "const" parameter also. Introduce skeleton to handle "stat" parameter. (gnumeric_percentile): Fix PERCENTILE. * src/format.c (format_number): Plug leak. 1999-09-20 Jody Goldberg * plugins/{ff-csv, gda, guile, python, sample, text}/Makefile.am : Do not specify private warnings. Use the default set from compiler-flags.m4. * src/cell.h (cell_deep_thaw_dependencies, cell_deep_freeze_dependencies) : Remove non-existant prototypes. 1999-09-19 Jukka-Pekka Iivonen * src/functions/fn-stat.c: Implemented PERCENTILE() function. 1999-09-19 Jody Goldberg * src/value.c (value_release) : Releasing value_terminate should not generate an error. * src/sheet-object-container.h : Add include . 1999-09-18 Jody Goldberg * src/sheet-object.h : Make SheetObjectType names constistant with SheetModeType names, and add GRAPHIC, BUTTON, and CHECKBOX. * plugins/html/epsf.c (epsf_write_wb) : RECTANGLE -> BOX. ELLIPSE -> OVAL. * src/sheet-object.c (create_object) : Ditto. * src/xml-io.c (xml_read_sheet_object) : Ditto. 1999-09-18 Miguel de Icaza * src/dialogs/dialog-simple-input.c (dialog_get_sheet_name): use dialog_run_and_close here. (dialog_get_number): ditto. * src/format.c (format_add_thousand, format_remove_decimal, format_add_decimal): New routines. (format_number): Fixed bug in 'E', 'e' handler (format was incremented twice). * src/workbook-cmd-format.c: Hook up the add/remove decimal and add thousand actions. * src/sheet.c (range_is_homogeneous): Do not value_release a value terminate. * src/workbook-cmd-format.c (do_apply_style_to_selection): set sheet dirty. (workbook_cmd_format_column_auto_fit): ditto. (workbook_cmd_format_column_width): ditto. (workbook_cmd_format_row_auto_fit): ditto. (workbook_cmd_format_row_height): ditto. * src/workbook.c (workbook_rename_sheet): dirty sheet. 1999-09-19 Michael Meeks * src/workbook.c (about_cmd): make static. * src/sheet-object-container.c (sheet_object_container_load): fix return value. * src/workbook.c (create_format_toolbar): cast to widget not entry. 1999-09-19 Morten Welinder * src/functions/fn-stat.c (callback_function_make_list): Static. (init_make_list_closure): Static. * src/expr.c (eval_expr_real): Static. * src/functions/fn-math.c (gnumeric_sum): Static. (gnumeric_suma): Static. * src/analysis-tools.c (covariance_tool): Plug leak. (descriptive_stat_tool): Plug leak. (correlation_tool): Plug leak. (ranking_tool): Plug leak. (anova_single_factor_tool): Plug leak. (sampling_tool): Don't read past array. * src/sheet.c (sheet_destroy): Plug leak. * src/dialogs/dialog-cell-sort.c (dialog_cell_sort): Plug leak. 1999-09-18 Jody Goldberg * src/sheet.c (range_is_homogeneous) : Ignore results from sheet_cell_foreach_range it will always be NULL or value_terminate. Neither need to be freed. * src/value.c (value_release) : Re-enable test to avoid releasing value_terminate. 1999-09-17 Miguel de Icaza * src/sheet.c (sheet_row_size_fit): fetch row information, not column information. Fix the routine. * src/workbook-cmd-format.c (workbook_cmd_format_column_auto_fit): (workbook_cmd_format_column_width): (workbook_cmd_format_row_auto_fit): (workbook_cmd_format_row_height): Fix the range being scanned to be inclusive. 1999-09-17 Jody Goldberg * samples/operator.xls : Updated to be robust in the face of errors, and to use epsilon comparisons for the artihmetic comparisons. 1999-09-18 Morten Welinder * gnumeric.spec.in (Requires): Update libglade version. * src/dialogs/dialog-printer-setup.c (do_hf_config): Plug leaks. * src/sheet.c (zoom_cell_style): Plug leak. * src/functions/fn-date.c (get_serial_time): Be defensive. * src/expr.c (eval_expr_real): For integer 0^0, return #NUM!. (eval_expr_real): Adjust float power error check to match the integer one. * src/style.c (style_new): Silence. * src/sheet.c (sheet_update_controls): Initialize all closure members. 1999-09-17 Michael Meeks * src/dialogs/dialog-summary.c (dialog_summary_update): Change to workbook argument, and reparent to toplevel. * src/dialogs/dialogs.h: ditto. * src/workbook.c (summary_cmd): ditto. 1999-09-17 Miguel de Icaza * src/widgets/gnumeric-toolbar.c (gnumeric_toolbar_class_init): typo fix. 1999-09-17 Miguel de Icaza * src/widgets/gnumeric-toolbar.c (gnumeric_toolbar_class_init): Parent class is GtkToolbar, not itself. 1999-09-17 Miguel de Icaza * src/workbook.c (create_format_toolbar): Make the size of the entry line onloy fit four zeros. (workbook_feedback_set): set the font even if no cached value exists. 1999-09-17 Jukka-Pekka Iivonen * src/workbook.c: Added ``Delete...'' entry to ``Edit'' menu. 1999-09-17 Miguel de Icaza * src/workbook-cmd.c: New file. Moved a bunch of commands here, and move to be moved. Implemented the set money format; Implemented the percent formt. 1999-09-16 Miguel de Icaza * src/sheet.c (sheet_update_controls, cell_is_homogeneous): Include checks for font name and font size. * src/dialogs/dialog-printer-setup.c (dialog_printer_setup): Add call to gnome_dialog_set_parent here. * src/dialogs/tools.h: New file, moved here all the tools declarations. Please, try to keep indentation for public functions as the rest of the Gnumeric ones. * src/workbook.c: Enable comands Format/Column, Format/Row and Format/Sheet. (create_format_toolbar): Add font selector toolbar widget. (change_font_in_selection_cmd): New routine. Applies a font to a selection in the workbook. (workbook_feedback_set): Upgraded feedback interface * src/sheet-view.c (sheet_view_row_size_changed): There is no need to call gnumeric_compute_visible_ranges, the sheet_row_set_height code does this. * src/item-bar.c (item_bar_event): Support also row-autosizing. * src/sheet.c (sheet_col_size_fit): Add this routine. (sheet_col_set_internal_width): New function. Similar to its counterpart * src/dialogs/dialog-cell-format.c (dialog_cell_format): Change call to g_list_free for sheet_cell_list_free. * src/selection.c (sheet_cell_list_free): New routine. * src/workbook.c: Reworked toolbars again. We now only have 2 toolbars instead of 8 or so. * src/sheet.h (SHEET_MAX_ROWS): New excel supports 64k rows, mimic this. * src/widgets/gnumeric-toolbar.c: Added new file. Handles the Gnumeric toolbars. 1999-09-17 Jody Goldberg * src/sheet.c (sheet_col_get_unit_distance, sheet_row_get_distance sheet_row_get_unit_distance sheet_col_get_unit_distance) : Constification. (sheet_init_default_styles) : Make the default row/col size match excel more closely. 1999-09-16 Michael Meeks * src/func.c (functions_init): Remove misc_init. * src/functions/fn-misc.c: Removed, empty & redundant. * src/functions/Makefile.am: remove fn-misc.c * src/func.h: ditto. * src/sheet-object-container.c (sheet_object_container_load): Implement cleaner & simpler load method * NEWS (Michael): doh, move it into the correct version. 1999-09-16 Michael Meeks * src/print.c (sheet_print): Update to use gnumeric_porinter_dialog_run. (print_job_info_get): Add range parameter. * src/dialogs/Makefile.am (libdialogs_a_SOURCES): Added dialog-printer.[ch] * src/dialogs/dialog-printer.[ch]: New thin wrapper of GnomePrinterDialog to handle sheet selection. * src/sheet-object-container.c (sheet_object_container_land): Add comments about what needs doing. * src/sheet-object.c (sheet_object_event): renamed. Updated various SheetObject var names to 'so'. 1999-09-15 Michael Meeks * src/sheet-object-container.c (sheet_object_container_land): Cleaned debug, improved sizing logic. 1999-09-16 Jody Goldberg * src/ranges.c (range_dump) : Typo. * src/selection.c (selection_to_list) : rename from sheet_selection_to_list and add allow_intersection parameter. (selection_to_string) : rename from sheet_selection_to_string and use selection_apply. * src/dialogs/dialog-cell-format.c (dialog_cell_format) : Adjust to changes in selection_to_list. 1999-09-15 Morten Welinder * src/sheet.c (cell_is_homogeneous): Always return a value. * src/ranges.c (range_dump): Fix destination. * src/selection.c (selection_apply): Plug leak. 1999-09-15 Michael Meeks * src/sheet-object.c (window_to_world): Remove. (sheet_motion_notify, sheet_button_release, sheet_object_drop_file): clean to use gnome_canvas_window_to_world. * src/sheet-view.c (sheet_view_construct, (filenames_dropped): move * src/gnumeric-sheet.c (gnumeric_sheet_filenames_dropped), (gnumeric_sheet_new): to here + rename; makes more sense. * src/sheet-object.c (sheet_object_drop_file): Take a GnumericSheet. * src/parser.y (array_row:): Manged to support wierd MS style array semantics some people get {1\2\3;4\5\6} instead of {1,2,3;4,5,6}. * src/workbook.c (workbook_file_toolbar): Remove duplicate print icon. * src/pixmaps/preview.xpm: Stop gap icon; improved. * src/xml-io.c (xml_get_print_hf): Remove redundant precondition. 1999-09-14 Miguel de Icaza * src/workbook.c: Split toolbars into mulitple toolbars; Add a private field to Workbook structure. Change the toolbar setup to have multiple dock-items. * src/format.c: Initialize this to NULL. * src/print-info.c (load_formats): Memory leak fix. * src/xml-io.c (xml_read_summary): Fixed memory leak. 1999-09-14 Morten Welinder * src/dialogs/dialog-analysis-tools.c (tools): Make static. * src/print-info.c (load_formats): Plug leak. * src/functions/fn-eng.c (eng_functions_init): Arg fix. * src/functions/fn-string.c (string_functions_init): Ditto. * src/functions/fn-stat.c (stat_functions_init): Ditto. * src/functions/fn-sheet.c (sheet_functions_init): Ditto. * src/functions/fn-misc.c (misc_functions_init): Ditto. * src/functions/fn-math.c (math_functions_init): Ditto. * src/functions/fn-lookup.c (lookup_functions_init): Ditto. * src/functions/fn-logical.c (logical_functions_init): Ditto. * src/functions/fn-information.c (information_functions_init): Ditto. * src/functions/fn-financial.c (finance_functions_init): Ditto. * src/value.c (value_terminate): Ditto. * gnumeric.spec.in (Requires): Update gnome-print dependency. 1999-09-14 Karl Eichwalder * src/workbook.c: The "import" item needs dots; it opens a dialog. * DEPENDS: Add gnome-print. * README: Increase gnome-print version (0.6); not sure, whether other version numbers are to be increased, too. Fix typos; small prettifications. 1999-09-13 Jody Goldberg * src/ranges.c (range_dump) : Improve format. * src/workbook.c (deps_output) : The selection can be a region. * src/dialogs/dialog-cell-sort.c (dialog_cell_sor) : sheet_selection_first_range returns a range. * src/print.c (sheet_print_selection) : Ditto. * src/selection.c (sheet_selection_first_range) : Simplify and move closer to to sheet_verify_selection_simple. * src/workbook.c (insert_cols_cmd, insert_cols_cmd) : Handle sheet_verify_selection_simple rename to selection_is_simple. * src/sheet.c (sheet_update_controls) : Use selection_apply rather than sheet_selection_to_list which is expensive. (sheet_col_selection_type, sheet_row_selection_type) : Constification. 1999-09-13 Michael Meeks * src/parser.y (forget_array): Created. exp: added array_row, array_exp, array_cols: created. (build_array): Implemented. (v_forget): added. * src/value.c (value_release): Update Array to only free if != NULL. * src/functions/fn-lookup.c (lookup_functions_init): add index. (gnumeric_index): Ghastly placeholder; we need more core functionality. (gnumeric_lookup): remove redundant value_duplicate fixing leak. (gnumeric_match): Implement as far as it goes. * src/workbook.c (workbook_delete_event): Nail fatal bug in #define for bonobo. * src/dialogs/dialog-printer-setup.c (dialog_print_info_new): Moved things into constructor and out of (dialog_printer_setup). (unit_changed): actually update the margin UnitInfo's value... * src/xml-io.c (xml_read_print_info, xml_write_print_info, xml_get_print_hf), (xml_set_print_hf): Header / footer, paper size writing. 1999-09-13 Karl Eichwalder * src/dialogs/hf-config.glade: Add missing `:'. Is this the right place to fix this kind of a bug? * src/dialogs/hf-config.glade.h (N_): Ditto (I don't know how to autogenerate this file). 1999-09-13 Jukka-Pekka Iivonen * src/functions/fn-misc.c, src/functions/fn-information.c: Moved the error functions to information functions file. * src/functions/fn-math.c, src/function/fn-lookup.c: Moved TRANSPOSE to lookup functions file. * src/functions/fn-stat.c: Added more examples. * src/dialogs/dialog-analysis-tools.c: Bug fix. Pressing ESC key means CANCEL now in the subdialogs. 1999-09-13 Michael Meeks * src/dialogs/dialog-printer-setup.c (do_setup_page_info): Fix initial display of icon: lr/td first. * src/xml-io.c (xml_sheet_read, xml_sheet_write): Add print info R/W. 1999-09-12 Michael Meeks * src/print-info.h: UnitName typo corrected. * src/dialogs/dialog-printer-setup.c (convert_to_mm, unit_editor_new): ditto. * src/xml-io.c (xml_read_print_info, xml_write_print_info): Implemented. (xml_read_summary): Cleaned preconditions to make Miguel happy. * src/print-preview.c (preview_destroyed, print_preview_new): Attach signal to the workbook and warn. * src/print.c (sheet_print): Remove redundant print_context_close_file. * src/embeddable-grid.c (grid_view_new): NULL a pointer. 1999-09-12 Michael Meeks * src/embeddable-grid.c (grid_view_activate): Hack to cope with new private Bonobo plug, just emit a warning. (grid_view_new): similarly hacked. * src/eval.c: Include ranges.h * src/selection.c (sheet_selection_first_range): Remove unused and cryptic base_col / base_row. * src/dialogs/dialog-cell-sort.c (dialog_cell_sort): remove base stuff. * src/workbook.c (print_setup_cmd, file_print_cmd), (file_print_preview_cmd): New print stuff. (deps_output): update to new first_range. * src/print-preview.c (print_preview_new): More wb->sheet. (sheet_destroyed): Renamed, (create_preview_canvas, render_page), (preview_file_print_cmd, create_toplevel): wb->sheet. include print.h (preview_file_print_cmd): Add active_sheet. (create_toplevel): Update name calc + add preconditions. * src/print-preview.h: update prototype + add _context proto. * src/print.c (print_job_info_get): more wb->sheet. (printjob_init_sheet): split out. (sheet_print_selection): implement. * src/sheet.c (sheet_new, sheet_destroy): Add print info bits. * src/workbook.c (workbook_do_destroy, workbook_init): Clean print-info bits. * src/dialogs/dialog-printer-setup.c (dialog_print_info_t): convert workbook -> sheet (do_print_preview_cb, do_print_cb), (dialog_print_info_new, dialog_printer_setup): ditto. (do_setup_main_dialog): preconditions. * src/dialogs/dialogs.h: Change prototype. * src/print.c (workbook_print): Implemented PRINT_ACTIVE_SHEETS, added default_range paramter: use for now; renamed (sheet_print) (print_sheet): preconditions (sheet_print_selection): renamed. * src/print.h (workbook_print): Move PrintRange enum here & re-name. 1999-09-11 Miguel de Icaza * src/workbook.c (workbook_delete_event): Fix the delete_event setup. 1999-09-11 Jody Goldberg * src/sheet-object-widget.c (sheet_object_widget_update_bounds) : Don't zoom coords sheet_object_get_bounds takes care of that for us. * src/sheet-object-container.c (sheet_object_container_update_bounds) : Ditto. * src/sheet-object-graphic.c (sheet_object_filled_update_bounds) : Ditto, renamed from sheet_object_filled_update to be more consistant. 1999-09-10 Michael Meeks * src/corba-sheet.c: include selection.h * src/sheet.c: Include ranges.h (sheet_insert_object): remove unused. * src/file.c (workbook_try_read): Remove unused var. (fs_key_event): Sort out return type & cast. * src/selection.c: Add Jody as an author if he isn't going to :-) * src/sheet-object.c: Cheekily do the same for me. 1999-09-10 Miguel de Icaza * src/corba-sheet.c: Updated to the new sheet selection API changes. * src/gnumeric-sheet.c (destroy_item_editor): Removed FIXME comment. More fixing from Federico's talk (gnumeric_sheet_stop_cell_selection): ditto * src/cell.c: Replaced unrefs of windows with destroys. Federico explained a thing or two to me today. * src/file.c (dialog_query_load_file): Added a key handler to handle ESC on dialog boxes to mean cancel. (workbook_save_as): ditto. 1999-09-10 Michael Meeks * src/sheet-object.c (window_to_world): Added debug. * src/widgets/widget-editable-label.c (el_start_editing): * src/workbook.c (sheet_label_text_changed_signal): Return focus to the main sheet when finished. * src/widgets/widget-editable-label.c (el_stop_editing): Convert gtk_object_unrefs to gtk_object_destroy's kills wierd debug. (el_destroy): NULL freed pointer. (el_start_editing): Add vital widget_grab_focus. * src/cursors.h (cursor_set_widget): Use G_STMT_* in macros. * src/workbook.c (workbook_can_close): Add forward definition. (workbook_new): Update sizing algo. to fit to the screen better. * src/main.c (gnumeric_main): Process gtk draw events between loading files, can't slow us down and looks lots better ! 1999-09-10 Jukka-Pekka Iivonen * src/functions/fn-*: Added tons of examples to help strings. 1999-09-09 Michael Meeks * src/sheet-object.c (sheet_button_release), sheet_motion_notify), (sheet_object_set_bounds): Fix for arrows. 1999-09-09 Michael Meeks * src/workbook.c (workbook_delete_event): Fix object_unref for Bonobo case. (workbook_widget_delete_event): remove strange unref, this needs looking at. * src/sheet-object.c (sheet_view_object_unrealize, sheet_object_destroy), (sheet_object_destroy_control_points): Changed _unref to _destroy nailing scads of warnings. * src/sheet-object-container.c (sheet_object_container_destroy_views): ditto. * src/sheet-object-container.c (sheet_object_container_land): Get auto sizing working. * src/sheet-object*.[ch]: Large overhaul, extensively re-wrote signal handling, and state passing. Generic object 'bounds' is now stored in sheet-object, and accessed via access procedures. Homegenized naming, Drasticaly simplified re-sizing modes. * src/sheet-view.c: Include selection.h to kill warnings. * src/sheet-object.c (sheet_object_get_bounds): Created. (sheet_view_object_unrealize): Fix the same list manipulation bug ( it gets everywhere ). 1999-09-09 Jukka-Pekka Iivonen * src/functions/fn-*: Started adding examples to all functions. 1999-09-08 Jody Goldberg * src/*.c : Have Range use CellPos, and SheetSelection use Range. * src/functions/fn-sheet.c (gnumeric_selection) : Switch to selection_apply. * src/sheet.c (sheet_set_selection) : Keep GNUMERIC_SHEET_VIEW local to sheet.c * src/selection.c (sheet_selection_change, selection_append_range, sheet_selection_extend_to) : Use sheet_set_selection. * src/dialogs/dialog-cell-format.c (apply_font_format, cell_properties_apply) : adjust to changes in SheetSelection. * src/functions/fn-sheet.c (gnumeric_selection) : Switch to selection_apply. * src/gnumeric-util.c (range_contains) : Ditto. Const. * src/selection.c (sheet_selection_clear, sheet_selection_clear_comments, sheet_selection_clear_content, sheet_selection_clear_formats) : Use selection_apply. (selection_apply) : New function abstracting selections enabling correct support for overlapping selection regions. (sheet_selection_to_list) : Use selection_apply. * src/value.c (value_new_array_empty) : New function. 1999-09-08 Michael Meeks * src/sheet-object.c (control_point_handle_event): substantialy re-written, same bugs :-), fix tommorow.; added range clipping. * src/sheet-object-container.c (sheet_object_container_land): Add auto-size placeholder & argument. (sheet_object_container_destroy): gnome_object_destroy instead of gtk_object_destroy. * src/sheet-object.c (sheet_object_drop_file): remove duff realize and debug. Correct gnome_object_destroy to gtk_object_destroy. 1999-09-08 Morten Welinder * gnumeric.desktop: Add Danish translations. 1999-09-08 Jody Goldberg * src/cell.c (cell_get_span) : Support VALUE_EMPTY. 1999-09-08 Michael Meeks * src/sheet-view.c (filenames_dropped, sheet_view_construct): Move D&D activation to here, so we get sensible handling of positions. * src/sheet-object-container.c (user_activation_request_cb): typo. (sheet_object_drop_file): Emit the correct signal to realize, take a SheetView argument, clean 'msg's up. (sheet_object_container_new): Squashed warning. * src/workbook.c (filenames_dropped, workbook_new): Move D&D into sheet-view.c. * src/file.c (workbook_try_read): Split from workbook_read. (workbook_import, workbook_read): Correct casts & updated. * src/dialogs/dialog-function-select.c (function_definition_update), (function_categories_fill): Add casts to get round daft clist_append constification. 1999-09-08 Vincent Renardias * src/dialogs/dialog-analysis-tools.c: A number of displayed strings were not marked as such. * po/fr.po: Updated accordingly. 1999-09-08 Pablo Saratxaga * src/workbook.c: changed "_Comments" to "Co_mments" as there is already "_Content" in the same menu 1999-09-07 Jody Goldberg * src/dialogs/dialog-function-select.c (function_definition_update, function_categories_fill) : Const. 1999-09-07 Miguel de Icaza * src/workbook.c: Remove sample button from the toolbar. * src/item-bar.c (item_bar_event): Use the item_bar->resize_pos computed during button press. #2090 fixed 1999-09-07 Morten Welinder * src/print-info.c (save_margin): Terminate the set of strings to concatenate. * src/dialogs/dialog-printer-setup.c (do_setup_main_dialog): Plug leak. 1999-09-07 Michael Meeks * src/pixmaps.h: Added button.xpm * src/sheet-object.c (sheet_object_drop_file): Created. * src/workbook.c (filenames_dropped): Move component d&d guts into sheet-object. * src/file.c (workbook_import, workbook_read): Add bonobo_object _destroy if we have bonobo. 1999-09-03 Miguel de Icaza * src/item-grid.c: Code now can draw emtpy cells with the correct style. 1999-09-03 Miguel de Icaza * src/dialogs/dialog-printer-setup.c (draw_margins): Added margin display preview. * src/print-preview.c (preview_zoom_out_cmd): Zoom-in, zoom-out and move are now toggle buttons. * src/workbook.c (italic_cmd, bold_cmd): Simplified the code some. * src/dialogs/dialog-printer-setup.c (do_setup_page_info): Force the icon display here. (preview_page_create): Invert test. (PAGE_X, PAGE_Y): They are now the same values. (do_setup_page): Show the images here. 1999-09-02 Miguel de Icaza * src/print-preview.c (create_toplevel): Add a toolbar. * src/print.c (compute_groups): Include the margins in the size computation. * src/print-cell.c (print_cell_range): Start printing from the start_row, not from zero. * src/print-preview.c: Change of plans. We now use a metafile, we render all the code there. And then we use the new metafile operations for rendering a specific page. * src/item-cursor.c (item_cursor_autofill_event): Change this to destroy again. 1999-09-01 Miguel de Icaza * src/print-preview.c (print_preview_print_done): Show the first page here. 1999-09-03 Michael Meeks * src/sheet-object-container.c (sheet_object_container_land): Add return type to denote if we created and bound correctly. (sheet_object_container_creation_finished): Add warning on failure. (get_file_name): Kill warning. 1999-09-01 Michael Meeks * src/sheet-object-container.c (sheet_object_container_land): Add optional file argument and document. (sheet_object_container_creation_finished): update call's args. * src/sheet-object.h: Removed redundant sheet_object_register. * src/workbook.c (filenames_dropped): Hacked. 1999-09-07 Miguel de Icaza * src/item-bar.c (item_bar_event): Use the item_bar->resize_pos computed during button press. #2090 fixed 1999-09-07 Miguel de Icaza * src/format.c (format_number): "\" is an escape character for the next character on the format. 1999-09-07 Morten Welinder * src/mathfunc.h: Make up for deficient header files. * src/cursors.c (create_bitmap_and_mask_from_xpm): Fix bitmap loading. This code isn't exactly elegant. 1999-09-06 Jody Goldberg * src/sheet-view.[ch] (sheet_view_scrollbar_config) : Adjust scrollbar increment. Split out from sheet_view_size_allocate. * src/gnumeric-sheet.c (gnumeric_sheet_compute_visible_ranges) : call sheet_view_scrollbar_config, to adjust scrollbar when region changes. 1999-09-05 Miguel de Icaza * src/print-preview.c (preview_canvas_event): Add an event handler for the preview canvas. Make the drag action on MOVE mode move the canvas. (zoom_state): new routine, controls the toolbar widget display. * src/cursors.c: Add new zoom in and zoom out cursors. * src/dialogs/dialog-printer-setup.c (unit_editor_new): One line warning fix. * src/sheet.c (sheet_col_size_fit): Returns the size required to render every cell completely. * src/item-bar.c (item_bar_event): Delay column/row resizing action until the division is actually being dragged. We need this to catch double-clicks for auto-sizing cells. (GDK_2BUTTON_PRESS): * src/dialogs/dialog-cell-format.c (create_background_radio, create_foreground_radio): Set the toggle button to the colored when the color selector has been clicked. * src/item-grid.c (item_grid_draw): Experimental code for drawing empty cells with the correct attributes. Only enabled if you use set gnumeric debugging flag above 1. I do have some issues with selection drawing. 1999-09-05 Richard Hestilow * configure.in: Minor s/For/for library check message fix. 1999-09-03 Miguel de Icaza * src/dialogs/dialog-printer-setup.c (draw_margins): Added margin display preview. * src/print-preview.c (preview_zoom_out_cmd): Zoom-in, zoom-out and move are now toggle buttons. * src/workbook.c (italic_cmd, bold_cmd): Simplified the code some. * src/dialogs/dialog-printer-setup.c (do_setup_page_info): Force the icon display here. (preview_page_create): Invert test. (PAGE_X, PAGE_Y): They are now the same values. (do_setup_page): Show the images here. 1999-09-02 Miguel de Icaza * src/print-preview.c (create_toplevel): Add a toolbar. * src/print.c (compute_groups): Include the margins in the size computation. * src/print-cell.c (print_cell_range): Start printing from the start_row, not from zero. * src/print-preview.c: Change of plans. We now use a metafile, we render all the code there. And then we use the new metafile operations for rendering a specific page. * src/item-cursor.c (item_cursor_autofill_event): Change this to destroy again. 1999-09-01 Miguel de Icaza * src/print-preview.c (print_preview_print_done): Show the first page here. 1999-09-02 Jody Goldberg * src/clipboard.c (clipboard_paste_region) : Check that another workbook has not already freed the selection before releasing. (x_selection_received) : Ditto. (x_clipboard_bind_workbook) : Init clipboard_paste_callback_data. 1999-09-01 Jody Goldberg * src/sheet-object.c (sheet_object_update_coords) : Scale movements by zoom factor. * src/sheet-object-widget.c (sheet_object_widget_update_coords) : Ditto. 1999-09-01 Jody Goldberg * src/sheet.c (sheet_compute_col_row_new_size) : The margin appears to be used for the border used to mark the current cell. This border is not scaled when zoomed. 1999-09-01 Miguel de Icaza * src/file.c (workbook_read): If the file does not exist, create a 1-sheet worbook. * src/print-preview.c: Re-enable zoom in and zoom out after the gnome-print fixes 1999-09-01 Jody Goldberg * src/sheet.c (sheet_move_column, sheet_shift_row, sheet_insert_row, sheet_delete_row, sheet_shift_col) : Don't relocate the expressions. (Bug 2041) 1999-09-01 Pablo Saratxaga * configure.in,po/da.po: added Danish file 1999-08-31 Miguel de Icaza * src/dialogs/dialog-printer-setup.c (do_setup_main_dialog): Enable the print-preview buttons. * configure.in (have_bonobo): Test for gnome-print 0.5 * src/print.c (workbook_print): Adapt to the new gnome-print; Added support for print preview. * src/print-preview.c: New file. Implements the print preview control window. * src/functions/fn-financial.c: Add brace to remove ambiguity 1999-08-31 Jukka-Pekka Iivonen * src/functions/fn-financial.c: Implemented ACCRINT() and DISC(). 1999-08-30 Miguel de Icaza * src/dialogs/dialog-paste-special.c: Typo fix. 1999-08-29 Morten Welinder * src/about.c (dialog_about): Add Ross Ihaka. * src/dialogs/dialog-paste-special.c: Typo. 1999-08-29 Jukka-Pekka Iivonen * src/functions/fn-financial.c: Implemented ACCRINTM(), INTRATE(), RECEIVED(), PRICEDISC(), and PRICEMAT(). * src/func.h, src/functions/fn-date.c: Made get_date public. 1999-08-29 Morten Welinder * src/functions/fn-lookup.c (gnumeric_indirect): Plug leak. * src/format.c (pre_parse_format): Don't overrun string. (format_number): Plug leak. * src/workbook.c (workbook_do_destroy): Typo. 1999-08-28 Miguel de Icaza * src/dialogs/*.glade.h: Make sure every dialog box has updated .glade.h and add glade.h generation to the summary, names and import glade files. 1999-08-28 Karl Eichwalder * gnumeric.desktop: Sort entries. (Name): Add `de'. (Comment): Ditto. * src/dialogs/dialog-zoom.c (dialog_zoom): Help xgettext to recognize the strings as `no-c-format'. * src/formats.c: Ditto. * src/gnumeric-sheet.c: Ditto. 1999-08-27 Karl Eichwalder * src/workbook.c: Typo. * src/workbook.c (sheet_action_delete_sheet): Change messages string. * src/workbook.c (sheet_action_delete_sheet): Ditto. 1999-08-26 Jukka-Pekka Iivonen * src/functions/fn-financial.c: Implemented ISPMT(). 1999-08-25 Jukka-Pekka Iivonen * samples/finfuns.xls: Fixed the test of MIRR. * src/functions/fn-financial.c: Implemented FVSCHEDULE(). 1999-08-24 Jukka-Pekka Iivonen * src/functions/fn-financial.c: Implemented TBILLEQ() and started MIRR(). 1999-08-23 Jukka-Pekka Iivonen * src/functions/fn-financial.c: Implemented TBILLPRICE() and TBILLYIELD(). 1999-08-22 Jukka-Pekka Iivonen * src/dialogs/dialogs-solver.c: Fixed a lot of things, memory leaks and bugs. The backend is still not there (but wait, one of these days it may get there). * src/dialogs/dialogs.h, src/dialogs/dialogs-analysis-tools.c: hbox_pack_label_and_entry made public. * src/collect.[ch], src/functions/fn-financial.c: Removed collect_dates. Added a flag COLLECT_DATES to callback_function_collect instead. 1999-08-22 Miguel de Icaza * src/main.c (gnumeric_main): New Bonobos need to issue the bonobo_activate() call. 1999-08-21 Miguel de Icaza * src/workbook.c (workbook_new_with_sheets): Fixed hardcoded buffer. 1999-08-20 Jukka-Pekka Iivonen * samples/finfuns.xls: Made all the dates to use DATE() function instead of using strings in scandinavian style. 1999-08-20 Jukka-Pekka Iivonen * src/fn-financial.c: Made the last two arguments of PMT and PPMT optional. 1999-08-20 Jukka-Pekka Iivonen * src/fn-financial.c: DDB() implemented. * src/fn-stat.c: QUARTILE() implemented. 1999-08-20 Jukka-Pekka Iivonen * po/de.po: Removed the last bogus msgid to make it compile again. * src/sheet.c (sheet_insert_object): Added #if ENABLE_BONOBO to make it compile without BONOBO. * src/gnumeric-sheet.c (gnumeric_sheet_drag_data_get): Ditto. * src/collect.[ch]: Wrote collect_dates and collect_dates_value. * src/fn-financial.c: DB() and XNPV() implemented. DOLLARDE() and DOLLARFR() fixed. * src/fn-date.c, src/func.h: get_serial_date made public. * TODO: Killed the four functions above from the todo list. 1999-08-19 Miguel de Icaza * src/workbook.c (workbook_container_get_object): Finish implementing this routine for responding to monikers. (create_graphic_cmd): temporarily bind this to Generic Bonobo object insertion. (cb_sheet_check_dirty): Make the dialog parent be the workbook window. * src/workbook.h (Workbook): Include a GnomeUIHandler. * src/sheet.c (sheet_insert_object): Enable this function again and update it to match the latest Bonobo developments. * src/sheet.h (Sheet): Include a pointer to the active object frame. * src/sheet-object.c (sheet_set_mode_type): Do deactivation of Bonobo frames here. * src/gnumeric-sheet.c (gnumeric_drag_data_get): Beginning of drag and drop support for Bonobo monikers. * src/item-grid.c (drag_start): More DnD support for Gnumeric selections using Monikers. * src/sheet-object-container.c (user_activation_request_cb, view_activated_cb, get_file_name): New routines for dealing with the Bonobo object action in Gnumeric. (sheet_object_container_land): Do object selection here for now. Support both PersistStream and PersistFile * src/sheet-object.c: * src/workbook.c (cb_sheet_check_dirty): Bind the dialog to the main window. 1999-08-20 Michael Meeks * src/cell.c (cell_set_text_simple): Add checks for over/under flow on integer reading... fall back to double values. 1999-08-19 Miguel de Icaza * src/cell.c (cell_content_changed): Ok, Paolo corrected me. This is not what he wanted. 1999-08-16 Michael Meeks * src/fn-lookup.c (gnumeric_indirect): Fix leak Update to use new cellref_*_get functions. * src/parser.y (return_cellref): Use new function. * src/sheet.c (cellref_get): Implemented (cellref_a1_get): Snarf from parser.y :-) (cellref_r1c1_get): Implemented. 1999-08-17 Miguel de Icaza * src/workbook.c (workbook_class_init): Added cell_content_changed signal. (workbook_do_destroy): Do not enable widgets to be focused. * src/cell.c (cell_content_changed): Calls workbook_cell_changed. This is for Paolo and his speech system for GNOME. * configure.in: New bonobo detection code and support for not compiling Bonobo support even if it is present on the system 1999-08-17 Jukka-Pekka Iivonen * samples/statfuns.xls: Updated the tests of LINEST and TREND to cover more possible cases. 1999-08-15 Jody Goldberg * src/format.c (split_time) : Use a integer to avoid problems with rounding when compiling with optimization. Be extra careful to round the result of the initial scaling. * src/sheet-view.c (vertical_scroll_event, horizontal_scroll_event) : Only move and append to the selection if the cursor actually moves. * src/dialog-function-wizard.c (arg_data_list_new) : Constness. * src/expr.c (eval_expr_real) : Add OPER_PERCENT. (do_expr_decode_tree) : Ditto. (expr_dump_tree) : Ditto. * src/expr.h : Ditto. * src/parser.y : Add function build_unary_op, and support exp '%'. Precedence is a GUESS. 1999-08-16 Michael Meeks * src/widget-editable-label.c (el_start_editing): Remove GTK_WIDGET_SET/UNSET_FLAGS (GTK_CAN_FOCUS): broken for scrolling notebooks. (el_stop_editing): ditto. * src/workbook.c (workbook_setup_sheets): remove unset FOCUS on notebook. 1999-08-15 Jukka-Pekka Iivonen * src/fn-stat.c: Implemented TREND (mostly). Made the second argument of LINEST optional. 1999-08-15 Jody Goldberg * src/expr.c (eval_expr_real) : Don't free empty cells in OPER_CONCAT. 1999-08-14 Jody Goldberg * src/clipboard.c (clipboard_release) : Use the original row/col to calculate offsets when pasting cells that relocate references. (clipboard_copy_cell_range) : Handle relocation. * src/expr.c (do_expr_decode_tree) : Duplicate the error message because someone is going to free it. (expr_relocate) : New Function. * src/cell.c (cell_relocate) : Use expr_relocate. (cell_copy) : Don't NULL out the row/col/sheet in the copied cell. It gets reset on entry and is useful information. (paste_cell) : Handle relocate. (clipboard_copy_cell_range) : Ditto. * cell.h : Differentiate CELL_COPY_TYPE_CELL into CELL_COPY_TYPE_CELL_ABSOLUTE or CELL_COPY_TYPE_CELL_RELATIVE, to deal with cut vs paste. * src/sheet-autofill.c : Use cell_relocate to test for out of bounds. 1999-08-14 Jody Goldberg * src/workbook.c (wb_edit_key_pressed) : Support F4 toggling abs/relative. * src/expr.h : Constify FunctionDefinition. * src/fn-information.c : Use 'Red' instead of 'red' to match XL. * src/func.c (function_get_category, fn_def_init, function_add_nodes, function_add_args) : Constify. 1999-08-15 Morten Welinder * src/fn-stat.c (gnumeric_frequency): Fix leak (bin_array). Fix leak (data_cl.entries). Fix leak (bin_cl.entries). Fix leak (floats for data). Fix leak (floats for bins). Fix leak (count). (gnumeric_linest): Simplify. (gnumeric_intercept): Simplify. (gnumeric_slope): Simplify. (gnumeric_forecast): Simplify. * src/collect.c (collect_floats_value): Make non-static. (float_range_function2): Plug leak. * src/Makefile.am (GNUMERIC_BASE_SOURCES): Add regressions.[ch]. * src/style.c (style_font_unref): Fix obsolete warning. 1999-08-12 Kjartan Maraas * src/fn-math.c: Typo fixes. 1999-08-12 Jukka-Pekka Iivonen * src/fn-stat.c: Implemented the simplest case of LINEST() function. 1999-08-12 Jody Goldberg * src/fn-date.c (gnumeric_date) : Fix typo that was moving us 1900 years into the future. * src/formats.c (cell_format_numbers) : Use 'Red' rather than 'red' to match XL better. 1999-08-11 Jody Goldberg * src/gnumeric-sheet.c ( move_cursor_horizontal, move_cursor_vertical, move_horizontal_selection, move_vertical_selection, selection_cursor_move_horizontal, selection_cursor_move_vertical) : selection_expand_horizontal, selection_expand_vertical) : Support Ctrl-Arrow which jumps to the boundaries of non-blank ranges. * src/sheet.c (sheet_find_boundary_vertical, sheet_find_boundary_horizontal) : New functions, to find the start and end of ranges. They also ensure that the corner which was moved stays visible. (sheet_selection_extend_vertical) : Use sheet_find_boundary_vertical. (sheet_selection_extend_horizontal) : Use sheet_find_boundary_horizontal. 1999-08-11 Jukka-Pekka Iivonen * src/fn-string.c: Fixed the rounding of DOLLAR() function. * src/fn-financial.c: Some minor cleaning. * src/func.h: Added prototypes for callback_function_make_list. * src/fn-stat.c: Fixed PROB() function. 1999-08-11 Michael Meeks * plugins/text/text-io.c: Prototypes updated. 1999-08-11 Jukka-Pekka Iivonen * TODO: Updated the remaining work of build-in functions. * src/fn-stat.c: Implemented FREQUENCY(). 1999-08-09 Miguel de Icaza * src/xml-io.c (xml_workbook_write): Handle locale switching here. (xml_workbook_read): Handle locale switching here. * src/file.c: Removed all references to saving and re-setting the locale. This should be handled in the xml-io code. 1999-08-10 Miguel de Icaza * src/workbook.c (workbook_do_destroy): remove g_free from the workbook. We are now a GtkObject. 1999-08-09 Miguel de Icaza * src/xml-io.c (xml_workbook_write): Move the locale setting/resetting here, instead of putting it all over the place. 1999-08-09 * src/xml-io.c (xml_workbook_read): Adjusted to use the new file open convention. * src/file.h: File open methods now take a workbook as an argument instead of creating it themselves. Required for the GNOME::Persist bonobo interfaces. * src/file.c (workbook_read): Fix the workbook creation order to keep the locale correct if the file did not exist. 1999-08-10 Morten Welinder * src/workbook.c (workbook_do_destroy): Don't free the workbook ourselves. 1999-08-10 Jukka-Pekka Iivonen * samples/statfuns.xls: Updated the tests of functions returning array values. * samples/dbfuns.xls: Added a test for GETPIVOTDATA function. Also added a very simple pivot table. 1999-08-10 Michael Meeks * TODO, DEPENDS, doc/Future-Roadmap, doc/Design: Updated, and added short plugin design section. * doc/saving.txt: Added short section on Summary Information. 1999-08-10 Jukka-Pekka Iivonen * src/fn-math.c: Finished ROMAN(). Gnumeric now supports all the 60 mathematical functions of Excel 2000. 1999-08-10 Jukka-Pekka Iivonen * src/fn-math.c: Added MDETERM(). 1999-08-09 Michael Meeks * src/workbook.c (workbook_class_init): Moved hack to workbook.h, and removed comment. 1999-08-09 Jukka-Pekka Iivonen * src/fn-math.c: Added MINVERSE(). 1999-08-09 Michael Meeks * src/sheet.c (sheet_cell_add): Optimise by checking last element of the list for a simple append before calling g_list_insert_sorted. CRowSort took up way too much time in my profile :-). [ This fix is quite temporary ] * src/workbook.c (workbook_init): Conditionaly compile bonobo specific code. (workbook_class_init): Grotesque hack so it compiles. 1999-08-08 Jacob Berkman * src/workbook.c: use smaller menu stock icon instead of large one 1999-08-06 Miguel de Icaza * src/xml-io.c (xml_write_summary): I think this is the correct fix. We should not add childs if no summary info is available. * src/corba-sheet.c (Sheet_cell_set_font): Use the standard procedure to set the font. * src/cell.c: deleted finally cell_set_font. * src/workbook.c: Reorganization to make the code be a GtkObject. Redone the destruction bits of the Workbook. * src/workbook.h: Split sheet.h into workbook.h and sheet.h * src/workbook.h: Now the Workbook is a GtkObject or a GnomeObject, depending on the compilation flags. 1999-08-05 Morten Welinder * src/dialog-printer-setup.c (dialog_print_info_destroy): Plug leaks. * src/print-info.c (hf_format_render): Plug leak. (render_opcode): Constify. * src/item-cursor.c (item_cursor_autofill_event): Don't unref, but destroy. We no longer own the ref. 1999-08-05 Michael Meeks * src/file.c (workbook_import): Fix control flow to have 1 return. fix leak. 1999-08-05 Jody Goldberg * src/func.c (function_get_category) : Lookup/store in sorted list. 1999-08-05 Morten Welinder * src/cell.c (cell_set_font): Obsolete -- #if 0 for now. * src/cell.h: Remove now-static cell_formula_changed, calc_text_dimensions, and cell_set_font. * src/dialog-analysis-tools.c (add_output_frame): Plug leak. 1999-08-05 Michael Meeks * src/file.c (workbook_import): Major hacks to get round quirks in libglade. * src/import.glade: Add label to the container. 1999-08-04 Miguel de Icaza * src/cell.c (calc_text_dimensions): Made static. (queue_cell): Killed dependency_deep_frozen routines, this was archaic code. (cell_formula_changed): Made static. * src/sheet-autofill.c (autofill_register_list): Make static. 1999-08-03 Michael Meeks * src/workbook.c (workbook_setup_edit_area): Removed function wizard. 1999-08-03 Miguel de Icaza * src/corba-sheet.c (fill_corba_value): Corrected the argument here. 1999-08-03 Jody Goldberg * src/plugin.h (struct) : 'private' is a C++ keyword. * src/sheet.h : Add GHashTable *dependency_hash to sheet. * src/sheet.c (sheet_destroy) : Clear dependency_hash. * src/eval.c (dependency_hash_init) : dependency_hash sheet specific. (add_cell_range_dep) : Ditto. (cell_add_dependencies) : Ditto. (cell_drop_dependencies) : Ditto. (region_get_dependencies) : Ditto. (cell_get_dependencies) : Ditto. (add_cell_range_dep) : Increment ref_count AFTER looking for duplicates. * src/workbook.c (workbook_do_destroy) : Add some debugging code to catch dangling dependancies. 1999-07-27 Miguel de Icaza * src/corba-workbook-factory.c (WorkbookFactory_read): Duplicate CORBA Object server here. (WorkbookFactory_create_object): and here. 1999-08-03 Robert Brady * gnumeric.spec.in, README: require gnome-print 0.3 or greater. (BUGFIX #1829) 1999-08-02 Morten Welinder * src/expr.c (eval_expr_real): Handle integer operations more carefully with respect to overflow. * src/cell.c (cell_cleanout): Don't unlink unless there is a sheet to unlink from. * src/collect.c (float_range_function2): Actually call the right function. (collect_floats_value): Fix type of result. * src/mathfunc.c (range_rsq_pop, range_rsq_est): New functions. * src/fn-stat.c (gnumeric_pearson): Simplify. (gnumeric_rsq): Simplify. 1999-08-02 Jody Goldberg * src/fn-information.c (gnumeric_n) : Fix boolean support. * src/corba-sheet.c: Correct previous typo. 1999-08-02 Elliot Lee * gnumeric.spec.in: Fix the .spec file to include correct documentation pieces. * doc/C/Makefile.am: Work with builddir != srcdir * plugins/lotus-123/Makefile.am: boot.h not needed. lotus-types.h is. * plugins/xbase/Makefile.am: boot.h not needed. * po/Makefile.in.in: v3 * src/corba-sheet.c: Use a compilable thing for error string. 1999-08-02 Morten Welinder * src/expr.c (eval_expr_real): Plug leak... 1999-08-02 Jody Goldberg * src/expr.c (eval_expr_real): Fix bool <-> number comparisons to match excel approach. TRUE&FALSE > numbers. * src/item-bar.c (item_bar_event) : Button3 should select the current row/col before bringing up the edit menu. * src/sheet.c (sheet_cell_foreach_range) : return NULL not FALSE on precondition failure. * src/value.[ch] : Add value_area_foreach * src/fn-date.c (gnumeric_networkdays) : Correct the modulo for weekends and add support for holidays via value_area_foreach. * src/sheet.c : Correct some documentation 1999-08-01 Jody Goldberg * samples/operator.xls : Test workbook for operators. * src/Gnumeric.idl : Add VALUE_ERROR, VALUE_BOOLEAN, VALUE_EMPTY in a few more places * src/fn-lookup.c : Ditto. * src/fn-math.c : Ditto. * src/fn-stat.c : Ditto. * src/fn-string.c : Ditto. * src/dialog-cell-sort.c : Ditto. * src/corba-sheet.c : Ditto. * src/fn-eng.c : Support VALUE_BOOLEAN and simplify comparison logic in DELTA and GESTEP. * src/expr.c (compare_bool_bool) : New function. (compare_int_int, compare_float_float) : Take (Value *) and do cast internally. (is_null_string) : Rename to value_is_empty_cell, support VALUE_EMPTY. and move to src/value.c. (compare) : Rework to bring into closer compliance with XL. (expr_eval_real) : Ditto, replace 'Type [Mm]ismatch' with '#!VALUE'. use eval_expr rather than eval_expr_real for arithmetic binary operators. Use value_get_as_float rather than value_cast_to_float. (eval_expr) : Remap 'VALUE_EMPTY' to int(0) * src/value.h : Adjust enumeration so that BOOLEAN < INTEGER < FLOAT remove value_cast_to_float * src/value.c (value_get_as_*) : Support NULL values. (value_cast_to_float) : Remove. * src/sheet.c (sheet_cell_formula_unlink) : Add precondition to handle problems using deleted cells. 1999-08-01 Morten Welinder * src/fn-stat.c (gnumeric_covar, gnumeric_correl): Simplify using range functions. * src/workbook.c (file_open_cmd): Plug leak. * src/mathfunc.c (range_covar, range_correl_pop, range_correl_est): New functions. * src/collect.c (collect_floats_value, float_range_function2): New functions. 1999-08-01 Michael Meeks * src/workbook.c (workbook_setup_sheets): Added comment about making workbook sheets' notebooks scrollable. * src/fn-database.c (gnumeric_dmin, gnumeric_dmax, gnumeric_daverage): Only use the value if it is a number. (find_column_of_field): Use g_strcasecmp instead of strcmp. (criteria_test_equal, unequal): ditto; test this. * src/fn-information.c (gnumeric_cell): Changed broken cell_fetch's to cell_gets. 1999-08-01 Jody Goldberg * src/fn-date.c (get_serial_date): Constify. Improve handling of date_serial 0. (gnumeric_networkdays): Add partial implementation. (MW: turned off.) * src/eval.c (add_value_deps): Handle empty value. * src/collect.c (callback_function_collect): Ignore empty values. * src/gnumeric-sheet.c (gnumeric_sheet_key_mode_sheet) : Support moving through the sheets. * src/Gnumeric.idl : Add VALUE_ERROR, VALUE_BOOLEAN, VALUE_EMPTY in a few more places. * src/corba-sheet.c : Ditto. * src/value.c (value_new_empty): New function. (value_dump, value_copy_to, value_get_as_bool, value_get_as_string, value_get_as_int, value_get_as_float): Handle empty value. 1999-08-01 Morten Welinder * src/expr-name.c (expr_name_add): Fix bogus check. (expr_name_remove): Abort until someone fixes this. * src/style.c (style_font_unref): Unref the font. * src/expr.c (eval_expr_real): Fix OPER_CONCAT case. From Jody. * src/value.c (value_cast_to_float): FMR fix from Jody. 1999-08-01 Manish Vachharajani * src/sheet-object-container.c: fix reference to gnome_client_site_bind_bonobo_object to read gnome_client_site_bind_embeddable 1999-08-01 * src/workbook.c: move the about-entry lower to make it more consistent with the rest of GNOME. 1999-08-01 Morten Welinder * src/format.c (format_number): YAL -- yet another leak. * src/fn-string.c (gnumeric_text): Plug leak. * src/expr.c (do_expr_tree_unref): Plug array value leak. * src/cell.c (cell_set_array_formula): Unref the wrappers so we don't leak a reference. * src/fn-math.c (gnumeric_countif): Initialise total_num member. 1999-07-31 Morten Welinder * src/fn-database.c (free_criterias): Plug massive leak. (parse_database_criteria): Plug leak. (parse_criteria): Constify. (find_column_of_field): Plug leak. (parse_database_criteria): Plug leak. (gnumeric_dproduct): Plug leak. (gnumeric_dvar): Plug leak. (gnumeric_dmin): Plug leak. (find_column_of_field): Plug leak. * src/fn-math.c (gnumeric_seriessum): Plug leak. (gnumeric_subtotal): Plug leak. * src/fn-lookup.c (gnumeric_address): Fix memory corruption. 1999-07-31 Robert Meeks * src/fn-information.c (translate_table): Populated. 1999-07-31 Michael Meeks * src/fn-information.c (gnumeric_cell): Implemented col, row, address, contents. Start of format. (translate_cell_format): Start of format translation. 1999-07-31 Morten Welinder * src/fn-logical.c (gnumeric_if): Fix case of first argument yielding an error. * src/expr.c (expr_dump_tree): Constify. * src/func.c (function_iterate_do_value): Fix behaviour of strict functions. * src/expr.c (do_expr_tree_invalidate_references): Handle VALUE_BOOLEAN and VALUE_ERROR. (eval_expr_real): Make comparisons strict. * src/summary.c (summary_info_free): Fix leak. (summary_item_free): Fix leak. * src/fn-misc.c (gnumeric_iserror): Fix leak. (gnumeric_error_type): Fix leaks. (gnumeric_isna): Fix leak. (gnumeric_iserr): Fix leak. * src/fn-information.c (get_value_class): Fix leak. 1999-07-31 Michael Meeks * src/fn-information.c (gnumeric_isref): Implemented. 1999-07-30 James Youngman * src/fn-eng.c (gnumeric_besseli): Implemented. (gnumeric_besselk): Implemented. (eng_functions_init): Add relevant inits. Include mathfunc.h 1999-07-30 Morten Welinder * src/cell.c (cell_cleanout): New function. (cell_set_formula): Don't bother with CELL_ERROR. Set value field in all cases. (cell_set_array_formula): Set cell values. (cell_set_value_simple): Simplify using cell_cleanout. (cell_set_text_simple): Ditto. (cell_set_formula_tree_simple): Ditto. (cell_destroy): Ditto. (cell_get_text): Simplify. (cell_get_content): Ditto. * src/eval.c (cell_eval): Reorganise slightly. * src/expr.c (eval_expr_real): value should no longer be null. * src/cell.h (CELL_ERROR): Obsolete. * src/print-info.h (hf_formats): Make extern. * src/summary.h (summary_item_name): Make extern. 1999-07-29 Michael Meeks * src/cell.c (cell_set_text_simple): Chomp whitespace off the end of integers ( other spreadsheets do this ). 1999-07-28 Michael Meeks * src/summary.c: Update, was out of step with the header. 1999-07-28 Michael Meeks * src/item-grid.h: Added border_gc[BORDER_MAX] to ItemGrid. * src/item-grid.c (item_grid_draw_cell): Border rendering code. Make rendering conditional on debug - this looks awful. (item_grid_realize): ditto + struct of types in style_border_data. (item_grid_unrealize): clean up after myself. 1999-07-27 Jody Goldberg * src/fn-date.c : Add EOMONTH, and partial WORKDAY. * src/formats.c : Add more date formats. * src/fn-math.c (gnumeric_transpose) : no need for an array if the input is a singleton. * src/expr.c : Add comment explaining the need for a re-org to correctly handle implicit intersetion vs arrays with operators. Move all value_* functions into. * src/value.c : Here. * src/func.c : Move const value initialization into value.c. * src/clipboard.c (clipboard_prepend_cell) : Return Value * as per change to VALUE_ERROR. * src/style.h : Add STYLE_ORIENT_MAX to remove ugly magic number that will change when we add support for diagonals. * src/print-cell.c (print_cell_border, print_border) : Use enum rather than hard coding the number of border types. * TODO : Add implicit intersection for operators. 1999-07-25 Jody Goldberg * plugins/guile/plugin.c, plugins/python/python.c src/{Makefile.am, cell.[ch], collect.[ch], eval.c, expr-name.c, expr.[ch], fn-database.c, fn-date.c, fn-eng.c, fn-financial.c, fn-information.c, fn-logical.c, fn-lookup.c, fn-math.c, fn-misc.c, fn-sheet.c, fn-stat.c, fn-string.c, format.c, func.[ch], sheet-object-container.c, sheet.[ch]} : Add VALUE_ERROR, VALUE_BOOLEAN, Change many signatures to return Value for errors. * icons/chart_*.png : Add Some images in preparation for re-enabling the graph wizard. * src/expr.c (eval_funcall) : When a single row or column is passed to a function expecting a single value, take the intersection of the evaluation position and the range. (cell_ref_get_abs_col, cell_ref_get_abs_row) : New functions. * src/value.[ch] : New files with Value support routines split out from expr.[ch] 1999-07-26 Michael Meeks * src/corba-sheet.c (fill_corba_value): Remove redundant Sheet * from cellref_name. 1999-07-26 Michael Meeks * src/xml-io.c (xml_read_cell): Commented out freeze/thaw deps. * src/cell.c (cell_deep_freeze_dependencies): Added warning not to use: strangely it doesn't work... investigate later. 1999-07-25 Michael Meeks * src/xml-io.c (xml_read_cell): Add freeze/thaw dependencies, and fix exit condition to restore state to correct coolness. * src/cell.h: Added prototypes. * src/cell.c (cell_content_changed, cell_formula_changed): (cell_deep_thaw_dependencies, cell_deep_freeze_dependencies): Added optimisation for load/save stuff. 1999-07-25 Michael Meeks * src/xml-io.c (xml_read_summary): Fix some massive cock-ups, how did this ever work. (xml_read_names): ditto. (xml_workbook_read): Shifted read_names down to where we actualy have the inter-sheet reference names in place. * src/expr.c (expr_tree_invalidate_references): Debugging that needs cleaning to new PP stuff #if-def'd out. (expr_tree_fixup_references): ditto. * src/xml-io.c (xml_write_names, xml_read_names): Implemented (xml_workbook_write, xml_workbook_read): Hooks added, but reading disabled: something dodgy somewhere. * src/sheet.c (sheet_lookup_by_name): Fixed to use simply a Workbook pointer. * src/workbook.c (workbook_set_auto_expr): Fix old hack using new PP stuff. * src/sheet.c (sheet_fill_selection_with): Updated to new PP code. * src/parser.y (gnumeric_expr_parser): Updated to new PP code, removed redundant and nasty _unsafe_expr_parser hack. Essentialy nothing new, but removes daft parser_sheet and replaces with parser_workbook, leaving sheet stuff to the evaluation stage. * src/dialog-define-names.c: Major fixups, killed obscure bug cause by freeing a copy of a list I passed to gtk_list_append_items. * src/expr.c (expr_parse_string, do_expr_decode_tree): (expr_decode_tree): Updated to new * src/expr-name.c (expr_name_create): Added for convenience. (expr_name_value): Updated to new PP scheme * src/cell.c (cell_set_formula, cell_get_text, cell_get_content): Update to new ParsePosition scheme. * src/expr.c (parse_pos_init, parse_pos_cell): Created. * src/expr.h: Add ParsePosition & prototpes 1999-07-25 Michael Meeks * src/dialog-define-names.c (update_edit): use expr_name_value. (grab_text_ok): Update to use new functions. * src/expr-name.c (expr_name_value): Added. (expr_name_create): Convenience function * src/xml-io.c (xml_workbook_write): Added names writing. 1999-07-24 Michael Meeks * src/expr-name.c (expr_name_add): Add check for circular references in (name_refer_circular): created. (add_real): More paranoia. 1999-07-23 Michael Meeks * src/expr-name.c (expr_name_list): Expand. (expr_name_remove): Serious bug freeing names. (expr_name_lookup): precondition. (expr_name_remove): more sanity checks. * src/dialog-define-names.c (fill_list): Append instead of inserting items. use "select" signal, hand the correct pointer on. Implemented guts, fixed lots of bugs. 1999-07-25 Karsten Weiss * src/print.glade.h: Fixed three typos. * src/hf-config.glade.h: Fixed a typo. Is this the right place to fix the typos or are they auto-generated from some other source? 1999-07-21 Miguel de Icaza * src/dialog-printer-setup.c (preview_page_destroy): Clear the pointers after unrefing. * src/print.c (setup_rotation): Add the rotation code for the vertical/horizontal printing. 1999-07-22 Michael Meeks * src/dialog-define-names.c (dialog_define_names): Removed all the dead code. Lots of new code ... not there yet though. * src/workbook.c: Enabled names menu item. * src/dialog-summary.c: add file header. * src/Makefile.am (glade_DATA): Added summary.glade and names.glade seems I didn't do this earlier: odd. * names.glade: Created. 1999-07-22 Michael Meeks * src/expr-name.c: Stylistic precondition fixes, simplification & workbook integration. * src/workbook.c (workbook_core_new): init names. (workbook_do_destroy): add name clean. * src/sheet.h: Add Workbook->names. * src/func.h: Added comments moved from expr.h 1999-07-21 Richard Hestilow * gnumeric.gnorba: Fix "Embeddable" typo (was IDL:/GNOME/Embeddable, should have been IDL:GNOME/Embeddable) 1999-07-21 Michael Meeks * src/widget-font-selector.c (fs_init): Convert g_error to g_warning on missing glade_xml_new. * src/Makefile.am (GNUMERIC_CORBA_GENERATED): Make this empty if BONOBO is not installed, should kill peoples Gnumeric.idl problems with luck. * configure.in: Add lotus-123 * plugins/Makefile.am: ditto. * src/main.c: Remove xbase include. 1999-07-20 Jody Goldberg * src/expr.c (value_area_fetch_x_y) : make value_zero local. (eval_expr) : renamed eval_expr_real, and allowed it to return NULL in all the places that make sense. (eval_expr) : New function. Calls eval_expr_real and returns 0 on NULL with no error set. Until VALUE_ERROR is in place things will look funny. 1999-07-20 Miguel de Icaza * src/item-bar.c (bar_draw_cell): Move the dimension computaiton of the font after we have figured which font to use. Before we did all the computaiton based on the default font, which is not always the font used (we use bold font for selected rows). This fixes the bug Morten reported. 1999-07-20 Jody Goldberg * src/fn-math.c : Moved gpow10 from here. * src/utils.[ch] : to here. * src/expr.c (value_area_get_x_y) : return NULL in all cases of invalid refernces dont fake a 0. Rename TYPE_ERROR -> TYPE_MISMATCH. (is_null_string) : New function. (compare) : Allow equality tests between empty/error things too. (eval_expr) : Allow comparisons of empty/error values. It can handle it now. (OPER_ARRAY) : Use value_area_get_x_y not fetch_x_y, handle empty/error. (value_get_as_string) : Fix typo in recent unlogged change. The change might break importing files from a different locale. * src/fn-string.c : Add TEXT, improve VALUE, REPLACE so that they passes more tests. * src/number-match.c (compute_value) : Partial support for thousands separator. Why doesn't this code use locale ? * src/format.c (format_value) : better support for ranges, attempt to work around problem of a thousands seperator in a date format. * src/cell-draw.c (cell_draw) : Fix potential for infinite loop with HALIGN_FILL. * src/print-cell.c (print_cell_text) : Ditto. * src/parser.y (make_string_return) : A string of the form "..." is a string, don't try to parse it as a number. * src/pattern-selector.[ch] : pattern_selector_select made static. In preparation for different approach. 1999-07-19 Andreas Voegele * src/parser.y (gnumeric_unsafe_expr_parser): Use the locale to figure out the correct separator * src/file.c (workbook_read): According to the GNU libc documentaiton retrieving the current locale should be done by passing NULL to setlocale as the locale argument. 1999-07-17 Michael Meeks * src/workbook.c (workbook_setup_edit_area): Enabled function wizard. 1999-07-16 Michael Meeks * src/summary.c (summary_item_as_text): Implemented. (summary_item_dump): Simplified. * src/xml-io.c (xml_write_summary, xml_read_summary): Created. (xml_workbook_read, xml_write_summary): Added summary stuff. 1999-07-17 Jukka-Pekka Iivonen * doc/C/analysis-tools.sgml: Added documentation of anova, single factor tool. 1999-07-14 Miguel de Icaza * src/fn-misc.c (gnumeric_error): Fixed usage of errors with the non-broken setup. * src/expr.c (error_message_set): Rewrote the error message logic to be clean and clear. Simplified and followed the Gnumeric coding conventions. 1999-07-15 Michael Meeks * src/summary.c (summary_info_add): Add duplicate entry removal. Re-organised structures and enum for convenience. (summary_info_as_list, append_item): Created. (summary_item_dump): Made static. include stdio.h Add 'Category' and 'Manager' * src/workbook.c (summary_cmd): Create. Add 'Su_mmary' to file menu. * dialogs.h: Added summary_update. * src/Makefile.am (GNUMERIC_BASE_SOURCES): Add dialog-summary.c * dialog-summary.c: Created. * summary.glade: Created. 1999-07-13 Jody Goldberg * src/fn-lookup.c (gnumeric_lookup) : Support default args for width & height. Return cell_value directly for 1x1 results. (gnumeric_hyperlink) : Add stub. * src/expr-name.[ch] (expr_name_add, expr_name_lookup) : Const. * src/parser.y (make_string_return) : Handle special case of "" avoid turning it into a number. 1999-07-13 Michael Meeks * src/Makefile.am (GNUMERIC_BASE_SOURCES): add summary.[ch] * src/workbook.c (workbook_core_new): Hook in summary info. (workbook_do_destroy): ditto. (deps_output): debugging hook. * src/sheet.h: Added SummaryInfo to Workbook. * src/summary.[ch]: Added. 1999-07-11 Michael Meeks * src/cell-draw.c (cell_draw): Added handy debug for when cell->text is duff. 1999-07-13 Morten Welinder * src/fn-string.c (gnumeric_search): Actually start search where advertised. (gnumeric_value): Try harder. * src/style.c (font_init): Print informative message instead of just aborting. (style_shutdown): Remove old code. * src/mathfunc.h: Work around Irix incompatibility. 1999-07-13 Jukka-Pekka Iivonen * src/dialog-analysis-tools.c, src/analysis-tools.c: Implemented Anova, single factor tool. * src/dialog-analysis-tools.c, src/analysis-tools.c: Implemented Anova, two-factor without replication tool. 1999-07-12 Miguel de Icaza * src/print-info.c (save_hf, print_hf_register): Save the headers and footers. Implement registration of new formats. * src/dialog-printer-setup.c (do_hf_config): Added the editing facility to the formats. 1999-07-12 Jody Goldberg * src/Gnumeric.idl : Add SplitsArray array exception for array-formula support. * src/cell.[ch] (cell_set_border) : Const. * src/expr.[ch] (value_area_get_width, value_area_get_height) : Const. * src/fn-math.c : Added TRANSPOSE. * wizards/graphics/*.c : Minor text tweaks so that things come closer to compiling. 1999-07-12 Jukka-Pekka Iivonen * doc/C/analysis-tools.sgml: Small fixes and additions. * src/dialog-analysis-tools.c, src/analysis-tools.c: Added Bernoulli distribution to the Random Number Generation tool. * src/analysis-tools.c: Finished Rank and Percentile tool. * src/analysis-tools.c: Fixed ``F/z/t Critical'' values of the F-Test, t-Test, and z-Test Tools. 1999-07-12 Jukka-Pekka Iivonen * src/dialog-analysis-tools.c, src/analysis-tools.c: Made ``Labels in the first row'' option to actually work. Killed some warnings and bugs related to outputs too. 1999-07-12 Miguel de Icaza * src/cell.c (cell_set_font): Now takes a "points" argument. * src/Gnumeric.idl (Sheet): Take a double for the cell_set_font points parameter. 1999-07-11 Raja R Harinath * configure.in: Don't use `foo >& /dev/null' style redirection, use `foo > /dev/null 2>&1'. 1999-07-11 Miguel de Icaza * src/dialog-cell-format.c (apply_font_format): Use the FontSelector here. * src/widget-font-selector.c (reload_preview): New approach for font loading, by using the scale explicitly I got it to work ;-). (font_selector_choose): New routine to set the font style. * src/sheet.c (sheet_init_default_styles): Change of plans, we are going to use 80 units for the default width. * src/widget-font-selector.c: New file. A simplified and robust font selector for Gnumeric. (fs_fill_font_name_list): Free this. 1999-07-11 Jody Goldberg * src/item-grid.c (context_cut_cmd, context_copy_cmd context_paste_cmd, context_paste_special_cmd, context_insert_cmd, context_delete_cmd, context_clear_cmd, context_cell_format_cmd, create_popup_menu, item_grid_popup_menu) : Operate on Sheet* rather than ItemGrid*. * src/item-bar.c (item_bar_event) : Popup an item_grid_popup_menu when Button3 is pressed. Excel also adds an entry to change col widths/row heights, that will be next TODO. * src/dialog-insert-cells.c, src/dialog-delete-cells.c : Short circuit the menus when an entire row/column is selected. This fixes the problem of selecting a column and accidentaly inserting a row would clear the sheet inserting MAX_ROW rows and erasing everything ... * src/cell-draw.c (cell_draw) : Remove use of str_trim_spaces and correct the bounding rectangle size for multiline entries. (cell_split_text) : Rework logic to strip spaces when a forced split causes a linebreak @ those spaces. Plus more comments. * src/print-cell.c (cell_split_text, print_cell_text) : Ditto. Switch accumulators to doubles. * src/parser.y : Moved dump_value from here. * src/expr.c : to here. And changed the format of CellRanges to be more appealing. * src/cell.c (cell_relocate) : Add some cruft to handle relinking the corner cell of an array formula. * src/clipboard.c (clipboard_prepend_cell) : Renamed from clipboard_append_cell. So that there is truth in naming. (clipboard_copy_cell_range) : Reverse the result of clipboard_prepend_cell so that the upper left corner is 1st. (Sheet *sheet, int col, int row, Cell *cell, void *user_data) * src/expr.c (eval_range) : New function to ensure that range arguments are recalculated. (eval_expr) : Use it. * src/sheet.c (range_check_for_partial_array) : New function. To avoid subdividing arrays does some obvious optimizations. (sheet_fill_selection_with) : Split out from here. (sheet_delete_col, sheet_delete_row) : Used here too. 1999-07-11 Michael Meeks * Sort ChangeLog out, apologies. 1999-07-10 Michael Meeks * src/func.c (function_iterate_do_value): Clean to use new macro. * src/fn-stat.c (gnumeric_rank, gnumeric_prob, gnumeric_steyx), (gnumeric_ftest, gnumeric_slope, gnumeric_percentrank), (gnumeric_ttest, gnumeric_forecast, gnumeric_intercept): New sheet support. * src/fn-math.c (gnumeric_countif): Cleaned with nicer sheet select macro. (gnumeric_sumif, gnumeric_sumx2my2, gnumeric_sumxmy2), (validate_range_numeric_matrix): Added new sheet support. * src/fn-information.c (gnumeric_countblank): Added correct sheet support. * src/fn-database.c (find_column_of_field): Add EvalPosition to get valid Sheet * from & use it. (parse_database_criteria, find_cells_that_match): Ditto. Update all references. * src/expr.c (value_area_get_height): Use eval_sheet (eval_funcall): Remove redundant Sheet * setting. * src/expr.h: Add eval_sheet to help all over the place. * src/eval.c (add_cell_range_deps): Use eval_sheet, and make warning more correct.