ChangeLog-1999-07-09 213 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70
1999-06-23  Michael Meeks  <michael@edenproject.org>

	* src/sheet.c (sheet_update_auto_expr): Add check for cached
	text.

	* src/sheet.h: Added workbook_set_auto_expr.

	* src/workbook.c (workbook_new): Initialise auto_expr stuff
	before reading it in set_auto_expr.
	(workbook_do_destroy): Add freeing of auto_expr_text.
	(workbook_set_auto_expr): Hacked to cache expression until we
	have a sheet context.


	* src/expr.h: Add extra Parser error type for invalid args.

	* src/fn-financial.c (finance_functions_init): Fix financial
	functions, using 'i' as a token ( invalid ).

1999-06-23  Michael Meeks <michael@edenproject.org>

	* docs/writing-functions.sgml: Updated to reflect my changes,
	expanded and removed anachronisms.
	
	* src/expr.h: Added FunctionArgs, FunctionNodes typedefs
	Created struct EvalPosition, struct FunctionEvalInfo and
	implemented through functions where necessary.

	* src/expr.c (function_error, function_error_alloc): created
	helper error return functions.
	(eval_pos_init, eval_pos_cell): Helper EvalPosition fn's
	(func_eval_info_init, func_eval_info_cell, func_eval_info_pos):
	created helper FunctionEvalInfo fn's
	(error_message_new, error_message_set_alloc),
	(error_message_set_small, error_message_txt, error_message_free):
	created error class.

	* src/expr.c (expr_parse_string, gnumeric_expr_parser),
	(expr_decode_tree, expr_tree_invalidate_referenced),
	(expr_tree_fixup_references, eval_expr): Updated to pass / use
	new EvalPosition / FunctionEvalInfo structures.

	* src/parser.y (gnumeric_expr_parser): Updated arguments to use
	EvalPosition, added more stringent checks.

	* src/func.h: Updated lots of things to new structures.
	Changed the iterators arguments to new structures, altered
	FunctionIterateCallback to suit.
	Re-implemented function storage / mapping.

	* src/func.c (function_get_category, function_add_args),
	(function_add_nodes): Created.
	(function_iterate_do_value, function_argument_values),
	(function_call_with_values, function_def_call_with_values):
	Updated to new scheme.
	
	* src/fn-*: Major major changes:
	- All function definitions changed to use:
	typedef Value *(FunctionArgs)  (FunctionEvalInfo *fe, Value **args); or
	typedef Value *(FunctionNodes) (FunctionEvalInfo *fe, GList *nodes);
	- All error returns altered to use:
	        return function_error (ei, _("foo"));
	instead of
	        {
		        *error_string = _("baa");
			return NULL;
		}
	this will allow for changing the error handling.
	- A few functions that used Sheet *, eval_col, eval_row updated.
	
71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86
1999-06-23  Morten Welinder  <terra@diku.dk>

	* src/collect.c, src/collect.h: New files.

	* src/Makefile.am (GNUMERIC_BASE_SOURCES): Add collect.c and
 	collect.h.

	* src/fn-stat.c: Rewrite range-taking using collect and new range
 	handling functions.  Most look really nice now.  (This fixes and
 	number of leaks and makes error cases handled better.  We might
 	return the wrong error from time to time, though.)

	* src/fn-math.c: Ditto.

	* src/expr.c (eval_funcall): Fix insanity check.

87 88 89 90 91 92 93 94 95 96
1999-06-22  Morten Welinder  <terra@diku.dk>

	* src/expr.c (eval_funcall): Add sanity check.

	* src/fn-stat.c (callback_function_ttest): Make static.

	* src/expr.h: Delete unwanted member "sym".

1999-06-22  Jukka-Pekka Iivonen  <iivonen@iki.fi>

97 98 99 100 101 102 103 104
        * samples/statfuns.xls: Added MMULT and MINVERSE tests.

        * samples/lookfuns.xls: Added a new file for testing lookup and
 	reference functions.

        * samples/logfuns.xls: Added a new file for testing logical
        functions.

105 106 107 108 109 110 111
1999-06-22  Nat Friedman  <nat@gnome-support.com>

	* src/sheet-object-container.c (sheet_object_container_land): Use
 	gnome_bonobo_object_clieint_new_view instead of
 	gnome_bonobo_object_new_view.
	(sheet_object_container_realize): Likewise.

112 113
1999-06-22  Morten Welinder  <terra@diku.dk>

Morten Welinder's avatar
Morten Welinder committed
114 115 116
	* src/number-match.c (format_create_regexp): You don't want to
 	know.

117 118 119 120 121 122 123 124 125 126
	* src/fn-date.c (get_serial_date): Cleanup.
	(get_serial_time): Ditto.

	* src/sheet.c (sheet_set_text): Abandon old reverse test that lead
 	to trouble with floating point formats.

	* src/number-match.c (format_match): Change from double to
 	float_t.  All callers changed.
	(compute_value): Ditto.

127 128
1999-06-22  Jukka-Pekka Iivonen  <iivonen@iki.fi>

Jukka-Pekka Iivonen's avatar
Jukka-Pekka Iivonen committed
129 130
	* src/fn-stat.c: Added TTEST().

Jukka-Pekka Iivonen's avatar
Jukka-Pekka Iivonen committed
131 132
	* src/fn-stat.c: Added FTEST().

133 134
	* src/fn-math.c: Added SUMPRODUCT().

Morten Welinder's avatar
Morten Welinder committed
135
1999-06-21  Morten Welinder  <terra@diku.dk>
136 137 138 139 140 141 142 143 144 145 146 147 148 149 150

	* src/dialog-function-wizard.c (arg_data_list_new): Fix case of
 	missing SYNTAX section.
	(create_description): Handle constness of tokenized_help_find.
  	Delete weird #define.

	* src/func.c (tokenized_help_find): Constify.

	* src/expr.c (expr_tree_new_error): Smarten.

	* src/fn-misc.c (gnumeric_error_type): Fix case of incorrect
 	number of arguments.

	* src/fn-information.c (get_value_class): Fix leak.

151 152 153 154
1999-06-21  Miguel de Icaza  <miguel@gnu.org>

	* src/func.c: Do not pre-initialize them.  If they need to be
	pre-initialized something is wrong in some other place.  Fix that
Morten Welinder's avatar
Morten Welinder committed
155
	instead.
156 157 158 159

	* src/clipboard.c (do_clipboard_paste_cell_region): Implement
	transpose-on-paste command.  Change the increment steps for
	transpose and compute a different target column as well.
Morten Welinder's avatar
Morten Welinder committed
160

161
	(sheet_paste_selection): Swap the paste dimesions here if we are
Morten Welinder's avatar
Morten Welinder committed
162
	pasting/transpose.
163 164 165 166 167 168 169 170 171 172 173 174

1999-06-18  Miguel de Icaza  <miguel@gnu.org>

	* src/func.c: Remove static initialization of the error messages.

1999-06-14  Miguel de Icaza  <miguel@gnu.org>

	* src/clipboard.h: Define PASTE_TRANSPOSE.

	* src/dialog-paste-special.c (dialog_paste_special): Add new
	checkbutton for transpose-on-paste operation.

Michael Meeks's avatar
Michael Meeks committed
175 176 177 178 179
1999-06-21  Michael Meeks  <michael@edenproject.org>

	* src/func.c (iterate_cellrange_callback): Add case
	of no cell text ( yet ).

Morten Welinder's avatar
Morten Welinder committed
180 181
1999-06-21  Morten Welinder  <terra@diku.dk>

182 183 184 185 186 187 188 189
	* src/fn-information.c (get_value_class): New function.
	(gnumeric_isnontext): Make non-strict.
	(gnumeric_istext): Make non-strict.
	(gnumeric_type): Make non-strict.
	(gnumeric_islogical): Make non-strict.
	(gnumeric_isnumber): Make non-strict.
	(gnumeric_n): Implement.
	(gnumeric_iseven): Implement.
190 191 192 193 194
	(gnumeric_isodd): Ditto.
	(gnumeric_cell): Fix error message.
	(gnumeric_info): Ditto.
	(gnumeric_type): Partly implement.

Morten Welinder's avatar
Morten Welinder committed
195 196 197 198 199 200 201 202
	* src/fn-math.c (gpow10): Rename from pow10 which colided with
 	something in Linux with libc5.  (Thanks to Alexander Jolk.)

	* src/utils.c (parse_cell_name): Don't use isdigit since we intend
 	to subtract '0' from the character.

	* src/workbook.c (workbook_parse_and_jump): Cleanup.

203 204 205 206 207
1999-06-21  Jukka-Pekka Iivonen  <iivonen@iki.fi>

        * samples/infofuns.xls: Added a new file for testing information
        functions.

Morten Welinder's avatar
Morten Welinder committed
208 209
1999-06-20  Morten Welinder  <terra@diku.dk>

210 211 212 213 214 215 216 217 218 219 220 221
	* src/workbook.c (wb_edit_key_pressed): New function to handle
 	Escape.
	(workbook_setup_edit_area): Activate wb_edit_key_pressed.

	* src/gnumeric-sheet.c (gnumeric_sheet_key_mode_sheet): Call
 	sheet_start_editing_at_cursor for F2.

	* src/sheet.c (sheet_cancel_pending_input): Fix last change.  Also
 	update entry box.
	(sheet_start_editing_at_cursor): New args blankp and cursorp.  All
 	callers changed.

Morten Welinder's avatar
Morten Welinder committed
222 223 224 225 226 227 228 229
	* src/fn-math.c (gnumeric_mod): Another try.
	(gnumeric_int): Fix for negative numbers.

	* src/sheet.c (sheet_set_text): Set value directly, not via text.  Also
	improve entry when a format is already set.
	(sheet_cancel_pending_input): Fixed behavior of canceling a cell
 	entry.  [From Bake Timmon.]

230 231 232 233 234 235 236 237
1999-06-18  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* samples/dbfuns.xls: Added new file for database functions.

	* samples/mathfuns.xls: Added MDETERM test.

	* samples/statfuns.xls: Added AVERAGEA, MINA, MAXA, ... tests.

238 239 240 241 242 243 244 245 246 247 248 249 250 251 252
1999-06-17  Morten Welinder  <terra@diku.dk>

	* src/fn-stat.c (gnumeric_count): Make non-strict and ignore cells
 	with errors.

	* src/fn-logical.c (gnumeric_or, gnumeric_and): Make strict!.

	* src/func.c (IterateCallbackClosure): Add strict member.
	(iterate_cellrange_callback): Handle strict and non-strict case.
	(function_iterate_argument_values): New argument, strict.  All
 	callers changed.  Initialise error_string always.  Handle strict
 	and non-strict case.
	(function_iterate_do_value): New argument, strict.  Handle strict
 	and non-strict case.  All callers changed.

Michael Meeks's avatar
Michael Meeks committed
253 254 255 256 257 258 259 260 261 262
1999-06-18  Michael Meeks  <michael@edenproject.org>

	* src/main.c (gnumeric_main): Add xbase_init

	* src/Makefile.am (gnumeric_LDADD): Add xbase.

	* configure.in (XML_CFLAGS): Added xbase.

	* plugins/Makefile.am (SUBDIRS): Added xbase.

263 264
1999-06-17  Morten Welinder  <terra@diku.dk>

265 266
	* src/expr.c (eval_expr): Fix error handling of comparisons.

Morten Welinder's avatar
Morten Welinder committed
267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284
	* src/expr.c (expr_tree_new_constant): New function.
	(expr_tree_new_unary): New function.
	(expr_tree_new_binary): New function.
	(expr_tree_new_funcall): New function.
	(expr_tree_new_var): New function.
	(expr_tree_new_error): Renamed from build_error_string, made
 	public, and simplified.  All callers changed.
	(do_expr_tree_invalidate_references): Simplify.
	(do_expr_tree_fixup_references): Ditto.
	(eval_expr): Simplify.
	(expr_tree_new): Obsolete.

	* src/func.c (constants_init): Simplify.

	* src/main.c (gnumeric_main): Call style_shutdown.

	* src/style.c (style_shutdown): New function.

Morten Welinder's avatar
Morten Welinder committed
285 286 287 288
	* src/expr.h: Avoid using bitfields here.  They are slow and
 	confuse tools like Purify.  And used like this they don't save any
 	space anyway.

289 290 291 292 293 294 295 296 297 298 299
	* src/complex.c: Fix includes.

	* src/fn-eng.c (gnumeric_impower): Use new complex_pow.
	(callback_function_imoper): Benefit from new and more intuitive
 	behavoiur of complex_mul and complex_add.

	* src/complex.h (complex_mod): Use hypot for better precision.
	(complex_*): Use complex_init when possible.  (This means that the
 	output can be the same as one of the inputs without any trouble.)
	(complex_pow): New function.

300 301 302 303
1999-06-17  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-stat.c (gnumeric_percentrank): Interpolation and rounding
	fixes.
304

305 306 307 308
1999-06-17  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-eng.c (gnumeric_erf): ERF() changed back to the previous
 	form.  Negative arguments are wrong.
309

310 311 312 313 314 315 316 317 318 319
1999-06-16  Morten Welinder  <terra@diku.dk>

	* src/complex.h, src/complex.c: New files.

	* src/fn-eng.c: Use complex.c; improve precision, fix a few bugs,
 	plug a few leaks, add a few functions, and generally be merry.

	* src/Makefile.am (GNUMERIC_BASE_SOURCES): Add complex.c and
 	complex.h.

320 321 322 323 324
1999-06-16  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* samples/finfuns.xls: A new file for financial functions.

	* samples/engfuns.xls: A new file for engineering functions.
325

326 327 328 329
	* samples/mathfuns.xls: COMBIN and FACT fixed.

	* samples/statfuns.xls: Accuracy dropped again.

330 331 332 333 334
1999-06-16  Morten Welinder  <terra@diku.dk>

	* src/workbook.c (workbook_feedback_set): Block the "clicked"
 	handlers when we are just setting the feedback.

335 336 337 338 339 340 341 342 343 344 345 346 347 348 349
1999-06-16  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-math.c (gnumeric_gcd): Made GCD() to take variable number
 	of arguments.

	* src/fn-stat.c (gnumeric_rank): RANK() fixed.

	* src/fn-eng.c (gnumeric_erf): ERF() fixed to return negative
	results if the argument is negative too like in Excel.

	* srg/fn-eng.c (get_real_and_imaginary): Added a branch for empty
 	imaginary part.

	* src/fn-eng.c (gnumeric_improduct, gnumeric_imsum): Made IMSUM()
	and IMPRODUCT() to take variable number of arguments.
350

Morten Welinder's avatar
Morten Welinder committed
351 352
1999-06-15  Morten Welinder  <terra@diku.dk>

Morten Welinder's avatar
Morten Welinder committed
353 354 355 356 357 358 359 360 361 362 363 364 365 366
	* src/style.c (style_font_new_simple): Plug leak.

	* src/cell.c (cell_set_formula_tree_simple): Ref before unref,
 	just in case.

	* src/fn-math.c (callback_function_criteria): Just collect the
 	values, not (incorrectly) allocated pointers to them.
	(gnumeric_countif): Release the values.  (Leak fix.)
	(gnumeric_sumif): Ditto.
	(gnumeric_countif): Plug leak.
	(gnumeric_sumif): Ditto.
	(gnumeric_seriessum): Plug three leaks.
	(gnumeric_subtotal): Plug leaks and fix error handling.

Morten Welinder's avatar
Morten Welinder committed
367 368
	* src/style.c (style_font_new_simple): Fix memory access problem.

Morten Welinder's avatar
Morten Welinder committed
369 370 371 372 373 374 375 376 377
	* src/style.c (font_init): Rework.  (Work in progress.  Things
 	should work ok, but will become even better.)
	(style_font_new_simple): Revert to loading a font, not a fontset.

	* src/gnumeric-util.c (font_get_italic_name): Plug leak and unref
 	the StyleFont.
	(font_get_bold_name, font_get_italic_name): New parameter units.
  	All callers changed.

Tomas Ogren's avatar
Tomas Ogren committed
378 379 380 381
1999-06-15  Tomas Ogren  <stric@ing.umu.se>

	* configure.in: Added sv

Morten Welinder's avatar
Morten Welinder committed
382
1999-06-14  Morten Welinder  <terra@diku.dk>
383

384 385 386 387 388 389 390 391 392
	* src/style.c (style_font_new_simple): Add negative caching.
	(DEFAULT_FONT): Don't have a complete wildcard here -- that might
 	be a very weird font.

	* src/cell.c (cell_set_font_from_style): Mark font valid.  Ref
 	before unref.
	(cell_set_format_from_style): Mark format valid.  Ref before
 	unref.

393 394 395
	* src/gnumeric-util.c (font_get_italic_name): Plug leak.
	(font_change_component): Constify.  Handle fontsets.

396 397
1999-06-14  Morten Welinder  <terra@diku.dk>

Morten Welinder's avatar
Morten Welinder committed
398 399
	* src/fn-math.c (gnumeric_floor): Add significance argument.

Morten Welinder's avatar
Morten Welinder committed
400 401 402 403
	* src/fn-math.c (callback_function_seriessum): Simplify.
	(gnumeric_seriessum): Don't round x, n, and m to integers.  Fix
 	error handling.

404 405 406 407 408 409 410
	* src/fn-math.c (pow10): New function.
	(gnumeric_rounddown): Simplify and correct.
	(gnumeric_round): Ditto.
	(gnumeric_roundup): Ditto.
	(gnumeric_trunc): Ditto.
	(gnumeric_fact): Improve precision.  Extend domain to all positive
 	numbers.
411
	(gnumeric_factdouble): Use float_t instead of int.
412
	(gnumeric_atan2): Swap args to atan2.
413

414 415
1999-06-13  Morten Welinder  <terra@diku.dk>

Morten Welinder's avatar
Morten Welinder committed
416 417 418 419
	* src/style.c (DEFAULT_FONT): Add extra font in the hope of curing
 	1207.
	(font_init): Shine up error message and avoid core dump.

420 421 422
	* src/gnumeric-sheet.c (gnumeric_sheet_stop_cell_selection):
 	Temporary patch for refcounts until Miguel can fixup things.
	(destroy_item_editor): Ditto.
423 424 425 426 427 428 429 430 431 432 433 434

	* src/fn-financial.c: s/double/float_t/;
	(calculate_pvif, calculate_pvifa, calculate_fvif, calculate_fvifa,
 	calculate_principal, calculate_pmt): Make static.
	(callback_function_npv): Simplify and truly ignore strings.
	(gnumeric_duration): More error checks.
	(gnumeric_nper): Ditto.
	(gnumeric_syd): Ditto.
	(gnumeric_sln): Ditto.
	(gnumeric_pv): Ditto.
	(gnumeric_fv): Ditto.

435 436 437 438 439 440 441 442 443 444 445 446 447
	* src/fn-information.c: Prune includes.
	* src/fn-string.c: Ditto.
	* src/fn-sheet.c: Ditto.
	* src/fn-misc.c: Ditto.
	* src/fn-financial.c: Ditto.
	* src/fn-date.c: Ditto.
	* src/fn-database.c: Ditto.
	* src/fn-lookup.c: Ditto.
	* src/fn-stat.c: Ditto.
	* src/fn-math.c: Ditto.
	* src/fn-logical.c: Ditto.

	* src/cell.h: Fix includes.
448 449 450 451 452 453 454 455 456 457 458 459 460 461

	* src/fn-information.c (gnumeric_isblank): Return boolean.
	(gnumeric_iseven): Ditto.
	(gnumeric_islogical): Ditto.
	(gnumeric_isnontext): Ditto.
	(gnumeric_isnumber): Ditto.
	(gnumeric_isodd): Ditto.
	(gnumeric_isref): Ditto.
	(gnumeric_istext): Ditto.
	(gnumeric_n): Ditto.

	* src/expr.c (value_new_bool): New function.
	(eval_expr): Return boolean Values.

462 463 464
	* src/fn-misc.c (gnumeric_iserr, gnumeric_iserror, gnumeric_isna):
 	Return boolean;

465 466 467 468 469 470
	* src/fn-logical.c (callback_function_and): Simplify.
	(callback_function_or): Ditto.
	(gnumeric_and): Simplify and return boolean Values.
	(gnumeric_not): Ditto.
	(gnumeric_if): Fix error case.  Simplify.

Morten Welinder's avatar
Morten Welinder committed
471 472
	* src/cell.c (cell_comment_destroy): Free realized_list.

Morten Welinder's avatar
Morten Welinder committed
473 474
	* fn-*.c: Use new standard error variables.

Morten Welinder's avatar
Morten Welinder committed
475 476 477 478 479 480 481 482 483
1999-06-12  Jody Goldberg  <jgoldberg@home.com>

	* src/expr.h : Declare new standard error constants to avoid
	spelling problems and typos.
	* src/expr.c, src/func.c, src/fn-math.c : Use and define them.
	* src/fn-misc.c	: First pass at finishing off error functions.
	* src/fn-information.c : Provide stubs for the rest of the
	information functions.

484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507
1999-06-12  Miguel de Icaza  <miguel@gnu.org>

	* src/dialog-cell-comment.c (dialog_cell_comment): Process the
	return value from gnome_dialog_run correctly as well.  (ie we
	should catch the return value -1 as the "user closed dialog box"
 	message and avoid destroying the dialog box ourselves).

	* src/item-grid.c (context_paste_special_cmd): Handle a cancel
	operation from the dialog_paste_special dialog box.

	* src/dialog-paste-special.c (dialog_paste_special): Hanlde the
	case in which the window manager closed the dialog box.

1999-06-10  Miguel de Icaza  <miguel@gnu.org>

	* src/pattern-selector.c (pattern_selector_init): Use the GNOME
	canvas fill_stipple feature instead of using the hack of creating
	the bitmap and setting the stipple on the realize handler.

1999-06-01  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* po/hr.po: Added croat translation from Vladimir Vuksan
	<vuksan@cs.unm.edu>.

508 509 510 511 512 513 514
1999-06-13  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* samples/mathfuns.xls: New test file for math functions.

	* samples/statfuns.xls: Accuracy dropped to 1e-5 (since Excel is
 	not as accurate as Gnumeric).  Also the total number of functions
 	in the test output fixed.
Morten Welinder's avatar
Morten Welinder committed
515

516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997
1999-06-12  Morten Welinder  <terra@diku.dk>

	* src/fn-string.c: Use value_new_string where appropriate.
	(gnumeric_clean): Use unsigned chars.
	(gnumeric_t): Speed improvement.

	* src/file.c (workbook_read): After a workbook has been read, it
 	is to be considered "clean", i.e., unchanged.

	* src/number-match.c (print_regex_error): Add a few missing breaks.

	* src/utils.c (gnumeric_strcase_hash): Use unsigned chars.
	(col_from_name): Ditto.

	* src/format.c (append_year): Ditto.
	(append_month): Ditto.
	(append_hour): Ditto.
	(append_day): Ditto.
	(append_minute): Ditto.
	(append_second): Ditto.
	(pre_parse_format): Ditto.

	* src/number-match.c (format_create_regexp): Ditto.

	* src/fn-string.c (gnumeric_lower): Use g_strdup to match g_free.
	(gnumeric_upper): Ditto.
	(gnumeric_lower): Use unsigned chars.  (This fixes problems with
 	non-English letters.)
	(gnumeric_upper): Ditto.
	(gnumeric_proper): Ditto.  Operate on a _copy_ of the string, not
 	the source string itself!

1999-06-10  Morten Welinder  <terra@diku.dk>

	* src/parser.y (return_cellref): Surprise: isdigit and friends
 	take unsigned chars (effectively).  The results are *undefined*
 	(and weird) for signed chars.
	(yylex): Ditto.

	* src/fn-string.c (gnumeric_proper): Ditto.

	* src/utils.c (parse_cell_name): Ditto.

	* src/sheet-autofill.c (string_has_number): Ditto.
	(autofill_cell): Ditto.

	* src/cell.c (cell_set_text_simple): Ditto.  Also fix long/int
 	confusion.

1999-06-10  James Henstridge  <james@daa.com.au>

	* src/main.c (gnumeric_main): changed call to glade_init() to a call
	to glade_gnome_init(), so that gnome widget building routines get
	initialised correctly.

1999-06-09  Morten Welinder  <terra@diku.dk>

	* src/xml-io.c: Fix major thinko in writing fonts.  (The name hash
 	table was used to look up a font, which always failed since keys
 	are names in that hash.)

1999-06-09  Nat Friedman  <nat@gnome-support.com>

	* src/sheet-view.c (sheet_view_insert_object): Commented out call
 	to gnome_bonobo_object_new_view since the API changed and this
 	function doesn't do anything anyways.

	* src/sheet-object-container.c: Include gnome-component-client.h
 	and view-frame.h.
	(sheet_object_container_land): Pass soc->client_site to
 	gnome_bonobo_object_new_view.  Get the view wrapper widget from
 	the view frame.
	(sheet_object_container_realize): Likewise.

1999-06-09  Morten Welinder  <terra@diku.dk>

	* src/workbook.c (insert_at_cursor): Use cell_set_value instead of
 	cell_set_text.  Constify.  Accept a Value *, not a double.  All
 	callers changed.

1999-06-08  Morten Welinder  <terra@diku.dk>

	* src/fn-date.c (gnumeric_days360): Get it right, I hope.

	* src/xml-io.c (xmlGetDoubleValue): Improve precision.
	(xmlGetCoordinate): Ditto.
	(xmlGetGnomeCanvasPoints): Ditto.

	* src/fn-math.c (gnumeric_fact): s/float/float_t/

	* src/fn-date.c: Fix types of most functions.  (We really need a
 	way of saying "scalar".)
	(get_serial_date): New helper function.
	(get_serial_time): Ditto.
	(gnumeric_hour): Use get_serial_time.
	(gnumeric_minute): Ditto.
	(gnumeric_second): Ditto.
	(gnumeric_year): Use get_serial_date.
	(gnumeric_month): Ditto.
	(gnumeric_day): Ditto.
	(gnumeric_weekday): Ditto.
	(gnumeric_datevalue): Ditto.
	(gnumeric_timevalue): Implement using get_serial_time.
	(gnumeric_days360): Pretty good first cut.

	* src/parser.y (yylex): Allow dots inside a function name.

	* src/fn-misc.c (gnumeric_error_type): New function.

1999-06-08  David Chan <dpc29@hermes.cam.ac.uk>

	* src/fn-math.c (gcd): Correct.

1999-06-08  Morten Welinder  <terra@diku.dk>

	* src/file.c (workbook_read): Temporarily switch to "C" locale
 	when loading and saving.  [Take 2.]
	(workbook_save_as): Ditto.
	(workbook_save): Ditto.

1999-06-21  Morten Welinder  <terra@diku.dk>

	* src/fn-information.c (get_value_class): New function.
	(gnumeric_isnontext): Make non-strict.
	(gnumeric_istext): Make non-strict.
	(gnumeric_type): Make non-strict.
	(gnumeric_islogical): Make non-strict.
	(gnumeric_isnumber): Make non-strict.
	(gnumeric_n): Implement.
	(gnumeric_iseven): Implement.
	(gnumeric_isodd): Ditto.
	(gnumeric_cell): Fix error message.
	(gnumeric_info): Ditto.
	(gnumeric_type): Partly implement.

	* src/fn-math.c (gpow10): Rename from pow10 which colided with
 	something in Linux with libc5.  (Thanks to Alexander Jolk.)

	* src/utils.c (parse_cell_name): Don't use isdigit since we intend
 	to subtract '0' from the character.

	* src/workbook.c (workbook_parse_and_jump): Cleanup.

1999-06-21  Jukka-Pekka Iivonen  <iivonen@iki.fi>

        * samples/infofuns.xls: Added a new file for testing information
        functions.

1999-06-20  Morten Welinder  <terra@diku.dk>

	* src/workbook.c (wb_edit_key_pressed): New function to handle
 	Escape.
	(workbook_setup_edit_area): Activate wb_edit_key_pressed.

	* src/gnumeric-sheet.c (gnumeric_sheet_key_mode_sheet): Call
 	sheet_start_editing_at_cursor for F2.

	* src/sheet.c (sheet_cancel_pending_input): Fix last change.  Also
 	update entry box.
	(sheet_start_editing_at_cursor): New args blankp and cursorp.  All
 	callers changed.

	* src/fn-math.c (gnumeric_mod): Another try.
	(gnumeric_int): Fix for negative numbers.

	* src/sheet.c (sheet_set_text): Set value directly, not via text.  Also
	improve entry when a format is already set.
	(sheet_cancel_pending_input): Fixed behavior of canceling a cell
 	entry.  [From Bake Timmon.]

1999-06-18  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* samples/dbfuns.xls: Added new file for database functions.

	* samples/mathfuns.xls: Added MDETERM test.

	* samples/statfuns.xls: Added AVERAGEA, MINA, MAXA, ... tests.

1999-06-17  Morten Welinder  <terra@diku.dk>

	* src/fn-stat.c (gnumeric_count): Make non-strict and ignore cells
 	with errors.

	* src/fn-logical.c (gnumeric_or, gnumeric_and): Make strict!.

	* src/func.c (IterateCallbackClosure): Add strict member.
	(iterate_cellrange_callback): Handle strict and non-strict case.
	(function_iterate_argument_values): New argument, strict.  All
 	callers changed.  Initialise error_string always.  Handle strict
 	and non-strict case.
	(function_iterate_do_value): New argument, strict.  Handle strict
 	and non-strict case.  All callers changed.

1999-06-18  Michael Meeks  <michael@edenproject.org>

	* src/main.c (gnumeric_main): Add xbase_init

	* src/Makefile.am (gnumeric_LDADD): Add xbase.

	* configure.in (XML_CFLAGS): Added xbase.

	* plugins/Makefile.am (SUBDIRS): Added xbase.

1999-06-17  Morten Welinder  <terra@diku.dk>

	* src/expr.c (eval_expr): Fix error handling of comparisons.

	* src/expr.c (expr_tree_new_constant): New function.
	(expr_tree_new_unary): New function.
	(expr_tree_new_binary): New function.
	(expr_tree_new_funcall): New function.
	(expr_tree_new_var): New function.
	(expr_tree_new_error): Renamed from build_error_string, made
 	public, and simplified.  All callers changed.
	(do_expr_tree_invalidate_references): Simplify.
	(do_expr_tree_fixup_references): Ditto.
	(eval_expr): Simplify.
	(expr_tree_new): Obsolete.

	* src/func.c (constants_init): Simplify.

	* src/main.c (gnumeric_main): Call style_shutdown.

	* src/style.c (style_shutdown): New function.

	* src/expr.h: Avoid using bitfields here.  They are slow and
 	confuse tools like Purify.  And used like this they don't save any
 	space anyway.

	* src/complex.c: Fix includes.

	* src/fn-eng.c (gnumeric_impower): Use new complex_pow.
	(callback_function_imoper): Benefit from new and more intuitive
 	behavoiur of complex_mul and complex_add.

	* src/complex.h (complex_mod): Use hypot for better precision.
	(complex_*): Use complex_init when possible.  (This means that the
 	output can be the same as one of the inputs without any trouble.)
	(complex_pow): New function.

1999-06-17  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-stat.c (gnumeric_percentrank): Interpolation and rounding
	fixes.

1999-06-17  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-eng.c (gnumeric_erf): ERF() changed back to the previous
 	form.  Negative arguments are wrong.

1999-06-16  Morten Welinder  <terra@diku.dk>

	* src/complex.h, src/complex.c: New files.

	* src/fn-eng.c: Use complex.c; improve precision, fix a few bugs,
 	plug a few leaks, add a few functions, and generally be merry.

	* src/Makefile.am (GNUMERIC_BASE_SOURCES): Add complex.c and
 	complex.h.

1999-06-16  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* samples/finfuns.xls: A new file for financial functions.

	* samples/engfuns.xls: A new file for engineering functions.

	* samples/mathfuns.xls: COMBIN and FACT fixed.

	* samples/statfuns.xls: Accuracy dropped again.

1999-06-16  Morten Welinder  <terra@diku.dk>

	* src/workbook.c (workbook_feedback_set): Block the "clicked"
 	handlers when we are just setting the feedback.

1999-06-16  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-math.c (gnumeric_gcd): Made GCD() to take variable number
 	of arguments.

	* src/fn-stat.c (gnumeric_rank): RANK() fixed.

	* src/fn-eng.c (gnumeric_erf): ERF() fixed to return negative
	results if the argument is negative too like in Excel.

	* srg/fn-eng.c (get_real_and_imaginary): Added a branch for empty
 	imaginary part.

	* src/fn-eng.c (gnumeric_improduct, gnumeric_imsum): Made IMSUM()
	and IMPRODUCT() to take variable number of arguments.

1999-06-15  Morten Welinder  <terra@diku.dk>

	* src/style.c (style_font_new_simple): Plug leak.

	* src/cell.c (cell_set_formula_tree_simple): Ref before unref,
 	just in case.

	* src/fn-math.c (callback_function_criteria): Just collect the
 	values, not (incorrectly) allocated pointers to them.
	(gnumeric_countif): Release the values.  (Leak fix.)
	(gnumeric_sumif): Ditto.
	(gnumeric_countif): Plug leak.
	(gnumeric_sumif): Ditto.
	(gnumeric_seriessum): Plug three leaks.
	(gnumeric_subtotal): Plug leaks and fix error handling.

	* src/style.c (style_font_new_simple): Fix memory access problem.

	* src/style.c (font_init): Rework.  (Work in progress.  Things
 	should work ok, but will become even better.)
	(style_font_new_simple): Revert to loading a font, not a fontset.

	* src/gnumeric-util.c (font_get_italic_name): Plug leak and unref
 	the StyleFont.
	(font_get_bold_name, font_get_italic_name): New parameter units.
  	All callers changed.

1999-06-15  Tomas Ogren  <stric@ing.umu.se>

	* configure.in: Added sv

1999-06-14  Morten Welinder  <terra@diku.dk>

	* src/style.c (style_font_new_simple): Add negative caching.
	(DEFAULT_FONT): Don't have a complete wildcard here -- that might
 	be a very weird font.

	* src/cell.c (cell_set_font_from_style): Mark font valid.  Ref
 	before unref.
	(cell_set_format_from_style): Mark format valid.  Ref before
 	unref.

	* src/gnumeric-util.c (font_get_italic_name): Plug leak.
	(font_change_component): Constify.  Handle fontsets.

1999-06-14  Morten Welinder  <terra@diku.dk>

	* src/fn-math.c (gnumeric_floor): Add significance argument.

	* src/fn-math.c (callback_function_seriessum): Simplify.
	(gnumeric_seriessum): Don't round x, n, and m to integers.  Fix
 	error handling.

	* src/fn-math.c (pow10): New function.
	(gnumeric_rounddown): Simplify and correct.
	(gnumeric_round): Ditto.
	(gnumeric_roundup): Ditto.
	(gnumeric_trunc): Ditto.
	(gnumeric_fact): Improve precision.  Extend domain to all positive
 	numbers.
	(gnumeric_factdouble): Use float_t instead of int.
	(gnumeric_atan2): Swap args to atan2.

1999-06-13  Morten Welinder  <terra@diku.dk>

	* src/style.c (DEFAULT_FONT): Add extra font in the hope of curing
 	1207.
	(font_init): Shine up error message and avoid core dump.

	* src/gnumeric-sheet.c (gnumeric_sheet_stop_cell_selection):
 	Temporary patch for refcounts until Miguel can fixup things.
	(destroy_item_editor): Ditto.

	* src/fn-financial.c: s/double/float_t/;
	(calculate_pvif, calculate_pvifa, calculate_fvif, calculate_fvifa,
 	calculate_principal, calculate_pmt): Make static.
	(callback_function_npv): Simplify and truly ignore strings.
	(gnumeric_duration): More error checks.
	(gnumeric_nper): Ditto.
	(gnumeric_syd): Ditto.
	(gnumeric_sln): Ditto.
	(gnumeric_pv): Ditto.
	(gnumeric_fv): Ditto.

	* src/fn-information.c: Prune includes.
	* src/fn-string.c: Ditto.
	* src/fn-sheet.c: Ditto.
	* src/fn-misc.c: Ditto.
	* src/fn-financial.c: Ditto.
	* src/fn-date.c: Ditto.
	* src/fn-database.c: Ditto.
	* src/fn-lookup.c: Ditto.
	* src/fn-stat.c: Ditto.
	* src/fn-math.c: Ditto.
	* src/fn-logical.c: Ditto.

	* src/cell.h: Fix includes.

	* src/fn-information.c (gnumeric_isblank): Return boolean.
	(gnumeric_iseven): Ditto.
	(gnumeric_islogical): Ditto.
	(gnumeric_isnontext): Ditto.
	(gnumeric_isnumber): Ditto.
	(gnumeric_isodd): Ditto.
	(gnumeric_isref): Ditto.
	(gnumeric_istext): Ditto.
	(gnumeric_n): Ditto.

	* src/expr.c (value_new_bool): New function.
	(eval_expr): Return boolean Values.

	* src/fn-misc.c (gnumeric_iserr, gnumeric_iserror, gnumeric_isna):
 	Return boolean;

	* src/fn-logical.c (callback_function_and): Simplify.
	(callback_function_or): Ditto.
	(gnumeric_and): Simplify and return boolean Values.
	(gnumeric_not): Ditto.
	(gnumeric_if): Fix error case.  Simplify.

	* src/cell.c (cell_comment_destroy): Free realized_list.

	* fn-*.c: Use new standard error variables.

1999-06-12  Jody Goldberg  <jgoldberg@home.com>

	* src/expr.h : Declare new standard error constants to avoid
	spelling problems and typos.
	* src/expr.c, src/func.c, src/fn-math.c : Use and define them.
	* src/fn-misc.c	: First pass at finishing off error functions.
	* src/fn-information.c : Provide stubs for the rest of the
	information functions.

1999-06-12  Miguel de Icaza  <miguel@gnu.org>

	* src/dialog-cell-comment.c (dialog_cell_comment): Process the
	return value from gnome_dialog_run correctly as well.  (ie we
	should catch the return value -1 as the "user closed dialog box"
 	message and avoid destroying the dialog box ourselves).

	* src/item-grid.c (context_paste_special_cmd): Handle a cancel
	operation from the dialog_paste_special dialog box.

	* src/dialog-paste-special.c (dialog_paste_special): Hanlde the
	case in which the window manager closed the dialog box.

	* src/cell.c (cell_comment_destroy): Changed invocation from
	gtk_object_destroy to gtk_object_unref.
	(cell_comment_unrealize): ditto.
	(cell_comment_clicked): ditto.
	* src/dialog-cell-sort.c (dialog_cell_sort): ditto.
	* src/dialog-function-select.c (dialog_function_select): ditto
	* src/dialog-function-wizard.c (dialog_function_wizard): ditto
	* src/dialog-paste-special.c (dialog_paste_special): ditto
	* src/dialog-solver.c (constr_add_click): ditto.
	(constr_add_click): ditto
	(dialog_solver_options): ditto
	* src/gnumeric-sheet.c (gnumeric_sheet_stop_cell_selection): ditto
	(destroy_item_editor): ditto.
	(gnumeric_sheet_key_mode_object): ditto, and clear the pointer to
	the current_object.
	* src/sheet-object-container.c (sheet_object_container_destroy): ditto.
	* src/item-cursor.c (item_cursor_drag_event): ditto.
	(item_cursor_autofill_event): ditto
	* src/item-bar.c (item_bar_event): ditto
	* src/workbook.c (workbook_setup_auto_calc): ditto.
	* src/widget-editable-label.c (el_stop_editing): ditto
	* src/sheet-object.c (sheet_object_destroy): ditto
	(sheet_view_object_unrealize): ditto
	(sheet_object_destroy_control_points): ditto
	* src/sheet-view.c (sheet_view_destroy): ditto

1999-06-10  Miguel de Icaza  <miguel@gnu.org>

	* src/pattern-selector.c (pattern_selector_init): Use the GNOME
	canvas fill_stipple feature instead of using the hack of creating
	the bitmap and setting the stipple on the realize handler.

1999-06-01  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* po/hr.po: Added croat translation from Vladimir Vuksan
	<vuksan@cs.unm.edu>.

1999-06-13  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* samples/mathfuns.xls: New test file for math functions.

	* samples/statfuns.xls: Accuracy dropped to 1e-5 (since Excel is
 	not as accurate as Gnumeric).  Also the total number of functions
 	in the test output fixed.
	
998 999
1999-06-12  Morten Welinder  <terra@diku.dk>

1000 1001 1002 1003 1004 1005 1006
	* src/fn-string.c: Use value_new_string where appropriate.
	(gnumeric_clean): Use unsigned chars.
	(gnumeric_t): Speed improvement.

	* src/file.c (workbook_read): After a workbook has been read, it
 	is to be considered "clean", i.e., unchanged.

1007 1008
	* src/number-match.c (print_regex_error): Add a few missing breaks.

1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029
	* src/utils.c (gnumeric_strcase_hash): Use unsigned chars.
	(col_from_name): Ditto.

	* src/format.c (append_year): Ditto.
	(append_month): Ditto.
	(append_hour): Ditto.
	(append_day): Ditto.
	(append_minute): Ditto.
	(append_second): Ditto.
	(pre_parse_format): Ditto.

	* src/number-match.c (format_create_regexp): Ditto.

	* src/fn-string.c (gnumeric_lower): Use g_strdup to match g_free.
	(gnumeric_upper): Ditto.
	(gnumeric_lower): Use unsigned chars.  (This fixes problems with
 	non-English letters.)
	(gnumeric_upper): Ditto.
	(gnumeric_proper): Ditto.  Operate on a _copy_ of the string, not
 	the source string itself!

1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046
1999-06-10  Morten Welinder  <terra@diku.dk>

	* src/parser.y (return_cellref): Surprise: isdigit and friends
 	take unsigned chars (effectively).  The results are *undefined*
 	(and weird) for signed chars.
	(yylex): Ditto.

	* src/fn-string.c (gnumeric_proper): Ditto.

	* src/utils.c (parse_cell_name): Ditto.

	* src/sheet-autofill.c (string_has_number): Ditto.
	(autofill_cell): Ditto.

	* src/cell.c (cell_set_text_simple): Ditto.  Also fix long/int
 	confusion.

1047 1048 1049 1050 1051 1052
1999-06-10  James Henstridge  <james@daa.com.au>

	* src/main.c (gnumeric_main): changed call to glade_init() to a call
	to glade_gnome_init(), so that gnome widget building routines get
	initialised correctly.

1053 1054 1055 1056 1057 1058
1999-06-09  Morten Welinder  <terra@diku.dk>

	* src/xml-io.c: Fix major thinko in writing fonts.  (The name hash
 	table was used to look up a font, which always failed since keys
 	are names in that hash.)

1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071
1999-06-09  Nat Friedman  <nat@gnome-support.com>

	* src/sheet-view.c (sheet_view_insert_object): Commented out call
 	to gnome_bonobo_object_new_view since the API changed and this
 	function doesn't do anything anyways.

	* src/sheet-object-container.c: Include gnome-component-client.h
 	and view-frame.h.
	(sheet_object_container_land): Pass soc->client_site to
 	gnome_bonobo_object_new_view.  Get the view wrapper widget from
 	the view frame.
	(sheet_object_container_realize): Likewise.

Morten Welinder's avatar
Morten Welinder committed
1072 1073 1074 1075 1076 1077
1999-06-09  Morten Welinder  <terra@diku.dk>

	* src/workbook.c (insert_at_cursor): Use cell_set_value instead of
 	cell_set_text.  Constify.  Accept a Value *, not a double.  All
 	callers changed.

Morten Welinder's avatar
Morten Welinder committed
1078 1079
1999-06-08  Morten Welinder  <terra@diku.dk>

1080 1081
	* src/fn-date.c (gnumeric_days360): Get it right, I hope.

1082 1083 1084 1085 1086 1087
	* src/xml-io.c (xmlGetDoubleValue): Improve precision.
	(xmlGetCoordinate): Ditto.
	(xmlGetGnomeCanvasPoints): Ditto.

	* src/fn-math.c (gnumeric_fact): s/float/float_t/

Morten Welinder's avatar
Morten Welinder committed
1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106
	* src/fn-date.c: Fix types of most functions.  (We really need a
 	way of saying "scalar".)
	(get_serial_date): New helper function.
	(get_serial_time): Ditto.
	(gnumeric_hour): Use get_serial_time.
	(gnumeric_minute): Ditto.
	(gnumeric_second): Ditto.
	(gnumeric_year): Use get_serial_date.
	(gnumeric_month): Ditto.
	(gnumeric_day): Ditto.
	(gnumeric_weekday): Ditto.
	(gnumeric_datevalue): Ditto.
	(gnumeric_timevalue): Implement using get_serial_time.
	(gnumeric_days360): Pretty good first cut.

	* src/parser.y (yylex): Allow dots inside a function name.

	* src/fn-misc.c (gnumeric_error_type): New function.

Morten Welinder's avatar
Morten Welinder committed
1107 1108 1109 1110
1999-06-08  David Chan <dpc29@hermes.cam.ac.uk>

	* src/fn-math.c (gcd): Correct.

1111 1112 1113 1114 1115 1116 1117
1999-06-08  Morten Welinder  <terra@diku.dk>

	* src/file.c (workbook_read): Temporarily switch to "C" locale
 	when loading and saving.  [Take 2.]
	(workbook_save_as): Ditto.
	(workbook_save): Ditto.

1118 1119 1120 1121 1122
1999-06-06  Michael Meeks  <michael@edenproject.org>

	* src/expr.c (value_area_get_at_x_y): Add vital check for
	forthcoming name stuff.

Morten Welinder's avatar
Morten Welinder committed
1123 1124 1125 1126 1127 1128 1129 1130 1131 1132
1999-06-03  Morten Welinder  <terra@diku.dk>

	* src/item-bar.c (item_bar_event): Handle zoom.
	(item_bar_get_line_points): Handle zoom.
	(item_bar_start_resize): Handle zoom better.
	(get_col_name): Delete.  Use col_name instead.
	(bar_draw_cell): Constify.

	* src/item-bar.h (ItemBar): Delete member resize_guide_offset.

1133 1134
1999-06-02  Morten Welinder  <terra@diku.dk>

Morten Welinder's avatar
Morten Welinder committed
1135 1136
	* src/fn-date.c (gnumeric_days360): New (unimplemented) function.

Morten Welinder's avatar
Morten Welinder committed
1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148
	* src/fn-date.c (gnumeric_year_month_day): Delete.
	(gnumeric_day, gnumeric_month, gnumeric_year): New functions.
	(gnumeric_hour_min_sec): Delete.
	(gnumeric_hour, gnumeric_minute, gnumeric_second): New functions.
	(gnumeric_weekday): New function.
	(gnumeric_date): Handle two-digit years.  Check this, please.
	(gnumeric_timevalue): New function.  (Untested -- Excel plugin
 	does not handle it yet.)

	* src/utils.c (g_date_serial): Deal with 19000229.
	(g_date_new_serial): Ditto.

1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176
	* samples/datefuns.xls: New file from Nick Lamb.

	* src/eval.c (workbook_recalc): If a cell has already been
 	computed, do not redo it.  This should speed up things.
	(cell_queue_recalc): Delete useless cast.
	(cell_unqueue_from_recalc): Ditto.
	(cell_queue_recalc_list): Ditto.
	(cell_queue_recalc_list): Extra parameter freelist controls
 	whether list is freed.  All callers changed.
	(workbook_recalc_all): Use cell_queue_recalc_list.

	* src/dialog-goal-seek.c (goal_seek_eval): Properly reevaluate.

	* src/expr.c (eval_expr): Only evaluate references cells when they
 	are queued for recalculation.

	* src/func.c (iterate_cellrange_callback): Ditto.

	* src/fn-math.c (gnumeric_lcm): Remove useless (Sheet *) cast.

	* src/fn-information.c (gnumeric_countblank): Ditto.

	* src/fn-database.c (find_column_of_field): Ditto.
	(parse_database_criteria): Ditto.
	(find_cells_that_match): Ditto.

	* src/cell.c (cell_comment_realize): Ditto.

1177 1178 1179 1180
1999-06-02  Michael Meeks  <michael@edenproject.org>

	* src/expr.c (do_expr_decode_tree): Added ARRAY support.

Morten Welinder's avatar
Morten Welinder committed
1181 1182 1183 1184 1185 1186 1187 1188 1189
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.

1190 1191 1192 1193 1194
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.
1195

1196
	* src/style.c: Change the default font names.
1197

1198 1199 1200 1201
	* src/workbook.c: Add gtk_widget_ensure_style() call, which is
	necessary to knowing if a fontset is supplied for the label
	widget.

1202 1203 1204 1205 1206 1207
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.

1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241
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.

1242 1243
1999-06-01  Miguel de Icaza  <miguel@nuclecu.unam.mx>

1244
	* src/file.c (dialog_query_load_file):
1245 1246 1247
	(workbook_save_as): Prettify these.  Thanks to Andrew for pointing
	this out.

1248 1249 1250 1251
1999-06-01  Morten Welinder  <terra@diku.dk>

	* src/fn-stat.c (gnumeric_kurt): Fix crashes and leaks.

1252 1253 1254 1255 1256
1999-06-01  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-string.c: Added SEARCH().  Quite a complex beast but
 	should work completely.

1257 1258 1259 1260 1261 1262 1263 1264
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.)

1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275
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.

1276 1277 1278 1279
1999-05-31  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-lookup.c: Added ADDRESS().  Cleaned up too long lines.

Morten Welinder's avatar
Morten Welinder committed
1280 1281 1282 1283 1284 1285 1286 1287 1288 1289
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.

Morten Welinder's avatar
Morten Welinder committed
1290 1291 1292 1293 1294
1999-05-27  Morten Welinder  <terra@diku.dk>

	* src/expr.c (value_get_as_string): Improve precision -- this
 	impacts the results of saves.

1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317
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.

1318 1319 1320 1321 1322 1323 1324 1325 1326
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.

1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343
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.

1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357
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.

1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384
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.

Morten Welinder's avatar
Morten Welinder committed
1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405
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.

1406 1407 1408 1409 1410 1411 1412 1413
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).
1414

1415 1416 1417 1418
	* src/dialog-insert-cells.c (dialog_insert_cells): ditto.

	* src/dialog-delete-cells.c (dialog_delete_cells): ditto.

1419 1420 1421 1422 1423 1424 1425 1426
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.

1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442
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.

1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454
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.

1455 1456 1457 1458 1459
1999-05-22  Morten Welinder  <terra@diku.dk>

	* src/fn-financial.c (gnumeric_pv): Revert last chance.  (Bogosity
 	is in me.)

1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576
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.

Morten Welinder's avatar
Morten Welinder committed
1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598
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.

1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623
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.

1624 1625 1626 1627 1628 1629
1999-05-21  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-stat.c: PERCENTRANK() added.

	* src/func.[ch]: function_iterate_do_value made public.

Morten Welinder's avatar
Morten Welinder committed
1630 1631 1632 1633 1634
1999-05-21  Morten Welinder  <terra@diku.dk>

	* configure.in: use AC_CHECK_HEADERS, not AC_CHECK_HEADER for the
 	benefit of autoheader.

1635 1636 1637 1638 1639 1640 1641
1999-05-19  Michael Meeks  <michael@imaginator.com>

	* src/fn-stat.c: Added 'static' to new non-global functions.

	* src/cell.c (cell_set_formula_tree_simple): Added
	missing sheet_cell_formula_unlink.

1642 1643
1999-05-19  Jukka-Pekka Iivonen  <iivonen@iki.fi>

jpekka's avatar
jpekka committed
1644
	* src/fn-math.c: SERIESSUM(), SUBTOTAL() and SUMA() added.
1645 1646 1647

	* src/fn-stat.c: SLOPE(), AVERAGEA(), MAXA(), MINA(), STDEVA(),
 	STDEVPA(), VARA(), and VARPA() added.
1648

1649 1650 1651 1652
	* src/fn-stat.c (gnumeric_counta, gnumeric_min, gnumeric_max,
 	gnumeric_stdev, gnumeric_stdevp, gnumeric_var, gnumeric_varp):
 	made public (used also in src/fn-math.c for now on).

Michael Meeks's avatar
Michael Meeks committed
1653 1654 1655 1656
1999-05-19  Michael Meeks  <michael@imaginator.com>

	* CHANGES: copied to web and blanked.

1657 1658 1659 1660 1661
1999-05-18  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/corba-args.c (gnumeric_arg_parse): Initialize as a server.
	Thanks to Elliot for fixing this one.

1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685
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.

1686 1687 1688 1689 1690
1999-05-16  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/corba-workbook.c (Workbook_corba_class_init): Make it work
	with the new bonobo.

1691 1692 1693 1694 1695 1696
1999-05-16  Raja R Harinath  <harinath@cs.umn.edu>

	* src/Gnumeric.idl: Revert the following checkin:
	1999-05-13  Kjartan Maraas  <kmaraas@online.no>.
	`gnome-object.idl' is part of `bonobo'.

1697 1698
1999-05-16  Morten Welinder  <terra@diku.dk>

1699 1700 1701 1702 1703 1704 1705 1706
	* src/expr.c (do_expr_tree_relocate): Change to use lazy copying
 	scheme -- this should improve sharing.  (Until someone saves and
	reloads, of course.  More about that at a later time.)
	(expr_tree_invalidate_references): Quiet.
	(expr_tree_fixup_references): Quiet.

	* src/cell.c (cell_relocate): Only update if changed.

1707 1708 1709 1710 1711 1712 1713 1714 1715
	* src/expr.c (evaluate_level): Deleted.
	(bigger_prec): Deleted.
	(do_expr_decode_tree): Handle left/right associativity.

	* src/cell.c (cell_set_text_simple): Simplify value parsing.

	* src/dialog-goal-seek.c (test_cell_with_value): Cast to double,
 	not float.

1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727
1999-05-16  Michael Meeks  <michael@imaginator.com>

	* src/workbook.c (cb_assemble_selection): Add 'char *sel'
	and change "," -> ','
	(workbook_selection_to_string): Add 'char *result'
	Fix incorrect pointer dereference.

	* src/sheet.c (reference_append): Fix appended strings to
	characters.
	(sheet_selection_to_string): Add missing GList pointer
	'selections'. Changes ":" -> ':', rename res to 'info->result'

1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739
1999-05-15  Heath Martin <martinh@pegasus.cc.ucf.edu>

	* src/gnumeric-sheet.c (gnumeric_sheet_compute_visible_ranges):
	Small cut and paste fix.  Use row here instead of col.

1999-05-13  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* configure.in (ALL_LINGUAS): Added slovak language.

1999-05-09  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/sheet.c (sheet_selection_to_string): New routine.  Returns a
1740
	string representation of the current selection.
1741 1742 1743 1744 1745 1746 1747 1748

	* src/workbook.c (workbook_selection_to_string): New routine.
	Retunrs a string representation of the current selection.

1999-05-08  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/corba-workbook.c (corba_sheet): Fix.

1749 1750 1751 1752 1753
1999-05-16  Michael Meeks  <michael@imaginator.com>

	* CHANGES: Added to ease burdern of creating accurate descriptions
	between versions.

1754 1755 1756 1757 1758 1759
1999-05-15  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* samples/statfuns.xls: Added a new file.  It can be used for
 	regression testing.  It is in Excel format so it tests the Excel
 	plugin's functionality in the same time too.

1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772
1999-05-15  Michael Meeks  <michael@imaginator.com>

	* src/file.c (file_format_register_save): Changed to append
	new types; works round bug in selection.

	* src/expr.c (eval_cell_value): Fix sillyness of top left
	corner stuff.

	* src/expr.h: Added const to value_dump

	* src/parser.y (value_dump): Fixed array problem.
	Added const to parameter.

1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791
1999-05-15  Michael Meeks  <michael@imaginator.com>

	* src/parser.c (value_dump): Updated Arrays, to use Value *

	* src/func.c (function_iterate_do_value): same.

	* src/fn-sheet.c (gnumeric_selection): same.

	* src/eval.c (add_value_deps): same.

	* src/expr.c (value_get_as_string): Major re-work of ARRAY
	conversion.
	(value_array_set): Fix rather embarassing bug in assertions.
	(eval_cell_value): Return top left corner of array, seems to be
	what excel does.
	(value_release, value_array_set, value_array_new),
	(value_array_copy_to, value_array_resize):
	Updated value->v.array to Value *'s saves much hassle !

1792 1793
1999-05-14  Michael Meeks  <michael@imaginator.com>

1794
	* src/expr.c (value_area_get_width, value_area_get_height):
1795 1796 1797 1798 1799 1800 1801 1802
	Clip to sheet bounds if CELLRANGE: Massive speedup on some
	lookups.

	* src/expr.h: Added value_zero

	* src/func.c (constants_init): Added a 'value_zero' constant
	to kill leak in out-of-range / NULL cell cases in value_get_at_x_y

Jukka-Pekka Iivonen's avatar
Jukka-Pekka Iivonen committed
1803 1804 1805
1999-05-14  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-math.c: Added LCM().
1806

Kjartan Maraas's avatar
Kjartan Maraas committed
1807 1808 1809 1810
1999-05-13  Kjartan Maraas  <kmaraas@online.no>

	* src/Gnumeric.idl: s/#include <gnome-object.idl>/
	  #include <GnomeObject.idl>, to make it compile.
1811

1812 1813 1814 1815 1816
1999-05-13  Michael Meeks  <michael@imaginator.com>

	* src/Gnumeric-impl.c: Fixes killing this file by
	mistake.

1817 1818 1819 1820
1999-05-13  Michael Meeks  <michael@imaginator.com>

	* src/expr.h: Updated all prototypes.

1821
	* *.c:
1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832
	s/\<value_float *(/value_new_float (/g
	s/\<value_int *(/value_new_int (/g
	s/\<value_str *(/value_new_string (/g
	s/\<value_string *(/value_get_as_string (/g
	s/\<value_cellrange *(/value_new_cellrange (/g
	s/\<value_get_as_double *(/value_get_as_float (/g
	s/\<value_get_bool *(/value_get_as_bool (/g

	* src/expr.c: Moved all pertainant Value functions to the
	same place to aid possible splitting.

Michael Meeks's avatar
Michael Meeks committed
1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846
1999-05-13  Michael Meeks  <michael@imaginator.com>

	* src/expr.c (value_area_get_at_x_y): Added warning
	in safety case.

	* src/fn-lookup.c (gnumeric_lookup): Implemented.

	* src/func.h: Updated critera_test_fun_t: returns int,
	should really be gboolean ?

	* src/expr.h: Added prototype & indentation beautified.

	* src/expr.c (value_array_set): Helper function added.

Jukka-Pekka Iivonen's avatar
Jukka-Pekka Iivonen committed
1847 1848 1849 1850
1999-05-13  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-math.c: Added GCD().

1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865
1999-05-12  Michael Meeks  <michael@imaginator.com>

	* src/workbook.c (workbook_setup_edit_area): Added dependancy
	debugging button for --debug=10 and fixed memory leak.
	(deps_output): Dumps dependency data to stdout.

	* src/gnumeric-util.c (range_contains): Re-order compares
	to catch single cell ranges more quickly.

	* src/eval.c (intersects): Change order of sheet / range check
	for speed.
	(search_cell_deps): Added comment.

	* src/eval.h: Cosmetic typo. fix shet -> sheet

1866 1867 1868 1869 1870 1871 1872 1873
1999-05-12  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-database.c: Database functions accept now string
 	criterias too.  In addition, the parsing of criterias and the test
 	functions are now public (src/fn-math.c uses these for now on).

	* src/func.h: Added type definitions and function prototypes for
 	internal functions that parse and test criterias.
1874

1875 1876 1877 1878 1879 1880
	* src/fn-math.c: Added LN().  Changed LOG() to take an optional
 	second parameter.  LOG() returns the logarithm in base 10 if the
 	optional argument is not given, otherwise it returns the logarithm
 	in the given base.

	* src/fn-math.c: Added COUNTIF() and SUMIF().
1881

1882
	* src/fn-eng.c: Added IMLOG10() and IMLOG2().
1883

1884 1885 1886
	* src/fn-eng.c (complex_ln): Fixed a bug.  Imaginary coefficient
	was calculated incorrectly.

1887 1888 1889 1890 1891 1892
1999-05-11  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-eng.c: Added CONVERT().  All translations should work.
  	Also get_real_and_imaginary() fixed (complex numbers should now
 	work completely).

Michael Meeks's avatar
Michael Meeks committed
1893 1894 1895 1896 1897 1898
1999-05-10  Michael Meeks  <michael@imaginator.com>

	* src/sheet.h: Added workbook_focus_sheet.

	* src/workbook.c (workbook_focus_sheet): Added.

1899 1900 1901 1902 1903 1904
1999-05-10  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-eng.c: Added IMARGUMENT(), IMCONJUGATE(), IMCOS(),
 	IMDIV(), IMEXP(), IMLN(), IMPOWER(), IMPRODUCT(), IMSIN(),
 	IMSQRT(), IMSUB(), and IMSUM().

1905 1906 1907 1908 1909 1910
1999-05-08  Michael Meeks  <michael@imaginator.com>

	* web/index.html: Fix sillyness in references.

	* web/gnumeric-0.25: Remove HTML tags...

1911 1912
1999-05-08  Michael Meeks  <michael@imaginator.com>

1913 1914 1915 1916
	* src/Makefile.am (gnumeric_LDADD): Added libole2 library.

	* configure.in (XML_CFLAGS): Updated to add excel/libole2

1917 1918 1919
	* src/sheet.h: Commented sheet_cell_get vs. _fetch.

	* src/expr.c (do_expr_tree_unref, value_string, value_release),
1920
	(eval_cell_value, do_expr_tree_invalidate_references):
1921 1922 1923 1924
	Clean: Added 'default' cases with warnings.
	(value_get_as_double, value_get_as_int, value_get_bool): Changed
	to safer / faster switch statement from if.

1925 1926 1927 1928 1929 1930 1931 1932 1933
1999-05-07  Michael Meeks  <michael@imaginator.com>

	* src/corba-workbook.c (corba_sheet): Add CORBA_Environment
	parameter, needed for Object_dupicate...
	(Workbook_sheet_new, Workbook_sheet_lookup),
	(Workbook_sheet_current): Updated corba_sheet's args.

	* src/fn-lookup.c: Fixed choose help.

1934 1935 1936 1937 1938
1999-05-06  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/corba-workbook.c (corba_sheet): Duplicate the object before
	returning to ORBit.

1939 1940 1941 1942 1943
1999-05-07  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-eng.c: Added COMPLEX(), IMABS(), IMAGINARY(), IMREAL().
  	Also added an internal function get_real_and_imaginary() which
 	still needs to be improved.
1944

1945 1946 1947
	* src/fn-math.c: Added MROUND() and ROMAN().  ROMAN() currently
 	supports only type 0 (classic).

1948 1949 1950 1951 1952 1953
1999-05-07  Heath Martin  <martinh@pegasus.cc.ucf.edu>

	* src/expr.c (expr_tree_invalidate_references): Add extra argument
 	for the sheet we are changing.  All callers changed.
	(expr_tree_fixup_references): Ditto.

Morten Welinder's avatar
Morten Welinder committed
1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978
1999-05-06  Morten Welinder  <terra@diku.dk>

	* src/eval.c (cell_queue_recalc): Don't re-queue cell.
	(cell_queue_recalc_list): Don't re-queue cells.  (Because it is
 	wasteful and because unqueue then won't work right.)

	* src/fn-lookup.c (gnumeric_column): Fix leak.
	(gnumeric_row): Fix leak.
	(gnumeric_choose): Fix leak.
	(lookup_similar): Fix leaks.

	* src/xml-io.c (xml_probe): Fix leak.
	(xmlGetValue): Fix *HUGE* leak.
	(readXmlStyle): Fix leaks.
	(readXmlSheet): Fix leaks.
	(createXmlSheet): Fix leak.
	(readXmlCell): Move the freeze, just in case.

	* src/fn-lookup.c (gnumeric_choose): Remove (incorrect) arg check.

	* src/cell.c (cell_copy): Properly handle render_color member.
  	Clear the CELL_QUEUED_FOR_RECALC flag.
	(cell_destroy): Add code to make it painfully clear when members
 	of freed cells are accessed.

1979 1980
1999-05-06  Michael Meeks  <michael@imaginator.com>

Michael Meeks's avatar
Michael Meeks committed
1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991
	* src/cell.h: Added deep freeze prototypes.

	* src/cell.c (cell_deep_freeze_redraws): Added
	(cell_deep_thaw_redraws): Added,
	(cell_queue_redraw): Updated to use deep_freeze
	effectively ignore redraw requests.

	* src/xml-io.c (readXmlCell): Added deep freeze/thaw
	redraws for clean and easy speedup.

1999-05-06  Michael Meeks  <michael@imaginator.com>
1992

1993 1994 1995 1996
	* src/workbook.c: Moved 'Sort' to the tools menu.

	* HACKING: Pedantic clean.

Jukka-Pekka Iivonen's avatar
Jukka-Pekka Iivonen committed
1997 1998
1999-05-06  Jukka-Pekka Iivonen  <iivonen@iki.fi>

Jukka-Pekka Iivonen's avatar
Jukka-Pekka Iivonen committed
1999 2000 2001
	* src/fn-date.c: Added EDATE().

1999-05-06  Jukka-Pekka Iivonen  <iivonen@iki.fi>
2002

Jukka-Pekka Iivonen's avatar
Jukka-Pekka Iivonen committed
2003
	* src/fn-date.c: Added DATEVALUE().
2004

2005 2006 2007 2008
1999-05-05  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-database.c (parse_criteria): If a condition contains
	just a number, it is an equality condition.
2009

2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026
1999-05-05  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* configure.in: Laptop does not have resources.  Make guile
	optional until at least.

	* src: Now we only support two modes: Gnumeric and
	Gnumeric-Bonobo.  The later includes all of the CORBA support,
	there is no longer a non-Bonobo CORBA version.

	* src/corba-workbook.c, src/corba-sheet.c, src/workbook-factory.c:
	New files that support the Gnumeric CORBA interfaces.

1999-05-02  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/corba-workbook.c (WorkbookFactory_init): Add workbook
	factory servant initialization.

2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039
1999-05-04  Morten Welinder  <terra@diku.dk>

	* src/eval.c (dependency_remove_cell): Remove unused assignment.
	(cell_queue_recalc_list): Mark queued cells as being so.

	* src/fn-math.c (gnumeric_combin): Clean up.
	(combin): Handle large numbers carefully.

	* src/utils.c (january_1900): Fix argument list.

	* src/fn-stat.c (gnumeric_var): Remove unused variable.
	(gnumeric_varp): Ditto.

Jukka-Pekka Iivonen's avatar
Jukka-Pekka Iivonen committed
2040 2041 2042
1999-05-04  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-math: Added ROUND().
2043

Jukka-Pekka Iivonen's avatar
Jukka-Pekka Iivonen committed
2044 2045 2046 2047
	* src/fn-information: Added new file for information functions.
	New function COUNTBLANK() implemented.

	* src/Makefile.am, src/func.[ch]: Added `fn-information.c'.
2048

Jukka-Pekka Iivonen's avatar
Jukka-Pekka Iivonen committed
2049 2050 2051 2052 2053 2054 2055
1999-05-04  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-database.c: Added DCOUNTA().

	* src/fn-stat.c: Added argument count checks for VAR() and VARP().
	Added STEYX().

Morten Welinder's avatar
Morten Welinder committed
2056 2057
1999-05-03  Morten Welinder  <terra@diku.dk>

Morten Welinder's avatar
Morten Welinder committed
2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068
	* src/format.c (split_time): Fix leak.

	* src/parser.y (forget): Fix leak.

	* src/expr.c (do_expr_tree_ref): Delete.
	(expr_tree_ref): Just increase the ref-count.
	(do_expr_tree_unref): Properly decrease all the way.
	(expr_tree_new): Fix prototype.
	(value_release): Add "break".
	(value_cellrange): Make args const.  Don't use memcpy call.

Morten Welinder's avatar
Morten Welinder committed
2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094
	* src/parser.y (v_new): Fix type.
	(alloc_register): Ditto.
	(dump_tree): Fix reference to variable cell.

	* src/file.c (file_format_unregister_save): Fix leak.
	(file_format_unregister_open): Fix leak.

	* src/parser.y (forget): Fix leak.

	* src/eval.c (add_tree_deps): Use OPER_ANY_BINARY.
	(add_value_deps): Delete unused variable.
	(dependency_remove_cell): Fix leak.

	* src/sheet.c (sheet_destroy_styles): Leak fix.  Late night
 	coding?  :-)
	(sheet_shift_row): Ditto.

	* src/parser.y (alloc_clean): Ditto.
	(alloc_list_free): Ditto.

	* src/main.c (gnumeric_main): Get rid of memory leak debug code
 	(handled by other means now).

	* src/cell.c (cell_set_value): Remove "const".
	(cell_set_value_simple): Ditto.

2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105
1999-05-03  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-database.c: New file added for database
 	functions. Implemented DAVERAGE(), DCOUNT(), DGET(), DMAX(),
 	DMIN(), DPRODUCT(), DSTDEV(), DSTDEVP(), DSUM(), DVAR(), and
 	DVARP().

	* src/func.c: Added registeration of database functions.

	* src/fn-stat.c, src/func.h: callback_function_stat made public.

2106 2107 2108 2109 2110 2111
1999-05-02  Michael Meeks  <michael@imaginator.com>

	* src/expr.h: Spelling fix 'substract' :-)

	* src/expr.c (expr_tree_new): Added for convenience.

Michael Meeks's avatar
Michael Meeks committed
2112 2113 2114 2115 2116 2117 2118
1999-05-02  Michael Meeks  <michael@imaginator.com>

	* src/cell.c (cell_set_value): Created.
	(cell_set_value_simple): Created.

	* src/cell.h: Added headers

2119 2120 2121 2122 2123 2124 2125
1999-05-01  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/corba-workbook.c, src/corba-sheet.c: New files implementing
	most of the new Gnumeric.idl interface.

	* src/Gnumeric.idl: Make it useful.

2126 2127
1999-04-30  Morten Welinder  <terra@diku.dk>

2128 2129 2130 2131 2132 2133
	* src/*.h: Properly forward-declare structures.  Include
 	dependencies.  Change the occasional "void *" to its right
	type.

	* src/*.[cy]: Include more dependencies.

2134 2135
	* src/sheet.c (sheet_delete_row): Remove from workbook hash also.

2136 2137
1999-04-29  Morten Welinder  <terra@diku.dk>

2138 2139 2140 2141 2142
	* src/expr.c (expr_tree_fixup_references): Implement.

	* src/sheet.c (sheet_delete_row, sheet_delete_col): Fixup
 	references.

2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156
	* src/expr.c (do_expr_tree_relocate): Remove strange and incorrect
 	refcount fiddling.

	* src/workbook.c (workbook_fixup_references,
 	workbook_invalidate_references): Fix cell walking.

	* src/expr.c (do_expr_decode_tree): rename binary_operation_names
	to operation_names and fill in the rest.

	* src/fn-misc.c (gnumeric_error): New function.

	* src/expr.c (value_str): Constify.
	(expr_tree_invalidate_references): Mostly implement.

Morten Welinder's avatar
Morten Welinder committed
2157 2158 2159
	* src/fn-math.c (gnumeric_multinomial, gnumeric_product,
 	gnumeric_sumsq): Fix type.

2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232
	* src/expr.h (OPER_ANY_BINARY, OPER_ANY_UNARY): new convenience
 	macros.
	(struct _Sheet): declare forward reference so we can use the right
 	types.
	(CellRef, FunctionDefinition, expr_parse_string, expr_decode_tree,
 	eval_expr): use "struct _Sheet *".

	* src/workbook.c (workbook_do_destroy): Carefully clean workbook
 	before deleting sheets.  Do things in the standard way.  Get rid
 	of clipboard leak.
	(insert_cols_cmd): Fix name string.
	(workbook_detach_sheet): New parameter "force".  All callers
 	changed.
	(workbook_fixup_references, workbook_invalidate_references,
 	workbook_sheets): New functions.

	* src/sheet.c (sheet_verify_selection_simple): Mark strings for
 	translation.
	(sheet_insert_col): Fixup references to moved cells.
	(sheet_delete_col, sheet_delete_row): Invalidate references to
 	deleted cells.

	* src/sheet-autofill.c (fill_item_new): Fix copying of cell with
	error.

	* src/parser.y (yylex): "const" fixes.
	(gnumeric_expr_parser): New function (to fix memory corruption and
 	leaks).

	* src/fn-stat.c (i1mach): Make static.
	(gnumeric_var, gnumeric_varp, gnumeric_stdev, gnumeric_stdevp,
 	gnumeric_rank, gnumeric_trimmean, gnumeric_covar, gnumeric_correl,
 	gnumeric_mode, gnumeric_harmean, gnumeric_geomean, gnumeric_count,
 	gnumeric_counta, gnumeric_average, gnumeric_min, gnumeric_max,
 	gnumeric_skew, gnumeric_kurt, gnumeric_avedev, gnumeric_devsq,
 	gnumeric_pearson, gnumeric_rsq, gnumeric_median, gnumeric_large,
 	gnumeric_small, gnumeric_ztest): Fix type.

	* src/fn-math.c (gnumeric_fact, gnumeric_combin): Mark strings for
 	translation.
	(gnumeric_sum, gnumeric_trunc): Fix type.

	* src/fn-lookup.c (gnumeric_choose, gnumeric_column,
 	gnumeric_row): Fix type.

	* src/fn-misc.c (gnumeric_iserror): Fix type.

	* src/fn-sheet.c (gnumeric_selection): Fix type.

	* src/fn-string.c (gnumeric_concatenate): Fix type.

	* src/fn-logical.c (gnumeric_and, gnumeric_not, gnumeric_or,
 	gnumeric_if): Fix type.

	* src/fn-financial.c (gnumeric_npv): Fix type.

	* src/expr.c (expr_parse_string): Move in part to parser.y.
  	Delete global variables to communicate.
	(do_expr_tree_ref, do_expr_tree_unref, do_expr_decode_tree,
 	do_expr_tree_relocate): use OPER_ANY_BINARY and OPER_ANY_UNARY.
	(function_call_with_values): Mark strings for translation.
	(eval_expr, do_expr_decode_tree, expr_decode_tree): Fix type to
 	use "Sheet *" instead of "void *".
	(do_expr_decode_tree): Free sum.
	(expr_tree_invalidate_references, expr_tree_fixup_references): New
 	functions.  Not implemented yet.

	* src/cell.c (cell_set_formula): "const" fix.
	(cell_copy): Ref entered_string also if it exists.
	(cell_relocate): Unlink cell from workbook list of cells.

	* src/about.c (dialog_about): Add myself.  Update copyright.

2233 2234
1999-04-29  Jukka-Pekka Iivonen  <iivonen@iki.fi>

2235 2236
	* src/fn-{math,sheet,logical}.c, src/func.[ch]: Moved logical
 	functions into a new file.
2237

2238 2239
	* src/fn-math.c: Added ROUNDDOWN(), ROUNDUP(), SUMX2MY2(),
 	SUMX2PY2(), and SUMXMY2().
2240

2241
	* src/fn-stat.c: Added PROB(). CONFIDENCE() should now work fully.
2242

2243 2244 2245 2246 2247 2248 2249
1999-04-28  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-stat.c: Added COUNTA(), FINV(), and TINV().

	* src/fn-stat.c, src/fn-math.c: AVERAGE(), COUNT(), MAX(), and
	MIN() moved from fn-math.c to fn-stat.c.  They are in the
	statistical function group in Excel.
2250

2251 2252 2253 2254
1999-04-27  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-stat.c: Added BETADIST(), FDIST(), and TDIST().

2255 2256 2257 2258 2259 2260
1999-04-26  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/eval.c (intersects): Typo fix.  Sheet was being assigned
	instead of being tested for equality.  This got Michael to crash
	Gnumeric (as there was no test for can_remove)

jpekka's avatar
jpekka committed
2261 2262 2263 2264
1999-04-26  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-stat.c: Added CHIDIST(), CHIINV(), and GAMMAINV().

2265 2266 2267 2268 2269 2270 2271 2272 2273 2274
Sat Apr 24 14:39:32 1999  Morten Welinder  <terra@diku.dk>

	* src/sheet.c (sheet_selection_reset_only): Remove useless
 	initialisation.  Don't free individual selections here.

	(sheet_selections_free): Walk the list of selections and free each
 	one.

	(sheet_get_selection_name): Calculate buffer size based on the
 	size of an int.
2275

2276 2277 2278 2279 2280 2281
	* src/fn-eng.c: Remove sqrtpi function -- it's already in fn-math.c

	* src/fn-math.c (gnumeric_sqrtpi): Add range check.

	* src/symbol.c (symbol_install): Add sanity check.

2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292
Fri Apr 23 17:52:44 1999  Morten Welinder  <terra@diku.dk>

	* src/sheet.c (sheet_destroy): Don't check that workbook is
	NULL because it cb_sheet_do_destroy will call it non-NULL.

	* src/workbook.c (cb_sheet_do_destroy): Don't NULL workbook
	member as it will be used.

	* src/format.c (render_number): Fix rounding up.

	* src/*.[chy]: add tons on "const"s.
2293

jpekka's avatar
jpekka committed
2294 2295 2296 2297 2298 2299
1999-04-23  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/fn-stat.c: Added GAMMADIST() function.  It uses pgamma()
 	function written by Ross Ihaka.  Thanks to Morten for pointing
 	this piece of code.

2300 2301 2302
1999-04-21  Morten Welinder  <terra@diku.dk>

	* src/workbook.c (workbook_do_destroy): Release the sheets and the
2303
	hash table that held the references to the sheets.
2304 2305

	* src/func.c: warning fix.
2306

2307 2308 2309 2310 2311 2312 2313
1999-04-21  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/widget-editable-label.c (el_button_press_event): Add type
	cast to kill warning.

	* src/format.c: Include ieeefp.h if required.

2314 2315 2316 2317 2318
1999-04-19  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/fn-string.c: Close parentheses in help_stubstitute function
	descritpion.   Thanks to Aldy Hernandez for pointing this out.

jpekka's avatar
jpekka committed
2319 2320 2321 2322 2323
1999-04-19  Jukka-Pekka Iivonen  <iivonen@iki.fi>

	* src/dialog-goal-seek.c: Goal seek tool implemented.  Goal seek
 	should now find a solution for all linear problems (if there is
 	one).  A simple non-linear search algorithm also implemented.
jpekka's avatar
jpekka committed
2324 2325

	* src/workbook.c: Made 'Goal seek' menu entry visible.
jpekka's avatar
jpekka committed
2326

jpekka's avatar
jpekka committed
2327 2328
	* src/fn-math.c: Added MULTINOMIAL(), PRODUCT(), SIGN(), SUMSQ(),
 	and SQRTPI().
2329

2330 2331 2332 2333 2334
1999-04-19  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/func.c (iterate_cellrange_callback): Eval the cell here if
	it has not yet been evaluated.

2335 2336 2337 2338 2339
Sun Apr 18 17:59:09 EDT 1999 Gregory McLean <gregm@comstar.net>

	* gnumeric.spec.in: Updated and enhanced spec file. Tastes even
	better and is less filling to boot!

2340 2341 2342
1999-04-17  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/sheet-object-container.c (make_container_item): New
2343
	routine.
2344 2345 2346
	(sheet_object_container_land): Used to convert from the temporary
	widgets to the view provided by Bonobo.

Miguel de Icaza's avatar
Miguel de Icaza committed
2347 2348
1999-04-16  Miguel de Icaza  <miguel@nuclecu.unam.mx>

2349
	* src/expr.c (value_array_resize): Fix typo bug I introduced.
2350

2351 2352 2353
	* src/eval.c (cell_queue_recalc): When queuing for recalc, tag the
	cell, so that if we remove the cell from the recalc list we can
	quickly find out if we have to look for it on the list of pending
2354
	recomputations.
2355 2356 2357 2358 2359
	(pick_next_cell_from_queue): Clear the cell's
	CELL_QUEUED_FOR_RECALC bit.
	(cell_unqueue_from_recalc): New routine to remove a cell queued
	for recomputation.

Miguel de Icaza's avatar
Miguel de Icaza committed
2360 2361
	* src/clipboard.c (new_node): Trim leading spaces.

jpekka's avatar
jpekka committed
2362 2363
1999-04-16  Jukka-Pekka Iivonen  <iivonen@iki.fi>

jpekka's avatar
jpekka committed
2364 2365
	* src/fn-math.c: Added EVEN, FACTDOUBLE, ODD, QUOTIENT, and
	RANDBETWEEN.
2366

jpekka's avatar
jpekka committed
2367 2368
	* src/fn-stat.c: Added LOGINV, NORMINV, NORMSINV, RSQ, and ZTEST
 	functions.
2369

Michael Meeks's avatar
Michael Meeks committed
2370
1999-04-15  Michael Meeks  <michael@edenproject.org>
Michael Meeks's avatar
Michael Meeks committed
2371

2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382
	* src/parser.y (value_dump): Added CellRange support

	* src/fn-lookup.c (gnumeric_offset): Implemented OFFSET.

	* src/expr.c (value_cellrange): Created.
	(eval_funcall): Major hack to allow auto-conversion
	of cell references to cell ranges on the fly.

	* src/expr.h: Added value_cellrange.

1999-04-15  Michael Meeks  <michael@edenproject.org>
2383

Michael Meeks's avatar
Michael Meeks committed
2384 2385
	(gnumeric_choose): CHOOSE function implemented.

2386 2387 2388
1999-04-14  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/sheet.c (sheet_destroy): No longer destroys the Bonobo
2389
	objects here.
2390 2391

	* src/sheet.h (Sheet): No longer keeps track of the ClientSites
2392 2393
	here.

2394 2395 2396 2397 2398 2399
	* src/sheet-object.c (sheet_finish_object_creation): Invoke new
	class method to signal finalization of object creation.

	* src/sheet-object-container.c, src/sheet-object-container.h: New
	files that implement the Bonobo ClientSites
	(SheetObjectContainers).
2400

2401
	* src/Makefile.am (gnumeric_bonobo_SOURCES): Sources for Bonobo
2402
	compilation.
2403 2404

	* src/sheet-object.c (sheet_object_construct): Create the bounding
2405
	box points here.
2406 2407 2408 2409 2410
	(sheet_set_mode_type): Fix from my previous reorganization:  Only
	stop editing mode if the mode is SHEET_MODE_SHEET.
	(sheet_button_press): Strategy change: now we accept
	sheet->current_object and we stop editing here the object.

2411 2412
	* src/sheet-object.h: points has been renamed to bbox_points.

2413 2414 2415 2416
	* src/sheet-object-graphic.c (sheet_object_filled_realize):
	Simplified this routine.  Also, we now update the bounding box
	here.

2417 2418
1999-04-15  Michael Meeks  <michael@mejm2.dow.cam.ac.uk>

2419 2420
	* src/fn-lookup.c: Silly bug in types fixed.

Michael Meeks's avatar
Michael Meeks committed
2421
	* src/expr.c (eval_funcall): Made cellrefs absolute.
2422

2423 2424
	* src/cell.c (cell_set_text_simple): Fix for 1.234E-07

2425 2426 2427 2428 2429 2430 2431 2432 2433 2434
1999-04-13  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/sheet-object.c: Converted SheetObject to a Gtk+ object.
	Splitted the functionality of the SheetObject into classes:
	SheetObject abstract class;  SheetObjectGraphic for simple drawings;
	SheetObjectFilled for objects that have a fill attribute.

	* src/sheet-object-graphic.c: Implement the SheetObjectGraphic and
	SheetObjectFilled objects.

2435 2436 2437 2438 2439
1999-04-13  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/xml-io.c (xml_probe): Do not crash if the file is a broken
	XML file.

2440 2441 2442 2443 2444
1999-04-13  Zbigniew Chyla <cyba@t19.ds.pwr.wroc.pl>

	* src/workbook.c: using 'gnome_dialog_run_and_close' instead of
	'gnome_dialog_run' (which _may_ destroy dialog widget - we don't have to
	check for this case).
2445

2446 2447
1999-04-12  Miguel de Icaza  <miguel@nuclecu.unam.mx>

2448 2449 2450 2451
	* src/corba-args.c (gnumeric_arg_parse): Intiialize Bonobo.

	* configure.in: add test for Bonobo.

2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465
	* src/clipboard.c (x_selection_to_cell_region): Fixed the
	computation of columns in the paste code.

1999-04-11  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/workbook.c (insert_object_cmd): Add sample bonobo support.
	Still lacking an object server selector.

	* src/sheet.c (sheet_insert_object): Add Bonobo support.

	* src/sheet-view.c (sheet_view_insert_object): Add basic Bonobo
	support.  I need to reuse the SheetObject stuff to add control
	points to the objects and to handle repositioning.

2466 2467 2468 2469
1999-04-12 Michael Meeks  <michael@imaginator.com>

	* TODO: Removed basic functions section, most are done.

Michael Meeks's avatar
Michael Meeks committed
2470 2471 2472 2473 2474 2475 2476 2477
1999-04-11 Michael Meeks  <michael@imaginator.com>

	* src/dialog-function-select.c (function_select_row):
	Check event is valid before using it, remove redundant
	total redraw.
	(category_select_row): Fix.
	(function_select_create): Removed redundant call to
	duplicated (create_description): Removed.
2478

Michael Meeks's avatar
Michael Meeks committed
2479 2480
	* src/fn-lookup.c: Actualy change the lookup function
	tokens to the correct values.
2481

2482 2483 2484 2485 2486 2487 2488 2489 2490
1998-04-09 Zbigniew Chyla <cyba@t19.ds.pwr.wroc.pl>

	* src/workbook.c: Creating auto_expr menu every time it is popped
        up instead of using one object all the time (and referencing to
        invalid workbook from "activate" signal handler).

        * src/item-grid.c: (item_grid_popup_menu): Fixed memory leak
        (gnumeric_popup_menu used instead of gtk_menu_popup).

2491 2492 2493 2494 2495 2496 2497 2498 2499 2500
1999-04-11 Michael Meeks  <michael@imaginator.com>

	* src/expr.c (eval_funccall): New array / 'area' tokens added,
	error strings simplified ( int type_mismatch added )
	(value_area_get_width, value_area_get_height): Implemented,
	(value_area_get_at_x_y): Implemented.
	(value_array_new, value_array_resize): Implemented.
	(value_release): Updated.
	(value_copy_to, value_array_copy_to): Updated, created.
	Added const to a scad of helper 'value_get' style functions.
2501

2502 2503 2504 2505 2506 2507
	* src/expr.h: Value: Changed 'array' from GList to a
	structure.
	Added struct _Value for self reference.
	Added const to a scad of helper 'value_get' style functions.

	* src/func.c (function_iterate_do_value): Updated Array code.
2508

2509 2510
	* src/eval.c (add_value_deps): Updated Array stuff.
	(add_value_deps): const added to Value *
2511

2512 2513 2514 2515
	* src/dialog-function-wizard.c (function_type_input):
	Updated text for new tokens.

	* src/fn-sheet.c (gnumeric_selection): Update to new array code.
2516

2517 2518 2519 2520 2521 2522 2523
	* src/fn-lookup.c (columns, rows): Updated to clean new API.
	(vlookup, hlookup): Large clean.

	* src/parser.y (value_dump): Updated Array section.

	* docs/C/writing-functions.smgl: Added section explaining tokens,
	and new API.
2524

2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538
1999-04-09 Michael Meeks  <michael@imaginator.com>

	* src/sheet.c (sheet_destroy): Move destruction of cell_hash to
	after destroy_styles.columns_and_rows that use it.
	NULL various pointers.
	(sheet_col_destroy): Added g_return_if_fail (ci)
	(sheet_duplicate_colrow): Merged into (sheet_row_new, sheet_col_new)
	and removed: nasty function.
	(sheet_destroy_columns_and_rows): Fix nasty bug using freed 'l'
	pointer ( freed by sheet_col_destroy / sheet_row_destroy ).
	NULL the pointers for safety.
	(sheet_col_destroy): NULL various pointers.

	* src/sheet.h (sheet_duplicate_colrow): Removed.
2539

2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553
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.
2554

2555 2556
1999-04-07  Miguel de Icaza  <miguel@nuclecu.unam.mx>

2557 2558 2559
	* src/xml-io.c (xmlGetCoordinates): Include fix from Richard Hult:
	Seemed to be a cut and paste error.

Morten Welinder's avatar
Morten Welinder committed
2560
	* src/cell.c (cell_destroy): From Morten Welinder: destroy the
2561 2562 2563 2564 2565
	cell->value only if it does exist.

	* src/file.c (dialog_query_load_file): Set the accepted value to
	false initially.  Thanks for Morten for pointing this one out.

2566 2567 2568 2569
1999-04-06  Zbigniew Chyla <cyba@piast.t19.ds.pwr.wroc.pl>

	* src/workbook.c (workbook_new): Use the translated version of the
	function to display
2570

2571 2572 2573 2574
1999-04-06  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/workbook.c: Enable the function wizard only if the --debug
	flag was passed.
2575

2576 2577 2578 2579
	* src/dialog-function-wizard.c, src/dialog-function-select.c:
	Adapt to the rest of Gnumeric coding style.

	Use a different way of creating the GUI and controlling the
2580 2581
	interactions.

2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593
	* src/func.c, src/func.h (function_iterate_do_value): Use my
	indentation and coding style here.

	* src/dialog-cell-format.c (render_formated_version): Handle the
	case where the value might be NULL.

	* src/xml-io.c (createXmlSheet): New function.  Used in an initial
	pass over the XML file to load all of the Sheets defined there.
	(readXmlWorkbook): Now this does two passes at loading the sheet:
	the first pass creates the sheets, the second pass actually loads
	the contents.

2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604
1999-04-06 Michael Meeks  <michael@imaginator.com>

	* src/workbook.c (workbook_new): More sensible default
	size.

	* src/sheet.c (sheet_row_set_height): use sheet_row_new()
	instead of sheet_duplicate_colrow(), as we get duff span
	data otherwise ( not calling row_init_span )
	(sheet_col_set_width): Re-order, presumably fixing bug,
	and as for set_height.

2605 2606 2607 2608 2609 2610 2611 2612
1999-04-06  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* src/xml-io.c (createXmlSheet): New function.  Used in an initial
	pass over the XML file to load all of the Sheets defined there.
	(readXmlWorkbook): Now this does two passes at loading the sheet:
	the first pass creates the sheets, the second pass actually loads
	the contents.

2613 2614 2615 2616 2617 2618 2619
1999-04-06 Michael Meeks  <michael@imaginator.com>

	* src/func.c (tokenised_help_new): Improved algorithem.
	(functions_init): Made descriptions more verbose.

	* src/workbook.c (wizard_input): Cleaned to use local
	entry instead of specific wb->ea_input.
2620

2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633
	* src/dialog-function-wizard.c (function_type_input):
	Update types, add recursive function button.
	(function_input): Created.
	(arg_data_list_new): Added wb to ARG_DATA, needed for
	function_input.
	Added default code for multi-arg functions.
	Deals with no-argument functions properly,
	Fix silly args=NULL g_free(args) bug.
	(dialog_function_wizard): Special 'no-arguments' quick
	case.

	* src/fn-math.c (gnumeric_rand): Added RAND function.

Morten Welinder's avatar
Morten Welinder committed
2634
1999-04-05  Morten Welinder <terra@diku.dk>