1. 26 Jun, 1999 1 commit
    • Miguel de Icaza's avatar
      The big GNUMERIC_PRINT merge into HEAD. · a5e65a30
      Miguel de Icaza authored
      
      
      The big GNUMERIC_PRINT merge into HEAD.
      
      Still some features are missing.  Check the TODO to see what is
      missing.
      
      1999-06-26  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/pixmaps.h: Removed unused pixmaps.
      
      	* src/corba-sheet.c (Sheet_corba_class_init): Fill in some missing
      	values fomr the GNOME::Gnumeric::Sheet epv interface.
      
      	* src/expr.c (eval_funcall): Removed unused variable.
      
      	* src/workbook.c (workbook_sheets): prepend and reverse instead of
      	appending all the time.  It is more efficient.
      
      	* src/style.c (x11_font_compute_hints): Renamed as well.  Might be
      	useful in the future.
      
      	* src/gnumeric-util.c (x11_font_get_italic_name,
      	x11_font_get_bold_name, x11_font_change_component): Renamed these
      	functions to reflect their actual usage.
      
      	* src/expr.c (expr_tree_new_constant): Change style to use early
      	return to keep indentation of the rest of the code at tab-1.  This
      	is a trick to keep indentation nice with 8-tab spaces.  Liberal
      	use of early returns, early continues, early breaks.
      
      	* src/cell.h (CELL_TEXT_GET): Kill unused macro.
      
      1999-06-25  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/xml-io.c (xml_read_cell): Merge the style we just read with
      	the existing information from the cell (which are the defaults).
      	This is only for compatibility with the old format
      
      1999-06-24  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/xml-io.c (style_font_new_from_x11): Implemented
      
      	* src/style.c (style_font_new): Improved matching of the font.
      
      	* src/xml-io.c 	(xml_write_style): Save Bold and Italic
      	properties.  Save Units as double.
      	(xml_read_style): Add conversion hook from old format.
      	(xml_read_style): Load properly italic and bold properties.
      
      	(xml_read_cell): Add new style reading code.  It is
      	compatible with the old Style reading code.
      	(xml_read_rows_info, xml_read_cols_info, xml_read_styles): Moved
      	Cols, Rows and Styles loading code here, for code clarity.
      
      	* src/style.c (style_font_new_simple): Include the scale in the
      	key lookup variable.
      
      	* src/xml-io.c: The FontDefs and the HREFs to the fonts were never
      	being used.  The new code for styles simplifies this.  Kill all
      	the references to the FontDefs urls and the font indeces.
      
      	* src/xml-io.c
      
      1999-06-23  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/xml-io.c: Major updates.
      	(xml_read_colrow_info): Use floating point for loading the
      	units, margin_a and margin_b.
      	(xml_write_colrow_info): Save units, margin_a and margin_b using
      	floating point.
      	(xml_set_value_double): Activate this function.
      	(xml_write_cell): Do not save the style here.  Lookup the style
      	id, and write a record with the style id link.
      	(xml_sheet_write): Add call to xml_cell_styles_init and
      	xml_cell_styles_shutdown to init and shutdown the cell styles in a
      	per-sheet basis.
      
      	Renamed functions to suit the gnumeric coding
      	sytle.  Fixed indentation.
      
      	File format now saves a different version.  We store all cell
      	styles first, and then we reference them.
      
      	(parse_xml_context_t): renamed from
      	parseXmlContext.  Add style_table hash table for storing all the
      	styles used by the cells on a workbook.  Used to dump Styles first
      	and then have the cells reference it.
      
      	* src/style.c (style_hash, style_compare): New routines to
      	put Styles on hash tables.
      
      	* src/workbook.c (workbook_sheets): Use g_list_prepend instead of
      	g_list_append and reverse the result.
      
      1999-06-14  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/cell.h: Killed ColType and RowType definitions.  They do not
      	save any noticeable amount of memory; we are not using them but
      	on the most useless places and finally they are the current limit
      	to our spreadsheet size.
      
      	* src/gnumeric-sheet.h: Use int instead of ColType, RowType
      	* src/item-cursor.h: Use int instead of ColType, RowType
      	* src/item-grid.h: Use int instead of ColType, RowType
      
      	* src/print-cell.c (CELL_DIM): Use _pt variants of the margins here.
      	(print_cell_text): and here.
      	(print_cell): and here.
      	(print_cell_range): and here.
      	(print_cell_grid): and here.
      
      1999-06-13  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/sheet.c (sheet_compute_col_row_new_size): Update margin_a
      	and margin_b from the points.
      	(col_row_info_init): New function to initialize a sample
      	ColRowInfo.  Inits the _pt fields.
      	(col_row_unit_distance): Use the new fields in computation.
      	(sheet_col_get_unit_distance): Use new fields in computation.
      
      	* src/dialog-printer-setup.c (do_setup_margin): Set scroll region.
      	(preview_page_create): Implement routine that draws the page for
      	the margin setup.
      
      	* src/sheet.h (ColRowInfo): Units are now doubles; margin_a_pt and
      	margin_b_pt are doubles that represent the a and b margins in
      	points.
      
      	* src/sheet.c (sheet_compute_col_row_new_size): Use the
      
      1999-06-11  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/cell-draw.c (cell_draw): Move the foreground setting routine
      	here and handle single-line and multiline coloring properly.
      
      	* src/print-info.c (unit_name_to_unit): New routine, returns the
      	UniName from the string name.
      
      	* src/dialog-printer-setup.c (dialog_printer_setup): Use
      	print_info_save and kill the do_save_settings routine for the
      	cleaner print_info routine.
      
      	* src/print-info.c (print_info_new): Now loads the default
      	settings from the saved configuration.
      	(print_info_save): Saves the print information to the gnome_config.
      
      1999-06-08  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/utils.c (str_trim_spaces): Moved str_trim_spaces ere.
      
      	* src/dialog-printer-setup.c (do_setup_main_dialog): Connect print
      	buttons.
      
      	* src/print-cell.c (print_cell_grid): Simplify routine.
      
      	* src/sheet.c (sheet_row_get_unit_distance,
      	sheet_col_get_unit_distance): Include  margins in computation.
      	This is broken, as the margins are now pixels, and they should be
      	made points.
      
      	* src/dialog-printer-setup.c (do_fetch_page_info): Fetch other values.
      	(do_save_settings): Saves the configuration.
      
      	* src/print-cell.c (print_border): Implement border drawing.
      	(print_cell_grid): Make this work as it should.
      
      	* src/print.c (compute_groups): Handle the case where the contents
      	fit entirely in one page.
      
      1999-06-07  Miguel de Icaza  <miguel@gnu.org>
      
      	* src/print.c: New file.  Implements high-level printing.
      
      	* src/dialog-printer-setup.c: New file.  Implements the "Print
      	Setup" dialog box.
      
      1999-04-30  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/cell-draw.c: New file.  All of the cell screen drawing code
      	has been moved here now.
      
      	* src/print-cell.c: Enhanced code.
      
      	* src/workbook.c: hardcoded page size for testing purposes.
      
      1999-03-10  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	I do not like the current approach.  I do think that StyleFonts
      	should be static with regard to Zoom.
      
      	And we would keep a cache of X fonts that are used for a
      	particular size.
      
      	* src/style.c (style_font_new_from): New routine that creates a
      	new font.
      
      	* src/sheet.c (sheet_set_zoom_factor): Scale fonts used in the
      	Sheet.
      
      1999-02-15  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/dialog-printer-setup.c: New file.  Implements the workbook
      	page configuration dialog box.
      
      	* src/print-info.c, src/print-info.h: Manages the per-worbook
      	print options.
      
      1999-02-07  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/style.c (font_equal): Adapt function to the new StyleFont.
      	(style_font_new, style_font_new_simple): Adapt for the upcoming
      	gnome-print support.
      	(font_init): Adapt.
      
      	* src/xml-io.c: Use Gnome Print font scheme.
      	* src/workbook.c: ditto.
      	* src/cell.c: ditto.
      	* src/item-bar.c, src/item-edit.c: ditto
      
      	* src/dialog-cell-format.c: Disable font selector for now.
      a5e65a30
  2. 21 Jun, 1999 1 commit
  3. 12 Jun, 1999 1 commit
  4. 10 Jun, 1999 1 commit
  5. 03 Jun, 1999 1 commit
  6. 26 May, 1999 1 commit
  7. 25 May, 1999 1 commit
  8. 22 May, 1999 1 commit
  9. 17 May, 1999 1 commit
    • Miguel de Icaza's avatar
      Return false if the cell name is outside the boundaries of the · 536fa980
      Miguel de Icaza authored
      1999-05-17  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/utils.c (parse_cell_name): Return false if the cell name is
      	outside the boundaries of the spreadsheet.
      
      	* src/corba-sheet.c (Sheet_range_set_text): Implement.
      	(Sheet_range_set_formula): Implement.
      	(Sheet_range_set_format): Implement.
      
      	* src/ranges.c (range_parse, range_list_parse, range_list_destroy,
      	range_list_foreach_full, range_list_foreach_all,
      	range_list_foreach, range_set_style): New functions.  Used by the
      	corba-sheet code.
      
      	* src/corba-sheet.c (Sheet_range_get_values): Implement
      	vector-based result return.
      
      	* src/xml-io.c (xmlSetGnomeCanvasPoints): use g_malloc instead of alloc.
      
      	* src/dialog-solver.c (constr_add_click): Use g_malloc instead of
      	alloc.  Use g_new instead of malloc.
      
      	* src/utils.c (parse_cell_name_list): Add parameter checking.  Use Migueestyle.
      536fa980
  10. 04 May, 1999 1 commit
  11. 30 Apr, 1999 1 commit
  12. 24 Apr, 1999 1 commit
  13. 08 Apr, 1999 1 commit
    • Jukka-Pekka Iivonen's avatar
      Wrote dialogs for these tools. The tools are not implemented yet. · 0e81c949
      Jukka-Pekka Iivonen authored
      
      
      1999-04-08  Jukka-Pekka Iivonen  <iivonen@iki.fi>
      
      	* src/dialog-solver.c, src/dialog-goal-seek.c, src/solver.h:
      	Wrote dialogs for these tools. The tools are not implemented yet.
      
      	* src/solver-lp.c:
      	New file for linear programming methods created.
      
      	* src/sheet.h:
      	Added parameters for the Solver tool.
      
      	* src/fn-stat.c (gnumeric_correl):
      	Bug fixed.  If the covariance is zero the correlation coefficient
      	should also be zero. Thanks for Vladimir for pointing this one out.
      0e81c949
  14. 30 Mar, 1999 1 commit
  15. 13 Dec, 1998 1 commit
    • Sebastian Wilhelmi's avatar
      Changed to use the glib GDate type instead of the lib_date functions. · 74e388f9
      Sebastian Wilhelmi authored
      1998-12-13  Sebastian Wilhelmi  <wilhelmi@ira.uka.de>
      
      	* src/fn-date.c (gnumeric_year_month_day, gnumeric_now,
      	gnumeric_today,gnumeric_date):
      	* src/workbook.c (insert_current_date_cmd):
      	* src/number-match.c (compute_value): Changed to use the glib
      	GDate type instead of the lib_date functions. Fixed off by-one
      	error for some date functions (e.g. =today ()) was one day to
      	early).
      
      	* src/utils.c, src/utils.h (g_date_serilal, g_date_serial_new):
      	New functions for handling the gnumeric serial of a date.
      74e388f9
  16. 28 Nov, 1998 1 commit
    • Miguel de Icaza's avatar
      OH MY GOD! This has been on my laptop for AGES! and it never went into CVS. What a dork I am · 11be5291
      Miguel de Icaza authored
      So, here it is:
      
      1998-11-13  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/sheet-autofill.c (autofill_cell): Simplify by using
      	cell_set_formula_tree
      
      	* src/expr.c (expr_parse_string): Take a sheet argument
      	(expr_decode_tree): Same
      
      	* sheet.c (cellref_name): Now takes a sheet argument and decodes the
      	cellref depending on the sheet.
      
      	* cell.c (CellRef): Now they include the sheet location.
      11be5291
  17. 13 Nov, 1998 1 commit
    • Miguel de Icaza's avatar
      Use case-insenstive routines when creating the hash table. · 3cbc7cdc
      Miguel de Icaza authored
      1998-11-12  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/parser.y:
      
      	* src/workbook.c (workbook_new): Use case-insenstive routines when
      	creating the hash table.
      	(workbook_sheet_get_free_name): Find an unused name for a sheet.
      	(workbook_sheet_lookup): Looks up a sheet by name in a Workbook.
      	(insert_sheet_cmd): New command to insert a sheet into a workbook.
      
      	* src/utils.c (gnumeric_strcase_hash, gnumeric_strcase_equal):
      	Routines used for strings hash tables that are not case
      	sensitive.
      
      1998-11-12  Morten Wellinder <terra@diku.dk>
      
      	* test-parser.c: Fix to compile with the new API
      
      	* parser.y: Make the code more maintainable.
      3cbc7cdc
  18. 13 Oct, 1998 1 commit
    • Miguel de Icaza's avatar
      It is amazing the number of times I duplicated this code. I wonder if I · cd222d42
      Miguel de Icaza authored
      1998-10-13  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/utils.c (col_name): It is amazing the number of times I
      	duplicated this code.  I wonder if I took prozac by accident.
      	This should fix the bug reported by Morten Welinder
      
      1998-10-12  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/sheet-view.c (vertical_scroll_event,
      	horizontal_scroll_event): Set the top column/row from the
      	adjustment as well.
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_set_top_col,
      	gnumeric_sheet_set_top_row): Export these functions to improve the
      	scrolling behaviour.
      
      1998-10-12  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/utils.c (cellref_name): Fixed another of column name
      	decoding.  I wonder when I will learn.
      cd222d42
  19. 12 Oct, 1998 1 commit
  20. 30 Sep, 1998 1 commit
  21. 23 Sep, 1998 1 commit
    • Miguel de Icaza's avatar
      At font creation time store a couple of the font attributes for quick · f7e3b6a2
      Miguel de Icaza authored
      1998-09-23  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/style.c (font_compute_hints): At font creation time store a
      	couple of the font attributes for quick retrieval.
      
      	* src/sheet-view.c (sheet_view_construct): Do not allow this
      	button to have the focus either.
      
      	* src/item-bar.c (item_bar_draw): If the whole sheet is selected,
      	draw all of the columns in pressed presenstation
      
      	* src/sheet.c (sheet_is_all_selected): Return wheter all the sheet
      	is selected.
      
      	* src/utils.c (cell_name): Fixed cell name computation.
      f7e3b6a2
  22. 04 Sep, 1998 1 commit
  23. 26 Aug, 1998 1 commit
    • Arturo Espinosa's avatar
      Today: · 061a1e74
      Arturo Espinosa authored
      
      
      Today:
      
      	- Column delete and Row delete work.  Bindings all over the
      	  place are working (context menus, menus, etc).
      
      	- Made scrollbars usable and include a tooltip-like thing
      	  like Excel does.
      
      	  They still are kind of inacurrate, and I just figured
      	  out a terrible design mistake that will be fixed tomorrow
      	  (it is kind of big).
      
      	- Various bug fixes to little things I had overlooked in
      	  cell insert/shift routines.
      
      Miguel.
      061a1e74
  24. 24 Aug, 1998 1 commit
    • Arturo Espinosa's avatar
      Lots of changes during the weekend: · ba7fbc1f
      Arturo Espinosa authored
      
      
      Lots of changes during the weekend:
      
      	- New style management code:  All styles are now managed by
      	  regions on a sheet (the default region, is attached to the
      	  complete sheet).
      
      	- Styles can now be partial: Only some parts of the style
      	  might be valid (this is very important).
      
      	- Insert column/Insert row/Shift rows has been fixed and
      	  it now computes properly the dependencies on any
      	  data change.
      
      	- Linking/unlinking formulas now takes care also of
      	  adding/removing the dependencies of the cell.
      
      Miguel.
      ba7fbc1f
  25. 14 Aug, 1998 1 commit
  26. 13 Aug, 1998 1 commit
  27. 30 Jul, 1998 1 commit
    • 0's avatar
      Free the record that tracks the allocation records. (alloc_clean): Handle · 69def31c
      0 authored
      1998-07-30    <miguel@nuclecu.unam.mx>
      
      	* src/parser.y (alloc_clean): Free the record that tracks the
      	allocation records.
      	(alloc_clean): Handle Strings.
      	(alloc_list_free): New function: cleans up the allocation list.
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_load_cell_val): Fix to use
      	the new Strings.
      
      	* src/cell.h: Use the new Strings instead of the Symbols.  That
      	was just a stupid idea.
      
      	* src/str.c (string_ref): New file:  Implements string sharing.
      
      	* src/symbol.c (symbol_install): Use our copy of the allocated key
      	when installing the symbol.
      
      1998-07-29    <miguel@nuclecu.unam.mx>
      
      	* src/symbol.c (symbol_unref_ptr): New function that does symbol
      	unreferencing and if the reference count reaches zero, it also
      	sets the value pointed to NULL.
      
      	* src/sheet.c (cell_set_text): Release evaluation tree after
      	entering new contents in a cell.
      
      	* src/sheet.h (Cell): We now keep all of the character information
      	as refcounted Symbols.
      
      	* src/expr.c (eval_node_release): Renamed and made static.  New
      	allocation strategy: EvalTree's top node are now refcounted to
      	simplify cell duplication.
      	(eval_expr): Now it takes column and row arguments for evaluating
      	the expression in that context.
      	(expr_parse_string): Same.
      
      	* src/parser.y: Renamed EvalNode to EvalTree.
      	(return_cellref): CellRefs now contain offsets relative to the
      	current column/row if the references are not absolute.
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_make_cell_visible): Use new
      	helper routines for doing the scrolling.  Scroll vertically.
      	(gnumeric_sheet_set_top_row, gnumeric_sheet_set_top_col): New
      	routines for keeping the contents of the canvas and the bars in
      	sync.
      	(gnumeric_sheet_new): Take the ItemBars for the columns and rows
      	as a parameter now.
      
      	* src/sheet.c (sheet_select_all): New routine: select the complete spreadsheet.
      
      	* src/item-bar.c (item_bar_class_init): Signal now takes an extra
      	argument which indicates the beginning of a column selection.
      
      	* src/sheet.c (sheet_selection_col_extend_to,
      	sheet_selection_row_extend_to): New methods for implementing the
      	extending column and row selection.
      	(sheet_row_selection_changed, sheet_col_selection_changed): Now
      	they use the new parameter to start the selection.
      69def31c
  28. 25 Jul, 1998 1 commit
    • Arturo Espinosa's avatar
      Weee! Regular strings are now treated as values (so they can be used in · a30e70c3
      Arturo Espinosa authored
      
      
      Weee!  Regular strings are now treated as values (so they
      can be used in cell expressions).  This means you can actually
      start typing expressions and they will actually make sense
      (note that no recalc is yet supported).
      
      The code to do interactive selections is there, but for some
      reason the cursor is not paying much attention to me.
      
      This feature lets you select a cell for an expression if you
      type in a formula in the spreadsheet (just type '=' and use
      the arrow keys to see my buggy code).
      a30e70c3
  29. 22 Jul, 1998 1 commit
    • Miguel de Icaza's avatar
      Numbers are parsed correctly. Bits of Oleo number parsing plugged in. · ef28d5f2
      Miguel de Icaza authored
      1998-07-21  Miguel de Icaza  <miguel@nuclecu.unam.mx>
      
      	* src/parser.y (yylex): Numbers are parsed correctly.  Bits of
      	Oleo number parsing plugged in.
      
      	* src/util.c, src/util.h: New files with assorted number utilities.
      
      	* src/numbers.h: New file: takes care of using gmp or regular
      	double/int.
      
      	* src/expr.c (eval_release_node): Implement.
      	(eval_release_value): New function.
      
      	* src/sheet.c (sheet_col_selection_changed,
      	sheet_row_selection_changed): Implement.
      	(sheet_selection_clear, sheet_selection_clear_only): Splitted
      	functionality into two routines.
      	(sheet_selection_clear_only): Remove any marks from the bars.
      	(sheet_row_set_selection, sheet_col_set_selection): Implement.
      
      	* src/item-bar.c (is_pointer_on_division): Return the column
      	changed.
      
      	* src/item-grid.c (item_grid_draw_cell): Fix the computation for
      	right indentation.
      ef28d5f2