1. 17 May, 2000 1 commit
    • Jody Goldberg's avatar
      Fix more memory errors. · 98e8cf26
      Jody Goldberg authored
          creating rows/cols when resizing empties.
      
      2000-05-17  Jody Goldberg <jgoldberg@home.com>
      
      	* src/sheet.c
      	(sheet_{col,row}_size_fit_pixels) : Return 0 if there are no cells.
      
      	* src/summary.c (summary_item_as_text) : Be careful to strdup all strings.
      	(g_str_case_equal) : Delete duplicate.
      	(g_str_case_hash) : Delete duplicate.
      	(summary_info_new) : Use gnumeric_strcase_hash & gnumeric_strcase_equal.
      
      	* src/workbook-cmd-format.c (workbook_cmd_format_{column,row}_auto_fit) :
      	  Only mark the sheet as dirty if something was changed.
      
      	* src/stf.c (stf_read_workbook) :  Bring up to date.
      
      	* src/xml-io.c (xml_write_attributes) : Do not use freed memory.
      
      	* src/item-bar.c (item_bar_event) : Autosizing an empty row/col
      	  returns 0.
      98e8cf26
  2. 24 Apr, 2000 1 commit
    • Jody Goldberg's avatar
      Rename ea_status -> selection_descriptor Moved ea_entry here and called it · c2687829
      Jody Goldberg authored
      
      2000-04-24  Jody Goldberg <jgoldberg@home.com>
      
      	* src/workbook-private.h : Rename ea_status -> selection_descriptor
      	Moved ea_entry here and called it edit_line.
      	* src/workbook.c (workbook_get_entry) : new routine.
      
      	* src/dialogs/function-select.glade : Made this a dialog, not a popup.
      
      	* src/summary.c (summary_item_free) : format police.
      	* src/value-sheet.c (value_area_foreach) : Ditto.
      
      	* src/sheet.c (sheet_new) : Init the update flags to FALSE, rather
      	  than TRUE now that the system seems to be getting their initial
      	  state correct when importing, paging and the like.
      	(sheet_load_cell_val) : Use workbook_get_entry.
      	(sheet_find_boundary_horizontal) : format police.
      	(sheet_find_boundary_vertical) : Ditto.
      	(sheet_range_splits_array) : Ditto.
      	(sheet_delete_{cols,rows}) : Ditto.
      	(sheet_restore_row_col_sizes) : Ditto.
      	(sheet_col_get_distance_{pixels,pts}) : Ditto.
      	(sheet_row_get_distance_pixels) : Ditto.
      	(sheet_row_get_distance_pts) : Ditto, Init accumulator.
      
      	* src/selection.c (sheet_selection_set) : format police.
      	(selection_check_for_array) : Ditto.
      	(sheet_selection_walk_step) : Ditto.
      	* src/sheet-view.c (horizontal_scroll_event) : Ditto.
      	(vertical_scroll_event) : Ditto.
      	* src/dialogs/dialog-cell-format.c : Ditto.
      	* src/dialogs/dialog-printer.c : Ditto.
      	* src/dialogs/dialog-workbook-attr.c : Ditto.
      	* src/functions/fn-eng.c : Ditto.
      	* src/functions/fn-lookup.c : Ditto.
      	* src/functions/fn-string.c : Ditto.
      
      	* src/pattern.c (gnumeric_sheet_patterns) : Add a few patterns for
      	  applix.  More are needed, and these are not available in the format
      	  dialog yet.
      
      	* src/number-match.c (compute_value) : Use g_strtod.
      	(format_match) : Ditto.
      
      	* src/item-edit.c : Use workbook_get_entry.
      
      	* src/item-bar.c (item_bar_event) : format police.
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_key_mode_sheet) : Do not set
      	  the focus directly.  Leave that to workbook_start_editing.
      	(gnumeric_sheet_new) : Use workbook_get_entry.
      
      	* src/format.c (render_number) : format police.
      
      	* src/complex.c (complex_from_string) : Use g_strtod.
      	* src/functions/fn-database.c : Ditto.
      
      	* src/colrow.c (cb_row_col_visibility) : format police.
      
      	* src/main.c (gnumeric_main) : Move the workbook_style_test to the
      	  empty case.
      
      	* src/mstyle.c (mstyle_set_pattern) : Add some safety.
      
      	* src/number-match.c (format_match) : Handle empties.
      c2687829
  3. 20 Apr, 2000 1 commit
    • Jody Goldberg's avatar
      Reorg cell contents and assignment. · bedb925b
      Jody Goldberg authored
      Fixs lots of usability details.
      
      2000-04-20  Jody Goldberg <jgoldberg@home.com>
      
      	* src/dialogs/dialog-cell-format.c : Use the edit_pos as the example
      	  not the top left corner.
      
      	* src/functions/fn-stat.c (gnumeric_ftest) : Use eval_pos_cellref
      	  to help localize the strangeness.
      	(gnumeric_ttest) : Ditto.
      
      	* src/xml-io.c (xml_write_cell_and_position) : If this is an array
      	  expression and we are the top left then add attributes to indicate
      	  size of array.  Ignore the rest of the array.
      	(xml_not_used_old_array_spec) : New routinr to handle the old array format.
      	(xml_cell_set_array_expr) : store an array.
      	(xml_read_cell) : Handle the old and the new array formats.
      
      	* src/workbook.c (workbook_close_if_user_permits) : Accept input
      	  first.
      	(wb_edit_key_pressed) : Handle array formulas here.
      	(workbook_detach_sheet) : Do not recalc all if we are exiting.
      	(workbook_start_editing_at_cursor) : When we start editing an
      	  array formula display just the formula not all the extra {}()[][] crap.
      
      	* src/sheet.c (SheetPrivate) : Add a recompute_spans flag.
      	(sheet_calc_spans) : New routine.
      	(sheet_cell_calc_span) : New routine.
      	(sheet_range_calc_spans) : Renamed and extended from
      	  sheet_cells_update.
      	(sheet_update) : Use sheet_calc_spans when necessary.
      	  Update the location region when the edit_pos changes.
      	(cb_recalc_spans_in_col) : Renamed from cb_collect_cells_in_col.
      	  Recalcs spans directly, no need to collect first.
      	(cb_set_cell_content) : New routine to set expr, or expr_and_value.
      	(sheet_range_set_text) : Use cb_set_cell_content, and remember
      	  chosen format with the cell rather than overriding the assigned
      	  format.
      	(sheet_cell_set_text) : Renamed from sheet_set_text.  Be more specific
      	  about how spans, rendering and the rest are handled.
      	(sheet_cell_set_expr) : New routine.
      	(sheet_cell_set_value) : Ditto.
      	(sheet_load_cell_val) : When displaying an array formula add {%s}()[][].
      	(sheet_redraw_cell_region) : Honour spans when redrawing.
      	(sheet_redraw_partial_row) : New routine.
      	(sheet_redraw_cell) : Ditto.
      	(sheet_is_cell_array) : Use cell_is_array.
      	(sheet_range_splits_array) : Renamed from sheet_check_for_partial_array.
      	(sheet_cell_add_to_hash) :  Do not touch spans at this point.
      	(sheet_cell_insert) : Rename from sheet_cell_add made recalc span
      	  optional.
      	(sheet_cell_new) : New routine that does not touch spans.
      	(sheet_cell_remove) : Made redraw optional.
      	(cb_clear_cell_comments) : Remove the cell if there is no comment.
      	(sheet_clear_region) : Remove the cell if there are no comments or
      	  contents.  Flag an update of the status region.
      
      	* src/sheet-view.c (cb_colrow_resize) : New function.
      	(sheet_view_col_size_changed) : Resize all rows, irrespective of
      	(sheet_view_row_size_changed) : existing cells.
      	(sheet_view_redraw_cell_region) : This no longer honours spans.
      
      	* src/sheet-style.c (sheet_style_attach) : Removed call to redraw.
      	sheet_cells_update : rename to sheet_range_calc_spans and move to
      	  sheet.c.
      
      	* src/sheet-autofill.c (autofill_cell) : Use sheet_cell_set_value
      	  rather than set_text.
      
      	* src/selection.c (sheet_selection_changed_hook) : Delete.
      	(sheet_selection_extend_to) : Update the status region to display the
      	  new size.
      	(sheet_selection_cut) : Use sheet_range_splits_array.
      	(selection_check_for_array) : New routine.
      
      	* src/parser.y : Remove icky array formula parsing that conflicted
      	  with array entries.
      
      	* src/number-match.c (format_match) : Return a Value * rather than a
      	  double.
      
      	* src/mstyle.c (mstyle_set_font_size) : Do not allow font sizes < 1.
      
      	* src/main.c (gnumeric_main) : Do NOT create an empty workbook
      	  then delete it if things are successfully loaded.  This causes
      	  a global recalc.  Instead add a flag to disable exit when the
      	  number of workbooks go to zero.  Then only enable the flag AFTER
      	  we have attempted to load the initial workbooks.
      
      	* src/item-grid.c (item_grid_event) : Update the status_region when
      	  button-1 is release.  It should display the edit_pos.
      
      	* src/gutils.c : Move cell_name, col_name, col_from_name,
      	  parse_cell_name, parse_cell_name_or_range and parse_cell_name_list,
      	  to parse-util.c.
      
      	* src/gnumeric.h  : Add RenderedValue.
      
      	* src/gnumeric-util.c (gnumeric_char_start_expr_p) : Move
      	  to parse-util.c
      
      	* src/file.c (workbook_read) : Remove freese thaw usage.
      	  Move call to update AFTER mark clean.
      
      	* src/expr.c (eval_pos_init) : Take a cellpos.
      	(parse_pos_evalpos) : New routine.
      	(eval_pos_cellref) : There is some questionable code scattered in the
      	  functions.  This routing localizes the odd bits for correction.
      
      	* src/eval.c (cell_eval_content) : Use sheet_redraw_cell,
      	  and rendered_value_calc_size.
      	(cell_get_dependencies) : Improve constness.
      
      	* src/corba-sheet.c : Remove the freeze thaw operations.
      	(Sheet_cell_set_formula) : Deleted.
      	(Sheet_range_set_formula) : Delete.
      
      	* src/commands.c : Adjust so that registration of command auto
      	  calls redo.  Add misc checks for splitting arrays.
      
      	* src/clipboard.h : Move the CellCopy types here from cell.h
      
      	* src/clipboard.c (paste_cell) : Use cell_has_expr.
      	  Don't insert the new cell till after its contents are assigned.
      
      	* src/cellspan.c (cell_register_span) : Improve constness.
      	(cell_unregister_span) : Ditto.
      	(row_cell_get_displayed_at) : Delete.
      	(cell_calc_span) : Moved here from cell.c
      
      	* src/dialogs/dialog-stf.glade : Adjust the header background colour
      	  to match the purdy new icon.  Add the icon.
      
      	* src/cell-draw.c : Use the rendered_value routines.
      	  Improve constness.
      
      	* src/analysis-tools.c (set_cell) : Use sheet_cell_fetch.
      
      	*.*
      	    cell_set_* -> sheet_cell_set_
      	    cell_set_*_simple -> cell_set_
      	    Cell::{row,col} -> Cell::{row,col}_info
      	    cell_get_text -> cell_get_entered_text
      	    cell_get_content -> cell_get_entered_text
      	    cell_name -> cell_coord_name
      	    cell_get_formatted_val -> cell_get_rendered_text
      	    cell_get_content -> cell_get_entered_text
      
      	* src/cell.c :
      	(cell_dirty) : Renamed from cell_modified.  Use
      	  sheet_set_dirty.
      	(cell_formula_changed) : Make the queuing of the recalc optional.
      	(cell_cleanout) : Handle union of expression and entered_text,
      	  and remove the rendered value.
      	(cell_copy) : Ditto.
      	(cell_destroy) : handle cell_modified -> cell_dirty.
      	(cell_set_text) : Use parse_text_value_or_expr and store the prefered
      	  format.
      	(cell_set_text_and_value) : New routine.
      	(cell_assign_value) : New routine.
      	(cell_set_value) : Support formats.
      	(cell_set_expr_and_value) : New routine.
      	(cell_set_expr_internal) : Split from cell_set_expr.
      	(cell_set_expr) : Divide to allow for not queuing a recalc.
      	(cell_set_array_formula) : Use cell_set_expr_internal.
      	(cell_is_array) : New utility.
      	(cell_is_partial_array) : New utility.
      	(cell_has_expr) : New utility.
      	(cell_render_value) : Use rendered_value_*.
      	Move all comment routines into cell-comment.[ch].
      
      	* idl/Gnumeric.idl : Remove cell_set_formula, and range_set_formula.
      	  These were identical to set_text.  Made Workbook embeddable.
      bedb925b
  4. 10 Apr, 2000 1 commit
    • Miguel de Icaza's avatar
      Do not destroy the context here, as it is dereferenced later in the · 30aba440
      Miguel de Icaza authored
      
      
      2000-04-07  Miguel de Icaza  <miguel@gnu.org>
      
      	* main.c (button_cancel): Do not destroy the context here, as it
      	is dereferenced later in the mainloop.
      
      2000-04-10  Miguel de Icaza  <miguel@gnu.org>
      
      	* Lots of files: replaces utils.h for gutils.h
      
      	* renamed utils.h to gutils.h to avoid the compilation problem on
      	some Unices (yes, fixing the Makefile would have done it, but
      	utils.h was still a lame name;  Of course gutils.h is not any
      	better, but it is now done).
      
      2000-04-07  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/cellspan.c (span_remove): Pretify code.
      30aba440
  5. 01 Apr, 2000 1 commit
    • Jody Goldberg's avatar
      Fix the silly edit bug tha was being reported. · fce11703
      Jody Goldberg authored
      Some major work on item-edit.
      
      2000-03-31  Jody Goldberg <jgoldberg@home.com>
      
      	* src/workbook.c : Switch over to useing GNOMEUIINFO_ITEM_ where
      	  possible.
      	(cb_editline_focus_in) : Do not start editing if we are already
      	  editing.
      
      	* src/utils.c (parse_cell_name) : constness.
      
      	* src/style.c (style_font_gdk_font) : constness.
      	(style_font_gdk_font) : ditto.
      	(style_font_gnome_font) : ditto.
      	(style_font_get_height) : ditto.
      
      	* src/sheet.c (sheet_set_zoom_factor) : redimension all cells, rather
      	  than the sparse sheet region.  Do not auto-resize.
      	(sheet_cell_add) :  Adjust to new calling convention for
      	  cell_calc_dimensions.
      	(sheet_stop_editing) : Rename from sheet_destroy_edit_cursor.
      
      	* src/sheet-view.c (sheet_view_get_style_font) : constness.
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_create_editing_cursor) :
      	  No need to set all those arguments.
      	(destroy_item_editor) : Merge into gnumeric_sheet_stop_editing.
      	(gnumeric_sheet_stop_editing) : Renamed from
      	  gnumeric_sheet_destroy_editing_cursor.
      
      	* src/cell.[ch] (cell_set_rendered_text) : Adjust to new calling
      	  convention for cell_calc_dimensions.
      	(cell_calc_dimensions) : Adjust calling convetion to make auto
      	  resizing optional.
      	(calc_text_dimensions) : Adjust calling convention to directly set size.
      
      	* src/sheet-style.c (re_dimension_cells_cb) :  Adjust to new calling
      	  convention for cell_calc_dimensions.
      
      	* src/item-edit.c : Major rework to behave better at margins,
      	  correctly handle cells whose display contents span differently than
      	  their displayed values, multi-line display mechanics, and a blinking
      	  cursor :-)
      fce11703
  6. 18 Feb, 2000 1 commit
    • Jody Goldberg's avatar
      - Merge some enhancements to the color combo boxes. · 771be446
      Jody Goldberg authored
      - Simplify and enhance the cursor and selection code.
        Its not as pretty as I'd like, but its getting better.
      - Fix a display glitch in the item-bar.  canvas redraw excludes
        the far coordinate.  That will teach me to read docs.
      
      2000-02-18  Jody Goldberg <jgoldberg@home.com>
      
      	* src/widgets/widget-color-combo.c (color_combo_construct) : typo.
      	(color_combo_new) : Disable the charting colours for now.  They are
      	  mostly duplicates.
      
      2000-02-16 Dom Lachowicz <dominicl@seas.upenn.edu>
      
      	* src/widgets/widget-color-combo.[ch]
      	Changed the code some to enable tooltips
      	Minor api changes
      
      2000-02-18  Jody Goldberg <jgoldberg@home.com>
      
      	* src/workbook-view.c : Add history.h.
      
      2000-02-18  Jody Goldberg <jgoldberg@home.com>
      
      	* src/sheet.c (sheet_redraw_selection) : Delete.
      
      	* src/selection.c (sheet_selection_extend_to) : Short circuit when
      	  there would be no change to the selection.
      	(sheet_selection_change) : The sheet already has the correct edit,
      	  move, base positions.  Use them.
      
      	* src/sheet-view.c (sheet_view_redraw_headers) : gnome_canvas_request_redraw
      	  EXCLUDES the far coordinates.  Add 1 so that the last pixel get
      	  redrawn too.
      
      2000-02-18  Jody Goldberg <jgoldberg@home.com>
      
      	* src/history.c (history_menu_item_create) : typo.
      
      2000-02-18  Jody Goldberg <jgoldberg@home.com>
      
      	* src/dialogs/dialog-goal-seek.c (dialog_goal_seek) : Use edit_pos.
      	* src/dialogs/dialog-solver.c (dialog_solver) : Ditto.
      
      	* src/xml-io.c (xml_read_selection_info) : Use edit_pos.
      	(xml_write_selection_info) : Ditto.
      
      	* src/workbook.c (cb_sheet_check_dirty) : Use edit_pos.
      	(paste_cmd) : Ditto.
      	(paste_special_cmd) : Ditto.
      	(insert_current_date_cmd) : Ditto.
      	(insert_current_time_cmd) : Ditto.
      	(workbook_edit_comment) : Ditto.
      
      	* src/sheet.c (sheet_new) : sheet_selection_append -> sheet_selection_add.
      	(sheet_accept_pending_input) : Use edit_pos.
      	(sheet_load_cell_val) : Ditto.
      	(sheet_start_editing_at_cursor) : Ditto.
      	(sheet_update_controls) : Ditto.
      	(sheet_{col,row}_selection_type) : Fix cut-paste-o.
      	(walk_boundaries) : Move to selection.c.
      	(walk_boundaries_wrapped) : Ditto.
      	(sheet_selection_walk_step) : Reworked and moved to selection.c.
      	(sheet_cursor_move) : Switch to new framework.
      	(sheet_cursor_set) : Ditto.
      	(sheet_set_selection) : Delete.
      
      	* src/sheet.h : (SheetSlection) : Remove base member.
      	(Sheet) : adjsut notion of cursor to differentiate between,
      	edit, base, and movement.  (see comments).
      	* src/sheet-view.c (sheet_view_set_zoom_factor) : Use edit_pos.
      	(sheet_view_scrollbar_config) : Switch to new scheme.
      	(sheet_view_{col,row}_selection_changed) : Make the Top/Left visible
      	  cell the edit cursor when things are out of range.
      
      	* src/sheet-style.c (sheet_style_attach) : Use sheet_redraw_range directly.
      	(sheet_range_apply_style) : Ditto.
      	(sheet_range_set_border) : Ditto.
      
      	* src/selection.c (sheet_selection_add_range) : Renamed from,
      	  sheet_selection_append.  Document.  Switch to new edit, base, move
      	  scheme.  Directly call sheet_cursor_set rather than the confusingly
      	  named sheet_set_selection.
      	(sheet_selection_add) : Renamed from sheet_selection_append.
      	(sheet_selection_change) : Adjsut parm name from 'new' -> 'new_sel' to
      	  enable test compiles from C++.
      	(sheet_selection_extend_to) : Switch to new edit, base, move scheme.
      	(sheet_selection_extend) : Just call sheet_selection_extend_to for the
      	  main work.  Document.
      	(sheet_select_all) : sheet_selection_append_range -> sheet_selection_add_range.
      	(sheet_selection_extend_{horizontal, vertical} : Merge in to
      	  sheet_seletion_extend and fix.
      	(sheet_selection_set) : Switch to the new scheme.
      	(sheet_selection_reset) : sheet_selection_append -> sheet_selection_add.
      	  Use edit_pos.
      	(walk_boundaries) : Moved from sheet.c, merged with
      	  walk_boundaries_wrap, and change signature.
      	(sheet_selection_walk_step) : Moved from sheet.c and switched to the
      	  new method.  Do not change the selected region while iterating.
      
      	* src/item-grid.c (item_grid_paint_empty_cell) : Use edit_pos.
      	(item_grid_draw_cell) : Ditto.
      	(item_grid_event) : Ditto.
      	(context_paste_cmd) : Use the base and move cursors.
      	(context_paste_special_cmd) : Ditto.
      	(item_grid_button_1) : sheet_selection_append -> sheet_selection_add.
      
      	* src/item-cursor.c (item_cursor_autofill_event) : Use
      	  sheet_selection_add_range rather than the two step select extend.
      
      	* src/clipboard.c (sheet_paste_selection) : Use
      	  sheet_selection_add_range rather than the 2 step process
      	  of setting the corner and extending.
      
      	* plugins/excel/ms-excel-read.c (ms_excel_read_selection) :
      	    sheet_selection_append_range -> sheet_selection_add_range
      	* src/corba-sheet.c (Sheet_selection_append) : Ditto.
      	(Sheet_selection_append_range) : Ditto.
      
      	* src/gnumeric-sheet.c (move_cursor) : Ditto.
      	(gnumeric_sheet_key_mode_sheet) : Ditto.  Use edit_pos.
                sheet_selection_walk_step now handles the cursor and selection
      	  changes.
      	(gnumeric_sheet_set_selection) : Delete this was unnecessary.
      	(gnumeric_sheet_set_cursor_bounds) : Add preconditions.
      	(move_cursor_horizontal) : Use the edit_pos for movement.
      	(move_cursor_vertical) : Ditto.
      	(gnumeric_sheet_create_editing_cursor) : Ditto.
      	(start_cell_selection) : Ditto.
      	(move_horizontal_selection) : Use sheet_selection_extend.
      	(move_vertical_selection) : Ditto.
      	(gnumeric_sheet_compute_visible_ranges) : Force a redraw of the
      	  item-cursor when the visible region changes.  FIXME : This should be
      	  an update not a redraw.
      771be446
  7. 14 Feb, 2000 2 commits
    • Jody Goldberg's avatar
      Adjsut XL import of row height to include margins. Heights · 58f4dd19
      Jody Goldberg authored
      should match exactly now.
      
      2000-02-14  Jody Goldberg <jgoldberg@home.com>
      
      	* src/format.c (format_value) : Empty formats produce empty cells.
      
      	* src/workbook.c (workbook_menu_tools) : Move the plugins menu item to
      	  the Tools menu.
      58f4dd19
    • Jody Goldberg's avatar
      A few more pts vs pixels cleanups and fixes. · fbf52c42
      Jody Goldberg authored
      2000-02-14  Jody Goldberg <jgoldberg@home.com>
      
      	* src/item-bar.c (item_bar_event) : Handle rename from
      	  sheet_{col,row}_size_fit -> sheet_{col,row}_size_fit_pixels
      	* src/selection.c (cb_set_row_height) : Ditto.
      	* src/workbook-cmd-format.c
      	(workbook_cmd_format_{column,row}_auto_fit) : Ditto.
      
      	* src/cell.c (cell_calc_dimensions) : Use sheet_row_set_size_pixels
      	  rather than sheet_row_set_internal_size_pts.
      
      	* src/sheet.c (sheet_{col,row}_set_size_{pixels,pts}) :
      	  Use sheet_row_fetch to avoid manually adding rows/col.
      	  Syncronize implementations and move the 'set_internal' code
      	  here.
      	(sheet_{col,row}_set_internal_size_pts) : Delete.
      	(sheet_{col,row}_size_fit) : Rename sheet_{col,row}_size_fit_pixels
      	(colrow_compute_pts_from_pixels) : Typo.
      fbf52c42
  8. 13 Feb, 2000 1 commit
    • Jody Goldberg's avatar
      Major rationalization of pts vs pixels and the use of margins. · b6d04cff
      Jody Goldberg authored
      Some redraw speedups and the addition of XL2000 style alpha bended selections.
      
      2000-02-13  Jody Goldberg <jgoldberg@home.com>
      
      	* ./src/sheet-view.c (sheet_view_redraw_cell_region) : redraw the
      	  bounding grid lines too.
      
      	* src/item-cursor.c (item_cursor_get_pixel_coords) : Clip the cursor
      	  region to the visible range.  The layout still needs cleaning to
      	  match the 'correct' way of implementing canvas-items, but this
      	  heuristic saves us lots of iterations through the accumulator for
      	  the size of the entire sheet.
      
      2000-02-12  Jody Goldberg <jgoldberg@home.com>
      
      	* src/gnumeric-sheet.c : Use visible flag and adjust to naming and
      	  margin changes.
      
      	* src/item-bar.c (colrow_tip_setlabel) : Use the format provided by
      	  XL2000.  Things are correct for rows, colwidth are quoted in pts
      	  rather than char widths.
      	(get_col_from_pos) : Use visible flag.
      	(item_bar_start_resize) : Function renaming.
      	(is_pointer_on_division) : Ditto.
      	(item_bar_draw) : Changes to margins.
      
      	* src/item-edit.c : Function renaming.
      	* src/item-cursor.c : Ditto.  decrease spacing for auto handle.
      
      	* src/item-grid.c (item_grid_draw) : Remove inversion process for the
      	  selection.  Instead have the cells draw their background
      	  differently.  Use the visible flag.
      	(item_grid_paint_empty_cell) : Ditto.
      	(item_grid_paint_cell) : Ditto.
      
      	* src/mstyle.c (mstyle_new_default) : The default vert alignment is BOTTOM.
      
      	* src/pattern.c (gnumeric_background_set_gc) : Draw the background of
      	  a selected cell differently.
      
      	* src/print-cell.c (DIM) : margins are already included.
      	(print_cell_text) : Adjust argument order to more closely match
      	  cell_draw.  Add support for vertical alignment of 1 line cells.
      	  Invert control of single vs multiple lines.
      	(print_cell) : Adjust to changes in the arguments.
      	(print_cell_range) : Use the visible flag.
      	  Draw line at the boundary rather than pretending there were
      	  additional rows/cols.
      
      	* src/print.c (compute_groups) : size_pts INCLUDES margins.  Use 'visible' flag.
      	(print_page) : Adjust to function renaming.
      	(print_range_used_units) : Ditto.
      
      	* src/selection.c : Include sheet-view directly for now.
      	(cb_set_row_height) : Adjust to function renaming.
      
      	* src/sheet-view.c (sheet_view_redraw_cell_region) : Adjust to function
      	  renaming.
      	(sheet_view_redraw_headers) : Ditto.
      	(sheet_view_set_zoom_factor) : Ditto.
      	(sheet_view_col_size_changed) : Ditto.
      	(sheet_view_row_size_changed) : Ditto.
      	(sheet_view_comment_get_points) : Ditto.
      
      	* src/sheet.[ch] : Rationalize function names, and add glossary.
      	Make the use of margins and sizes (in points and pixels) consistant.
      
      	(sheet_col_get_external_width : Delete.
      	(sheet_row_get_external_height : Delete.
      	(sheet_col_get_distance : Rename sheet_col_get_distance_pixels.
      	(sheet_row_get_distance : Rename sheet_row_get_distance_pixels.
      	(sheet_row_get_unit_distance : Rename sheet_row_get_distance_pts.
      	(sheet_col_get_unit_distance : Rename sheet_col_get_distance_pts.
      	(sheet_col_set_width : Rename sheet_col_set_size_pixels.
      	(sheet_col_set_width_units : Rename sheet_col_set_size_pts.
      	(sheet_row_set_height : Rename sheet_row_set_size_pixels.
      	(sheet_row_set_height_units) : Rename sheet_row_set_size_pts.
      	(sheet_get_default_external_col_width) : Rename sheet_col_get_default_size_pts.
      	(sheet_get_default_external_row_height): Rename sheet_row_get_default_size_pts.
      	(sheet_col_set_internal_width) : sheet_col_set_internal_size_pts.
      	(sheet_row_set_internal_height): sheet_row_set_internal_size_pts.
      	(sheet_{row,col}_set_default_size_pts) : New functions.
      
      	(sheet_init_default_styles) : Tune to match XL defaults.
      
      	* src/sort.c : Use g_strcasecmp, and include <stdlib.h>
      
      	* src/style.c (style_color_new) : Init the selection colour as a 50%
      	  alpha blend with lavender.
      
      	* src/style.h : Change default font to be Helvetica 9 because it will
      	  scale better when the standard 96 dpi resolution is assumed.
      	  Add a selected_color to StyleColor.
      
      	* src/value-sheet.c : Include <gnome.h> to get the
      	  internationalization support.
      
      	* src/workbook-cmd-format.c (workbook_cmd_format_column_auto_fit) :
      	  sheet_col_set_width -> sheet_col_set_size_pixels.
      	(workbook_cmd_format_column_width) :
      	  sheet_col_set_width_units -> sheet_col_set_size_pts.
      	(workbook_cmd_format_row_auto_fit) :
                sheet_row_set_height -> sheet_row_set_size_pixels
      	(workbook_cmd_format_row_height) :
      	  sheet_row_set_height_units -> sheet_row_set_size_pts.
      
      	* src/xml-io.c (xml_read_rows_info) : Rename
      	  sheet_row_set_height_units -> sheet_row_set_size_pts.
      	(xml_read_cols_info) : Rename
      	  sheet_col_set_height_units -> sheet_col_set_size_pts.
      	(xml_read_colrow_info) : Remove hack with negative pixels.
      	  Use 'visible' flag instead.
      	(xml_write_colrow_info) : Ditto.
      b6d04cff
  9. 10 Feb, 2000 1 commit
    • Jody Goldberg's avatar
      Remove inclusion of cell.h. Adjust includes to loosen things a bit more. · f6b62c13
      Jody Goldberg authored
      
      2000-02-10  Jody Goldberg <jgoldberg@home.com>
      
      	* src/sheet.h : Remove inclusion of cell.h.  Adjust includes to loosen
      	  things a bit more.
      
      	* src/colrow.h : Remove margin_a_pt margin_b_pt.  Margins are NOT
      	  scaled by resolution or zoom.
      	  Rename units -> size_pts and store as float rather than double.
      	  Rename pixels-> size_pixels
      	  hard_size -> use gboolean rather than a 1 element bitfield
      
      	* src/style.h : Move the typedefs from here.
      	* src/gnumeric.h : to here.
      
      	*.[ch] : Catch up with the renames and include changes.
      f6b62c13
  10. 04 Feb, 2000 2 commits
    • Jody Goldberg's avatar
      - Fix some of the problems with the resolution scaling. · 3e12961e
      Jody Goldberg authored
      - Implement an initial version of paste_cut undo.
      
      2000-02-05  Jody Goldberg <jgoldberg@home.com>
      
      	* src/sheet.[ch] (sheet_row_info_set_{height, width}) : Make static.
      
      	* src/cell.c (cell_calc_dimensions) : The size is already scaled.
      
      	* src/item-bar.c (item_bar_event) : Only scale by the zoom.
      	  The item-grid canvas is zoomed by the zoom factor, not by the
      	  resolution adjustment.
      	(item_bar_start_resize) : Ditto.
      
      	* src/selection.c (sheet_selection_paste) : Use cmd_paste_cut.
      
      	* src/commands.c (cmd_paste_cut) : Implement.
      
      2000-02-04  Jody Goldberg <jgoldberg@home.com>
      
      	* src/widgets/widget-font-selector.c (font_selector_set_points) : new
      	  function.
      	* src/dialogs/dialog-cell-format.c (fmt_dialog_init_font_page) : Use it.
      3e12961e
    • Jody Goldberg's avatar
      Add some config variables to the application to allow for axis dependent · d6fe542a
      Jody Goldberg authored
      zooming based on the screen display resolution (eg 110 dpi).  No GUI currently
      available.
      
      2000-02-04  Jody Goldberg <jgoldberg@home.com>
      
      	* src/widgets/widget-font-selector.c (font_selector_set_points) : new
      	  function.
      	* src/dialogs/dialog-cell-format.c (fmt_dialog_init_font_page) : Use it.
      
      2000-02-04  Jody Goldberg <jgoldberg@home.com>
      
      	* src/sheet.c (sheet_col_set_internal_width) : Scale by the axis
      	  resolution adjment.
      	(sheet_row_set_internal_height) : Ditto.
      	(colrow_set_units) : Ditto.
      	(sheet_compute_col_row_new_size) : Ditto.
      
      	* src/item-bar.c (item_bar_fonts_init) : Scale by resolution.
      	(item_bar_start_resize) : Ditto.
      	(item_bar_event) : Ditto.
      
      	* src/cell.c (cell_calc_dimensions) : Adjust interface to take the
      	  cell. Scale the height test by the vertical resolution adjustment.
      
      	* src/cell-draw.c (sheet_view_get_style_font) : rename from
      	  sheet_get_style_font in preparation for view split.  Scale
      	  the font by the average of the resolutions.
      d6fe542a
  11. 01 Feb, 2000 1 commit
  12. 31 Jan, 2000 1 commit
    • Jody Goldberg's avatar
      Move more of the pure view elements into WorkbookPrivate. · a038ab94
      Jody Goldberg authored
      
      2000-01-31  Jody Goldberg <jgoldberg@home.com>
      
      	* src/worksheet.h : Move more of the pure view elements into
      	  WorkbookPrivate.
      
      	* src/sheet.h : Remove include of workbook.h
      
      	* *.c : manually include workbook.h only where we need it.
      
      	* src/ranges.c (parse_range) : Move here from dialog-analysis-tools.c
      	  to avoid warnings.
      
      	* src/corba-workbook.c (Workbook_save_to) : Adjust to new calling
      	  convention.
      	* src/corba-workbook-factory.c (WorkbookFactory_read) : Ditto.
      
      	* src/parser.y : Support interbook references.
      
      	* src/item-bar.c : Ignore scroll-wheel events. Eventually the app will
      	  handle these rather than the grid.
      a038ab94
  13. 25 Jan, 2000 1 commit
    • Jody Goldberg's avatar
      - Fix a problem with zooming caused by the new item-bar enhancements. - · 03198e1d
      Jody Goldberg authored
      
      - Fix a problem with zooming caused by the new item-bar enhancements.
      - Remove gnumeric-sheet.h from a number of places that it had no reason to be.
      - Move all of the row/col pos/offset cache into GnumericSheet.  WARNING
        I do not populate all of it yet.
      
      2000-01-26  Jody Goldberg <jgoldberg@home.com>
      
      	* src/sheet-view.c (sheet_view_set_zoom_factor) : Keep the cursor in
      	  the same place and recompute the alignments for everything.
      
      	* src/item-cursor.c (item_cursor_set_bounds) : New function.
      
      	* src/gnumeric-sheet.h : Add more orthogonal structure for caching
      	  common row/col bounds and their canvas offsets.
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_create) : Init the new members.
      	(gnumeric_sheet_filenames_dropped) : Keep the canvas private.
      	(gnumeric_sheet_make_cell_visible) : Add 'force_scroll' argument.
      
      	* src/clipboard.c (clipboard_release) : It is possible to have no
      	  styles associated with a region.
      
      	* src/item-grid.c : Remove overlapping cache of bounding rows/cols and
      	  offsets.  Use the superset in GnumericSheet.
      	 (item_grid_find_{row, col}) : Support sliding backwards.
      03198e1d
  14. 23 Jan, 2000 1 commit
    • Jody Goldberg's avatar
      Improve itembar redraw. · b8823fde
      Jody Goldberg authored
      2000-01-22  Jody Goldberg <jgoldberg@home.com>
      
      	* src/sheet-view.c (sheet_view_redraw_headers) : New function that
      	  will redraw a subset of an itembar.
      	(sheet_view_redraw_columns) : Delete.
      	(sheet_view_redraw_rows) : Delete.
      
      	* src/sheet.c (sheet_redraw_headers) : Call sheet_view_redraw_headers.
      	(sheet_redraw_columns) : Delete.
      	(sheet_redraw_rows) : Delete.
      
      	* src/gnumeric-sheet.h (GnumericSheet) : Remove unused member item_bar_col.
      
      	* src/colrow.c (col_row_set_visiblity) : Use sheet_redraw_headers
      	  in place of sheet_redraw_{cols,row}.
      	* src/selection.c (sheet_selection_append_range) : Ditto.
      	(sheet_select_all) : Ditto.
      	(sheet_selection_reset_only) : Ditto.  Clear the selection internally.
      
      	* src/sheet.c (sheet_{col,row}_get_distance) : Handle from > to.
      
      	* src/item-cursor.c (item_cursor_get_pixel_coords) : Use the
      	  precalculated offsets.
      	* src/item-edit.c (item_edit_get_pixel_coords) : Ditto.
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_bar_set_top_row) : Update the
      	  item_grid's notion of the top.  Calculate the new distance using the
      	  previous top as the start point.
      	(gnumeric_sheet_bar_set_left_col) : Rename from top_col.  Ditto.
      
      2000-01-21  Jody Goldberg <jgoldberg@home.com>
      
      	* src/item-bar.c (item_bar_draw) : Remove minor drawing glitch when
      	  drawing at the edge of the sheet.
      	(item_bar_class_init) : Remove the unsed 'First' argument.
      
      	* src/item-grid.c (item_grid_draw) : Draw gridlines even at the
      	  outer edges.
      b8823fde
  15. 18 Jan, 2000 1 commit
    • Jody Goldberg's avatar
      - gnome-xml is is CVS now. Prepare for release and require it. · 943bf40e
      Jody Goldberg authored
      - Row/Col hiding.
      
      2000-01-18  Jody Goldberg <jgoldberg@home.com>
      
      	* src/xml-io.c (xml_write_colrow_info) : Save whether or not a row/col
      	  is hidden.
      	(xml_read_colrow_info) : Restore the hidden-ness.
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_compute_visible_ranges) :
      	  Col/Row pixel width < 0 indicates the row is hidden.
      	(gnumeric_sheet_make_cell_visible) : Ditto.
      	(colrow_set_units) : Ditto.
      	(sheet_{row,col}_info_set_{height,width}) : Ditto.
      	(sheet_{row,col}_set_internal_{height,width}) : Ditto.
      	(sheet_{row,col}_get_distance) : Ditto.
      	(sheet_{row,col}_get_unit_distance) : Ditto.
      	(sheet_{row,col}_is_hidden) : Utility routines.
      	(sheet_find_boundary_{vertical,horizontal}) : Skip hidden rows/cols.
      	(sheet_row_col_visible) : Mark a contiguous set of rows/cols as
      	  visible or hidden.
      
      	* src/sheet.c (sheet_compute_col_row_new_size) : Ditto.
      
      	* src/item-bar.c (item_bar_draw) : Ditto.
      	(is_pointer_on_division) : Ditto.
      	(get_col_from_pos) : Ditto.
      
      	* src/item-grid.c (item_grid_find_{col,row}) : Ditto.
      	(item_grid_draw) : Skip cells in hidden rows cols.
      	(item_grid_paint_empty_cell) : Ditto, just in case.
      	(item_grid_draw_cell) : Ditto.
      	(context_{col,row}_{hide,unhide}) : New functions.
      	(item_grid_context_menu) : Add new menu items.
      
      	* src/selection.c (selection_row_col_visible) : New function.
      	cb_row_col_visibility : Utility function.
      
      	* src/workbook-cmd-format.c
      	(workbook_cmd_format_{column,row}_{hide,unhide}) : New functions.
      	(workbook_cmd_format_column_std_width) : Stub.
      	(workbook_cmd_format_row_std_height) : Stub.
      
      	* src/workbook.c : Add hide/unhide to the row/col format menus.
      
      2000-01-18  Jody Goldberg <jgoldberg@home.com>
      
      	* configure.in : Add test for gnome-xml >= 1.8.5. This is
      	  required to support the problems with versions 1.8.[234].
      	* gnumeric.spec.in : Ditto.
      943bf40e
  16. 05 Jan, 2000 1 commit
    • Jody Goldberg's avatar
      Initial version of undo. · 7667d632
      Jody Goldberg authored
      2000-01-04  Jody Goldberg <jgoldberg@home.com>
      
      	* src/commands.[ch] : New files.
      
      	* src/workbook-view.c (workbook_view_set_undo_redo_state) : Take
      	  strings to use as suffixes to undo and redo.  NULL indicates
      	  disabled.
      
      	* src/sheet.c (sheet_set_current_value) : Use cmd_set_text to register
      	  undo.
      
      	* src/workbook.c (workbook_menu_view) : Make The formula toggle a
      	  toggle item.
      	(workbook_menu_insert) : Move the insert object menu item here,
      	  and adjust the selector characters to make more sense.
      	(undo_cmd, redo_cmd) : Enable.
      
      	(workbook_init) : Init the undo/redo lists.
      	(workbook_do_destroy) : Clear the undo/redo lists.
      	(wb_input_finished) : Delete.  It was the same as accept_input.
      7667d632
  17. 20 Dec, 1999 1 commit
    • Jody Goldberg's avatar
      Quick fix for workbooks exiting (and leaking a bit) when an import · d4430e2f
      Jody Goldberg authored
      failed.
      
      1999-12-20  Jody Goldberg <jgoldberg@home.com>
      
      	* src/workbook.c (file_open_cmd) : Handle failed opens.
      	(file_import_cmd) : Handle failed imports.
      
      	* src/item-bar.c (item_bar_start_resize) : Add resize marker on the
      	  other side of the row/col being resized.
      	(item_bar_init) : Init the marker to NULL.
      	(item_bar_end_resize) : Clear the marker.
      d4430e2f
  18. 18 Dec, 1999 2 commits
    • Jody Goldberg's avatar
      Bug 3289 · 5769426d
      Jody Goldberg authored
      1999-12-19  Jody Goldberg <jgoldberg@home.com>
      
      	* src/selection.c (sheet_selection_cut) : Fix Typo.
      
      	* src/item-bar.c (item_bar_start_resize) : Don't bother setting the
      	  location of the line here.  Instead we set the correctly zoomed
      	  bounds of the static-dimension.
      	(item_bar_end_resize) : Clear the saved points.
      	(item_bar_init) : Init the guide and points to NULL;
      	(item_bar_event) : No need to call canvas to world.  We zoom manually.
      	(item_bar_get_line_points) : Delete.
      5769426d
    • Morten Welinder's avatar
      Unref fonts. (Found by Miguel.) · bc703438
      Morten Welinder authored
      1999-12-18  Morten Welinder  <terra@diku.dk>
      
      	* src/item-bar.c (item_bar_destroy): Unref fonts.  (Found by
       	Miguel.)
      
      	* src/style.c (style_shutdown): Add code to warn of font ref leaks
       	on exit.
      bc703438
  19. 19 Nov, 1999 1 commit
  20. 15 Nov, 1999 2 commits
  21. 13 Nov, 1999 1 commit
  22. 09 Nov, 1999 2 commits
  23. 01 Nov, 1999 1 commit
    • Miguel de Icaza's avatar
      Optimize. (is_pointer_on_division): Bug fix for boundary condition. · 5fbd1563
      Miguel de Icaza authored
      1999-11-01  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/item-bar.c (item_bar_draw): Optimize.
      	(is_pointer_on_division): Bug fix for boundary condition.
      	(get_col_from_pos): ditto.
      
      1999-10-30  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/print-preview.c (preview_canvas_event): Reversed the delta
      	computation, to make the scrolling follow what federico
      	suggested.
      
      	* src/workbook-format-toolbar.c: Change the money format to
      	include decimals.
      
      1999-10-29  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/xml-io.c (xml_init): Rename.
      
      1999-10-25  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/complex.h (GNUMERIC_COMPLEX_PROTO): Fix from Tom Mooney to
      	get the compile settings done correctly.
      5fbd1563
  24. 26 Oct, 1999 1 commit
  25. 10 Oct, 1999 1 commit
  26. 09 Oct, 1999 2 commits
  27. 08 Oct, 1999 1 commit
    • Jody Goldberg's avatar
      - Move some math functions from utils to mathfuncs. · 42b5114f
      Jody Goldberg authored
      - Beautify the scrollbar tooltips a bit and move some of their utility
        routines into gnumeric-utility.
      - Add width/height tooltips on col/row resize.
      - Fix bug that would loose the end of resize event when the cursor had
        not moved.
      42b5114f
  28. 06 Oct, 1999 1 commit
  29. 17 Sep, 1999 1 commit
    • Miguel de Icaza's avatar
      New file. Moved a bunch of commands here, and move to be moved. · dd6fabaa
      Miguel de Icaza authored
      1999-09-17  Miguel de Icaza  <miguel@gnu.org>
      
      	* 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  <miguel@gnu.org>
      
      	* 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/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.
      dd6fabaa
  30. 08 Sep, 1999 1 commit
  31. 06 Sep, 1999 1 commit
    • Miguel de Icaza's avatar
      Add an event handler for the preview canvas. (zoom_state): new routine, · d242fb80
      Miguel de Icaza authored
      1999-09-05  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/print-preview.c (preview_canvas_event): Add an event handler
      	for the preview 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):
      
      1999-09-04  Jody Goldberg <jgoldberg@home.com>
      d242fb80
  32. 02 Aug, 1999 1 commit
  33. 21 Jul, 1999 1 commit
    • Miguel de Icaza's avatar
      Move the dimension computaiton of the font after we have figured which · 863b33b2
      Miguel de Icaza authored
      1999-07-20  Miguel de Icaza  <miguel@gnu.org>
      
      	* 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.
      863b33b2
  34. 11 Jul, 1999 1 commit
    • Jody Goldberg's avatar
      - Disable insert/delete row/column that would split an array-formula · a3506bf7
      Jody Goldberg authored
      - Enable cut/copy/paste for array formulas.
      - Fix multi-line cell drawing & whitespace issues.
      - Change the default column width & grid colour to more closely match XL
      - Add the edit popup menu in the row/col headers
      - Short circuit the insert/delete dialogs to directly insert/delete when
        an entire row/column is selected.
      a3506bf7