Commit 714ab40e authored by Jody Goldberg's avatar Jody Goldberg Committed by Jody Goldberg

handle blanks without an error.

2006-03-22  Jody Goldberg <jody@gnome.org>

	* src/graph.c (gnm_go_data_vector_get_value) : handle blanks without
	  an error.

2006-03-16  Jody Goldberg <jody@gnome.org>

	* Makefile.am : Drop the .server, .keys, and .mime files as obsolete.

2006-03-14  Jody Goldberg <jody@gnome.org>

	* src/sheet.c (sheet_dup) : dup the properties too.
parent a398fb6b
......@@ -3,6 +3,19 @@
* src/gnm-datetime.c (datetime_value_to_g): Check validity of
date.
2006-03-22 Jody Goldberg <jody@gnome.org>
* src/graph.c (gnm_go_data_vector_get_value) : handle blanks without
an error.
2006-03-16 Jody Goldberg <jody@gnome.org>
* Makefile.am : Drop the .server, .keys, and .mime files as obsolete.
2006-03-14 Jody Goldberg <jody@gnome.org>
* src/sheet.c (sheet_dup) : dup the properties too.
2006-03-22 Morten Welinder <terra@gnome.org>
* src/validation.c (validation_eval): Clean this up. Handle
......
......@@ -10,28 +10,30 @@ change_logs = ChangeLog \
OChangeLog-2000-02-23 OChangeLog-2000-10-10 \
OChangeLog-2001-06-26
@INTLTOOL_DESKTOP_RULE@
Applicationsdir = $(datadir)/applications/
Applications_in_files = gnumeric.desktop.in
Applications_DATA = gnumeric.desktop
gnewdir = $(datadir)/mc/templates
gnew_in_files = gnumeric.desktop.in
gnew_DATA = gnumeric.desktop
Mimedir = $(datadir)/mime-info
Mime_DATA = gnumeric.keys gnumeric.mime
if WITH_GNOME
serverdir = $(libdir)/bonobo/servers/
server_in_files = GNOME_Gnumeric.server.in
server_DATA = GNOME_Gnumeric.server
GNOME_Gnumeric.server.in : GNOME_Gnumeric.server.in.in Makefile
sed -e "s|\@LIBEXECDIR\@|$(libexecdir)|" $< > $@
endif
@INTLTOOL_SERVER_RULE@
# gnewdir = $(datadir)/mc/templates
# gnew_in_files = gnumeric.desktop.in
# gnew_DATA = gnumeric.desktop
# Mimedir = $(datadir)/mime-info
# Mime_DATA = gnumeric.keys gnumeric.mime
# Old stale functionality
#
#if WITH_GNOME
#serverdir = $(libdir)/bonobo/servers/
#server_in_files = GNOME_Gnumeric.server.in
#server_DATA = GNOME_Gnumeric.server
#GNOME_Gnumeric.server.in : GNOME_Gnumeric.server.in.in Makefile
# sed -e "s|\@LIBEXECDIR\@|$(libexecdir)|" $< > $@
#
# @INTLTOOL_SERVER_RULE@
#endif
# Unused as far as I know
#gnumeric.keys: gnumeric.keys.in Makefile
# sed -e 's^\@gnumeric_icondir\@^$(gnumeric_icondir)^g' < $(srcdir)/gnumeric.keys.in > gnumeric.keys.tmp \
# && mv gnumeric.keys.tmp gnumeric.keys
#
CLEANFILES = $(server_DATA) $(server_in_files) \
gnumeric.desktop gnumeric.keys
......@@ -51,9 +53,11 @@ EXTRA_DIST = \
omf.make \
GNOME_Gnumeric.server.in.in $(server_in_files) $(server_DATA)
gnumeric.keys: gnumeric.keys.in Makefile
sed -e 's^\@gnumeric_icondir\@^$(gnumeric_icondir)^g' < $(srcdir)/gnumeric.keys.in > gnumeric.keys.tmp \
&& mv gnumeric.keys.tmp gnumeric.keys
@INTLTOOL_DESKTOP_RULE@
Applicationsdir = $(datadir)/applications/
Applications_in_files = gnumeric.desktop.in
Applications_DATA = gnumeric.desktop
gnumeric.desktop: gnumeric.desktop.in Makefile $(INTLTOOL_MERGE) $(POFILES_FULL)
LC_ALL=C $(INTLTOOL_MERGE) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< $@.tmp
......
......@@ -3,6 +3,19 @@
* src/gnm-datetime.c (datetime_value_to_g): Check validity of
date.
2006-03-22 Jody Goldberg <jody@gnome.org>
* src/graph.c (gnm_go_data_vector_get_value) : handle blanks without
an error.
2006-03-16 Jody Goldberg <jody@gnome.org>
* Makefile.am : Drop the .server, .keys, and .mime files as obsolete.
2006-03-14 Jody Goldberg <jody@gnome.org>
* src/sheet.c (sheet_dup) : dup the properties too.
2006-03-22 Morten Welinder <terra@gnome.org>
* src/validation.c (validation_eval): Clean this up. Handle
......
......@@ -578,8 +578,10 @@ gnm_go_data_vector_get_value (GODataVector *dat, unsigned i)
v = value_dup (vec->as_col
? value_area_get_x_y (vec->val, 0, i, &ep)
: value_area_get_x_y (vec->val, i, 0, &ep));
v = value_coerce_to_number (v, &valid, &ep);
if (NULL == v)
return go_nan;
v = value_coerce_to_number (v, &valid, &ep);
if (valid) {
gnm_float res = value_get_as_float (v);
value_release (v);
......@@ -983,8 +985,10 @@ gnm_go_data_matrix_get_value (GODataMatrix *dat, unsigned i, unsigned j)
eval_pos_init_dep (&ep, &mat->dep);
v = value_dup (value_area_get_x_y (mat->val, i, j, &ep));
v = value_coerce_to_number (v, &valid, &ep);
if (NULL == v)
return go_nan;
v = value_coerce_to_number (v, &valid, &ep);
if (valid) {
gnm_float res = value_get_as_float (v);
value_release (v);
......
......@@ -3,7 +3,7 @@
/*
* sheet.c: Implements the sheet management and per-sheet storage
*
* Copyright (C) 2000-2005 Jody Goldberg (jody@gnome.org)
* Copyright (C) 2000-2006 Jody Goldberg (jody@gnome.org)
* Copyright (C) 1997-1999 Miguel de Icaza (miguel@kernel.org)
*
* This program is free software; you can redistribute it and/or
......@@ -4283,9 +4283,12 @@ sheet_clone_colrow_info (Sheet const *src, Sheet *dst)
static void
sheet_clone_styles (Sheet const *src, Sheet *dst)
{
GnmRange r;
GnmStyleList *styles;
GnmCellPos corner = { 0, 0 };
static GnmCellPos const corner = { 0, 0 };
GnmRange r;
GnmStyleList *styles;
sheet_style_set_auto_pattern_color (
dst, sheet_style_get_auto_pattern_color (src));
styles = sheet_style_get_list (src, range_init_full_sheet (&r));
sheet_style_set_list (dst, &corner, FALSE, styles);
......@@ -4368,8 +4371,10 @@ sheet_clone_cells (Sheet const *src, Sheet *dst)
/**
* sheet_dup :
* @src :
*/
* @src : #Sheet
*
* Create a new Sheet and return it.
**/
Sheet *
sheet_dup (Sheet const *src)
{
......@@ -4386,13 +4391,27 @@ sheet_dup (Sheet const *src)
dst = sheet_new (wb, name);
g_free (name);
/* Copy the print info */
g_object_set (dst,
"zoom-factor", src->last_zoom_factor_used,
"text-is-rtl", src->text_is_rtl,
"visibility", src->visibility,
"protected", src->is_protected,
"display-formulas", src->display_formulas,
"display-zeros", !src->hide_zero,
"display-grid", !src->hide_grid,
"display-column-header", !src->hide_col_header,
"display-row-header", !src->hide_row_header,
"display-outlines", !src->display_outlines,
"display-outlines-below", src->outline_symbols_below,
"display-outlines-right", src->outline_symbols_right,
"use-r1c1", src->r1c1_addresses,
"tab-foreground", src->tab_text_color,
"tab-background", src->tab_color,
NULL);
print_info_free (dst->print_info);
dst->print_info = print_info_dup (src->print_info);
sheet_style_set_auto_pattern_color (
dst, sheet_style_get_auto_pattern_color (src));
sheet_clone_styles (src, dst);
sheet_clone_regions (src, dst);
sheet_clone_colrow_info (src, dst);
......@@ -4403,16 +4422,11 @@ sheet_dup (Sheet const *src)
#warning selection is in view
#warning freeze/thaw is in view
/* Copy the solver */
solver_param_destroy (dst->solver_parameters);
dst->solver_parameters = solver_lp_copy (src->solver_parameters, dst);
/* Copy scenarios */
dst->scenarios = scenario_copy_all (src->scenarios, dst);
/* We need a more general property copying solution. */
g_object_set (dst, "zoom-factor", src->last_zoom_factor_used, NULL);
sheet_mark_dirty (dst);
sheet_redraw_all (dst, TRUE);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment