Commit a5e65a30 authored by Miguel de Icaza's avatar Miguel de Icaza Committed by Arturo Espinosa

The big GNUMERIC_PRINT merge into HEAD.



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.
parent c1c745c7
Change between versions 0.27 and 0.28
Miguel:
Print support (imported from the GNUMERIC_PRINT branch).
Pattern selector works again.
----------------------------------------------------------------------
Changes between version 0.26 and 0.27
Jukka:
......
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.
1999-06-26 Morten Welinder <terra@diku.dk>
* src/fn-financial.c (gnumeric_rate): New function.
......@@ -3439,6 +3654,4432 @@ Tue Mar 23 14:00:37 CET 1999 Daniel Veillard <Daniel.Veillard@w3.org>
* plugins/excel/ms-formula.c (ms_excel_parse_formula):
FORMULA_PTG_ATTR stubs: can ignore most of AttrSpace.
1999-06-02 Michael Meeks <michael@edenproject.org>
* src/expr.c (do_expr_decode_tree): Added ARRAY support.
1999-06-01 Morten Welinder <terra@diku.dk>
* src/format.c (format_value): Mark format for translation.
(format_number): Locale improvements.
* src/parser.y (yylex): Translate locale's decimal point into a
dot.
(gnumeric_expr_parser): Extract locale's decimal point.
1999-06-01 Akira Higuchi <a-higuti@math.sci.hokudai.ac.jp>
* src/gnumeric-util.c (font_change_component): Extend the size of
the array components[] so that it can handle very long fontset
names.
* src/style.c: Change the default font names.
* src/workbook.c: Add gtk_widget_ensure_style() call, which is
necessary to knowing if a fontset is supplied for the label
widget.
1999-06-01 Morten Welinder <terra@diku.dk>
* src/fn-stat.c (callback_function_trimmean): Cleanup.
(gnumeric_large): Fix conditional. Thanks to Nick Lamb.
(gnumeric_small): Ditto.
1999-06-01 Morten Welinder <terra@diku.dk>
* src/fn-stat.c (gnumeric_skew): Fix crashes and leaks.
(gnumeric_covar): Ditto.
(gnumeric_rsq): Ditto.
(gnumeric_pearson): Ditto.
(gnumeric_correl): Ditto.
(gnumeric_avedev): Ditto.
(gnumeric_stdev): Don't make assumptions of the type of VAR.
(gnumeric_stdevp): Ditto.
(gnumeric_stdeva): Ditto.
(gnumeric_stdevpa): Ditto.
(callback_function_covar): Simplify greatly.
(callback_function_correl): Ditto.
(callback_function_stat_avedev_sum): Ditto.
(callback_function_skew_sum): Ditto. Also improve precision.
(callback_function_rank): Ditto.
(callback_function_trimmean): Ditto.
(callback_function_mode): Ditto.
(callback_function_stat_prod): Ditto.
(callback_function_count): Ditto.
(callback_function_kurt_sum): Ditto.
(callback_function_ztest): Ditto.
(callback_function_list): Ditto.
(callback_function_percentrank): Ditto.
(gnumeric_skew): Handle zero stddev.
* src/expr.c (eval_cell_value): Delete. Use value_duplicate
instead.
(eval_funcall): Fix memory corruption on error. Fix serious leak.
(free_values): Only free non-NULLs.
1999-06-01 Miguel de Icaza <miguel@nuclecu.unam.mx>
* src/file.c (dialog_query_load_file):
(workbook_save_as): Prettify these. Thanks to Andrew for pointing
this out.
1999-06-01 Morten Welinder <terra@diku.dk>
* src/fn-stat.c (gnumeric_kurt): Fix crashes and leaks.
1999-06-01 Jukka-Pekka Iivonen <iivonen@iki.fi>
* src/fn-string.c: Added SEARCH(). Quite a complex beast but
should work completely.
1999-06-01 Morten Welinder <terra@diku.dk>
* src/fn-stat.c (gnumeric_confidence): Fix sign.
(gnumeric_devsq): Simplify and correct.
* src/file.c: undo last change. (The operation succeeded, but the
patient died.)
1999-05-31 Matt Loper <matt@gnome-support.com>
* src/sheet-view.c: Because GNOME::Component was renamed to
GNOME::BonoboObject, some bonobo function call names needed to be
changed here (ex. gnome_component_new_view to
gnome_bonobo_object_new_view).
* src/sheet-object-container.c (sheet_object_container_land):
likewise.
(sheet_object_container_realize): likewise.
1999-05-31 Jukka-Pekka Iivonen <iivonen@iki.fi>
* src/fn-lookup.c: Added ADDRESS(). Cleaned up too long lines.
1999-05-28 Morten Welinder <terra@diku.dk>
* src/file.c (workbook_read): Temporarily switch to "C" locale
when loading and saving. I am not sure this is the right thing to
do, but until someone finds a better way, it will work fine.
(workbook_save_as): Ditto.
(workbook_save): Ditto.
* src/fn-math.c (gnumeric_power): Fix domain.
1999-05-27 Morten Welinder <terra@diku.dk>
* src/expr.c (value_get_as_string): Improve precision -- this
impacts the results of saves.
1999-05-27 Morten Welinder <terra@diku.dk>
* src/fn-stat.c (callback_function_mode): Ignore strings as
advertised.
(callback_function_stat_inv_sum): Ditto.
(callback_function_rank): Ditto.
(callback_function_trimmean): Ditto.
(callback_function_covar): Ditto.
(callback_function_correl): Ditto.
(callback_function_stat_prod): Ditto.
(callback_function_skew_sum): Ditto.
(callback_function_kurt_sum): Ditto.
(callback_function_stat_avedev_sum): Ditto.
(callback_function_devsq_sum): Ditto.
(callback_function_median): Ditto.
(gnumeric_tinv): Fix meaning.
(callback_function_count): Cleanup.
(callback_function_stat_inv_sum): Ditto. Also fix error case.
(gnumeric_normdist): Simplify using dnorm.
(gnumeric_gammadist): Use dgamma.
* src/mathfunc.c (dgamma): New function from R.
1999-05-27 Jukka-Pekka Iivonen <iivonen@iki.fi>
* src/fn-stat.c: Added BETAINV() and CHITEST(). Added optional
parameters A and B to BETADIST(). Implemented non-cumulative case
of NORMDIST(). Implemented cumulative case of POISSON(). Fixed
CHIDIST(), CHIINV(), FDIST(), FINV(), and TDIST() to return the
complement of the probablity. It looks like TINV() is still
broken after file restructurations.
1999-05-26 Morten Welinder <terra@diku.dk>
* src/sheet-view.h: Include fix.
* src/style.h: Include fix.
* src/symbol.c (symbol_table_new): Use gnumeric_strcase_equal and
gnumeric_strcase_hash.
(g_strcase_equal): Delete.
(g_strcase_hash): Delete.
* src/eval.c (dependency_equal): Constify.
* src/sheet.c (cell_hash): Constify.
(cell_compare): Ditto.
(CRsort): Ditto.
1999-05-26 Michael Meeks <michael@imaginator.com>
* src/file.c (file_saver_is_default_format): Fixed bug causing
incorrect format to be displayed.
(fill_save_menu): Wait until we have populated the option menu
before setting the current item.
(make_format_chooser): Move some code into file_save_menu.
* src/xml-io.c (writeXmlSheetTo): Removed,
(writeXmlWorkbook): Use the order workbook_sheets list.
* src/workbook.c (cb_workbook_sheets): Commented out
(workbook_sheets): Get sheets in order from notebook tabs.
1999-05-25 Morten Welinder <terra@diku.dk>
* src/mathfunc.c, src/mathfunc.h: New files, mostly taken from the
R package. (It's a GPL'ed gold mine.)
* src/*.c: Use <math.h>, not "math.h".
* src/utils.c (random_normal): Use qnorm, not inv_phi.
* src/fn-stat.c: Move all R code to mathfunc.c
Change all uses to phi to pnorm.
(gnumeric_normsinv): Use qnorm.
(gnumeric_confidence): Use qnorm.
(normsinv): Superseded by qnorm.
(help_lognormdist): Fix.
(gnumeric_lognormdist): Fix domain.
(gnumeric_lognormdist): Use plnorm.
(gnumeric_loginv): Use qlnorm.
(gnumeric_norminv): Use qnorm.
(gnumeric_tinv): Use qt.
(gnumeric_fdist): Use qf.
(gnumeric_gammainv): Use qgamma.
(gnumeric_chiinv): Use qchisq.
* src/Makefile.am (GNUMERIC_BASE_SOURCES): Add mathfunc.c and
mathfunc.h.
1999-05-25 Morten Welinder <terra@diku.dk>
* src/fn-string.c (gnumeric_code): Handle compilers for which the
"char" type is signed.
* src/utils.c (parse_cell_name): Don't use isalpha which is
subject to locale. (So is toupper, but the effects are ok.)
Move bounds check to handle overflow also.
(col_from_name): Don't use isalpha.
* src/fn-stat.c: Eliminate fmin2 and fmax2.
* src/fn-math.c (gnumeric_randbetween): Use random_01.
(gnumeric_rand): Ditto.
* src/utils.c (random_01): Function moved from goal-seek.c and
improved.
(random_normal): Function moved from goal-seek.c.
* configure.in: Check for a few ways of getting random numbers.
1999-05-23 Miguel de Icaza <miguel@nuclecu.unam.mx>
* src/file.c (workbook_save_as): Handle the window closing by the
window manager here.
(dialog_query_load_file): And here.
* src/dialog-zoom.c (dialog_zoom): Handle window manager close
here (it comes in the form of return value being NULL).
* src/dialog-insert-cells.c (dialog_insert_cells): ditto.
* src/dialog-delete-cells.c (dialog_delete_cells): ditto.
1999-05-24 Morten Welinder <terra@diku.dk>
* src/workbook.c (workbook_fixup_references): Set formula
directly, not via text strings. (This actually fixes a bug with
insertion of columns/rows where we modify the cells before we
restructure the sheet.) It's much faster and cleaner too.
(workbook_invalidate_references): Ditto.
1999-05-23 Morten Welinder <terra@diku.dk>
* src/gnumeric-sheet.c (gnumeric_sheet_cursor_set): Make the
scroll bar reflect the top-left corner's position. This feels
more natural.
(gnumeric_sheet_set_top_col): Compute visible ranges; do nothing
until things change.
(gnumeric_sheet_set_top_row): Ditto.
* src/dialog-goal-seek.c (gnumeric_goal_seek): Use
goal_seek_initialise.
(gnumeric_goal_seek): Trawl heavier and earlier in the middle.
(dialog_goal_seek): downcase a stray uppercase letter.
* src/goal-seek.c (goal_seek_initialise): New function.
1999-05-23 Morten Welinder <terra@diku.dk>
* src/dialog-goal-seek.c: redesign non-gui part.
(dialog_goal_seek): Added entries for xmin and xmax.
* src/goal-seek.h: New file.
* src/goal-seek.c: New file.
* src/Makefile.am (GNUMERIC_BASE_SOURCES): Add goal-seek.c and
goal-seek.h.
1999-05-22 Morten Welinder <terra@diku.dk>
* src/fn-financial.c (gnumeric_pv): Revert last chance. (Bogosity
is in me.)
1999-05-22 Morten Welinder <terra@diku.dk>
* src/sheet.c (sheet_selection_to_string): Delete unused variable
"assembler".
* src/sheet-view.c (horizontal_scroll_event): Delete unused
variable "distance".
(vertical_scroll_event): Delete unused variable "distance".
* src/sheet-object.c (control_point_handle_event): Delete unused
variables "ll" and "object_item".
* src/widget-editable-label.c (editable_label_set_text): Delete
unused variable "item_text".
* src/fn-string.c (gnumeric_replace): Delete unused variable "p".
* src/fn-eng.c (get_real_and_imaginary): Delete unused variables
"i" and "buf".
* src/sheet-object-graphic.c (sheet_object_filled_update): Delete
unused variables "x1", "x2", "y1", and "y2".
* src/fn-stat.c (gnumeric_harmean): Delete unused variable "ans".
(gnumeric_geomean): Delete unused variable "ans".
(gnumeric_avedev): Delete unused variable "ans".
(gnumeric_large): Delete unused variable "count".
(gnumeric_small): Delete unused variable "count".
* src/parser.y (make_string_return): Delete unused variable "type".
* src/workbook.c (cb_sheet_check_dirty): Delete unused variable
"f".
(workbook_focus_sheet): Delete unused variable "sheet_view".
(workbook_selection_to_string): Delete unused variable "str".
* src/fn-date.c (gnumeric_datevalue): Delete unused variables
"year", "month", and "day".
(gnumeric_edate): Delete unused variables "year", "month", and
"day".
* src/dialog-cell-format.c (apply_coloring_format): Delete unused
variable "cl".
* src/dialog-solver.c: Delete unused variable "paste_types".
* src/xml-io.c (xmlGetFloatValue): Delete unused variable "child".
(xmlGetDoubleValue): Delete unused variable "child".
(xmlGetCoordinate): Delete unused variable "child".
(xmlGetGnomeCanvasPoints): Delete unused variable "child".
(xmlGetColorValue): Delete unused variable "child".
(xmlGetCoordinates): Delete unused variable "child".
(xmlGetCoordinates): Delete unused variables "X1", "Y1", "X2", and
"Y2".
* src/sheet-object-graphic.c (sheet_object_graphic_update): Delete
unused variable "sog".
* src/cell.c (cell_set_value_simple): Delete unused variable "lconv".
(cell_set_text_simple): Delete unused variable "lconv".
(cell_draw): Delete unused variable "white_gc".
(cell_get_text): Delete unused variable "sheet".
* src/ranges.c (range_list_parse): Delete unused variable "range".
(range_set_style): Delete unused variables "col" and "row".
* src/dialog-solver.c (dialog_solver_options): Delete unused
variable "button".
* src/eval.c (search_cell_deps): Delete unused variables "inters"
and "nointers".
* src/dialog-cell-sort.c (dialog_cell_sort): Delete unused
variable "txt".
* src/fn-database.c (find_cells_that_match): Delete unused
variable "new_item".
* src/func.c (function_iterate_do_value): Delete unused variable
"list".
* src/fn-lookup.c (gnumeric_lookup): Delete unused variables "v1"
and "ans".
(lookup_functions): Use correct help variable
for "columns".
* src/dialog-function-select.c (function_select_create): Delete
unused variable "hadj".
* src/main.c (gnumeric_main): Delete unused variable.
* src/dialog-function-wizard.c (function_type_input): Remove
unused variable.
(get_text_value): Ditto.
(arg_data_list_destroy): Comment out -- not used.
* src/fn-financial.c (gnumeric_pv): Fix sign error. Something is
entirely bogus in this file.
* src/ranges.h: Fix includes.
* src/pattern-selector.h (PATTERN_SELECTOR_CLASS): Bogosity fixed;
macro not used, though.
* src/workbook.c (sheet_action_delete_sheet): Grammar fix.
* src/sheet.c (sheet_verify_selection_simple): Grammar fix.
* src/file.c (file_priority_sort): Constify.
(file_format_register_open): Make description parameter const.
(file_format_register_save): Ditto.
(file_format_unregister_open): Plug leak.
(file_format_unregister_save): Ditto.
(workbook_save_as): Grammar fix.
* src/about.c (dialog_about): Fix URL.
1999-05-22 Morten Welinder <terra@diku.dk>
* src/sheet.c (sheet_set_text): Use General format for all numbers
in standard format. (In particular, don't create a sticky "0" format
whenever an integer is entered.)
* src/format.c (format_number): Constify.
(append_minute): Ditto.
(append_day): Ditto.
(append_hour): Ditto.
(append_month): Ditto.
(append_year): Ditto.
(append_second): Ditto.
(check_valid): Ditto.
(append_half): Ditto.
(lookup_color): Ditto.
(render_number): Ditto.
(format_value): Ditto.
* src/expr.c (do_expr_decode_tree): Handle negative numbers, just
in case.
1999-05-21 Morten Welinder <terra@diku.dk>
* src/sheet-autofill.c (autofill_cell): Add FIXME.
* src/sheet.h (IS_SHEET): Remove cast.
* src/expr.h: Delete expr_tree_relocate.
* src/expr.c (fixup_calc_new_cellref): New function.
(do_expr_tree_fixup_references): Simplify using
fixup_calc_new_cellref.
(do_expr_tree_relocate): Delete.
(expr_tree_relocate): Delete.
* src/sheet.c (sheet_cell_formula_link): Add debug code.
(sheet_insert_col, sheet_delete_col, sheet_insert_row,
sheet_delete_row): Do fixups early.
* src/cell.c (cell_relocate): Don't relocate cell -- fixup handles
all that is needed.
* src/color.c (gs_white, gs_black, gs_light_gray, gs_dark_gray,
gs_red): Moved from src/gnumeric-sheet.c.
(gnumeric_color_context): make static.
1999-05-21 Jukka-Pekka Iivonen <iivonen@iki.fi>
* src/fn-stat.c: PERCENTRANK() added.
* src/func.[ch]: function_iterate_do_value made public.
1999-05-21 Morten Welinder <terra@diku.dk>