1. 14 Aug, 1998 5 commits
  2. 13 Aug, 1998 3 commits
  3. 12 Aug, 1998 7 commits
  4. 11 Aug, 1998 1 commit
  5. 10 Aug, 1998 1 commit
  6. 08 Aug, 1998 3 commits
    • Arturo Espinosa's avatar
      It autocalcs! · d2c3b2ba
      Arturo Espinosa authored
      
      
      It autocalcs!
      
      My technique is incredibly cool!  The engine should support
      most excel features for recursive computations (we just need
      the dialog boxes now).
      
      It still has a wierdo crash from a mismatched string ref/unref
      but that is going to be trivial to fix.
      
      Next step:  Functions in Perl.
      d2c3b2ba
    • Arturo Espinosa's avatar
      Forgot this file · 76c29c52
      Arturo Espinosa authored
      76c29c52
    • Arturo Espinosa's avatar
      Today it probably does not compile, but I have to leave now. · 6b09bc61
      Arturo Espinosa authored
      
      
      Today it probably does not compile, but I have to leave now.
      
      This is basically the framework for getting computations working.
      
      My current approach is to register areas of interest for a cell.
      This is not perfect, but good enough:
      
      	The idea is to walk the expression tree and look for
      	cell references (cell references or ranges) and register
      	those areas of "interest" for a cell.
      
      	When a new text is entered into a cell, the "regions" of
      	interest list is checked and if a match is found, then
      	the cells on that region of interest are queued for
      	recomputation.
      
      Of course, I do not know yet how to handle the recursive references.
      
      One option is to keep a counter (that starts at zero) during
      recomputation, ie something like:
      
      eval_cell (Cell *cell)
      {
      	cell->use_count++;
      	if (cell->use_count > threshold)
      		return "Cycle too depth";
      	...
      	on value lookup:
      		eval_cell (cell);
      	...
      	cell->use_count--;
      }
      6b09bc61
  7. 07 Aug, 1998 7 commits
  8. 06 Aug, 1998 1 commit
    • Arturo Espinosa's avatar
      Lots of things today: · b261e986
      Arturo Espinosa authored
      
      
      Lots of things today:
      
      - New functions implemented:
      	SELECTION(),  SUM(),  IF()
      
      - Autocompute of an expression that applies to the selection.
      
      - Added comparission to the expression grammar.
      
      - Added array values.
      
      Bug fixes as usual and lots other thingies I forget.
      
      Miguel
      b261e986
  9. 05 Aug, 1998 5 commits
  10. 04 Aug, 1998 2 commits
  11. 31 Jul, 1998 1 commit
    • Federico Mena Quintero's avatar
      Neat X hack: set the window backing pixmap to NULL, so that the window · a0190b68
      Federico Mena Quintero authored
      1998-07-30  Federico Mena Quintero  <federico@nuclecu.unam.mx>
      
      	* src/sheet.c (canvas_bar_realized):
      	* src/gnumeric-sheet.c (gnumeric_sheet_realize): Neat X hack:  set
      	the window backing pixmap to NULL, so that the window does not get
      	cleared when it receives an exposure event.  It will just leave
      	whatever bits were on the window when the expose happened.  This
      	allows us to avoid flicker.  *** MIGUEL, LOOK AT THIS ***
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_make_cell_visible): Fixed
      	width/height confusion (cut&paste bug).
      
      	* src/sheet.c (new_canvas_bar): Set outrageously big scrolling
      	limits.  This has to be fixed to use the real sheet's dimensions.
      	(sheet_new): Use correct table expansion parameters.
      a0190b68
  12. 30 Jul, 1998 4 commits
    • Federico Mena Quintero's avatar
      Use gnome_canvas_scroll_to(). · 83801a54
      Federico Mena Quintero authored
      1998-07-30  Federico Mena Quintero  <federico@nuclecu.unam.mx>
      
      	* src/sheet.c (sheet_set_zoom_factor): Use gnome_canvas_scroll_to().
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_set_top_row): Scroll using
      	gnome_canvas_scroll_to().
      	(gnumeric_sheet_set_top_col): Likewise.
      	(gnumeric_sheet_make_cell_visible): Get the offsets using
      	gnome_canvas_get_scroll_offsets().
      	(gnumeric_sheet_make_cell_visible): Use gnome_canvas_scroll_to().
      83801a54
    • Federico Mena Quintero's avatar
      Query the colormap with gtkdget_get_colormap(), because the canvas · ed5aa7d4
      Federico Mena Quintero authored
      1998-07-30  Federico Mena Quintero  <federico@nuclecu.unam.mx>
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_color_alloc): Query the
      	colormap with gtkdget_get_colormap(), because the canvas structure
      	no longer has a colormap field in it.
      	(gnumeric_sheet_set_top_row): Use the canvas layout adjustment to
      	scroll.
      	(gnumeric_sheet_set_top_col): Use the canvas layout adjustment to
      	scroll.
      	(gnumeric_sheet_make_cell_visible): Get the values from the canvas
      	adjustments.
      
      	* src/sheet.c (new_canvas_bar): Call gnome_canvas_new() correctly.
      	(scroll_to): New helper function to scroll a canvas.
      	(sheet_set_zoom_factor): Use scroll_to().
      
      	* src/gnumeric-sheet.c (gnumeric_sheet_create): Do not call
      	gnome_canvas_construct() at is does not exist anymore.
      	(gnumeric_sheet_new): Use outrageously big values for the canvas
      	scrolling region, for now.  This needs to be fixed.
      	(gnumeric_sheet_make_cell_visible): Use the canvas layout
      	adjustment to scroll.
      ed5aa7d4
    • Arturo Espinosa's avatar
      Missing files from last commit · edb8c481
      Arturo Espinosa authored
      edb8c481
    • 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