Commit 5ba2df2d authored by Jody Goldberg's avatar Jody Goldberg Committed by Jody Goldberg

Release 0.5.3

2007-11-19  Jody Goldberg <jody@gnome.org>

	* Release 0.5.3

svn path=/trunk/; revision=1976
parent 18940c72
......@@ -299,6 +299,10 @@ Plans
style modification
1.41) Range selection
1.41.1) Initial implementation <-------->
1.42) Win/Lose Plots (simplification of bar/col)
eg up blue, down red
1.43) Grading regions for grid (sequence of colour bands)
eg ( ..0) red, [0..1) yellow, [1..] green.
Misc things to fix
------------------
......@@ -314,3 +318,17 @@ Misc things to fix
: Markers with non solid fill color are displayed
without filling for some shapes. (FIXED)
Ideas
-----
- Dimension choser as label in chart
- Use Legend to manipulate data
- edit style of various series
- Add/remove dimensions
- select items in a plot
- Matrix feature to replicate a group of plots using different slices of
data. eg XY for age x salary, with distinct chart for M and F
- Add 'group' button to the data editors to pull up a context menu that
allows for grouping / filtering
- filter/group routines from autofilter into goffice for charts and pivots
2007-11-19 Jody Goldberg <jody@gnome.org>
* Release 0.5.3
2007-08-10 Jody Goldberg <jody@gnome.org>
* goffice/graph/gog-guru.c (gog_guru) : clean the api. The caller is
......
......@@ -41,7 +41,8 @@ typedef struct {
GogChart *chart;
GogAxis *axis;
GogAxisPosition position;
GogAxisPosition pos_user; /* user assigned preference */
GogAxisPosition pos_calculated; /* actual position, with current AxisSet */
unsigned crossed_axis_id;
GogDatasetElement cross_location;
......
......@@ -81,7 +81,7 @@ gog_axis_base_set_property (GObject *obj, guint param_id,
switch (param_id) {
case AXIS_BASE_PROP_POSITION:
position = g_value_get_uint (value);
resized = (position != axis_base->position);
resized = (position != axis_base->pos_user);
gog_axis_base_set_position (axis_base, position);
break;
case AXIS_BASE_PROP_POSITION_STR:
......@@ -96,8 +96,8 @@ gog_axis_base_set_property (GObject *obj, guint param_id,
position = GOG_AXIS_AT_HIGH;
else
return;
resized = (position != axis_base->position);
axis_base->position = position;
resized = (position != axis_base->pos_user);
axis_base->pos_user = position;
break;
case AXIS_BASE_PROP_CROSS_AXIS_ID:
axis_base->crossed_axis_id = g_value_get_uint (value);
......@@ -169,11 +169,11 @@ gog_axis_base_get_property (GObject *obj, guint param_id,
switch (param_id) {
case AXIS_BASE_PROP_POSITION:
g_value_set_uint (value, axis_base->position);
g_value_set_uint (value, axis_base->pos_user);
break;
case AXIS_BASE_PROP_POSITION_STR:
switch (axis_base->position) {
switch (axis_base->pos_user) {
case GOG_AXIS_AT_LOW:
g_value_set_static_string (value, "low");
break;
......@@ -359,7 +359,7 @@ gog_axis_base_set_position (GogAxisBase *axis_base, GogAxisPosition position)
position = GOG_AXIS_CROSS;
}
axis_base->position = position;
axis_base->pos_calculated = position;
}
#ifdef GOFFICE_WITH_GTK
......@@ -420,7 +420,7 @@ cb_position_toggled (GtkWidget *button, AxisBasePrefs *state)
else
position = GOG_AXIS_AT_LOW;
if (position != axis_base->position)
if (position != axis_base->pos_user)
gtk_widget_set_sensitive (glade_xml_get_widget (state->gui, "padding_spinbutton"),
position != GOG_AXIS_CROSS);
......@@ -556,17 +556,17 @@ gog_axis_base_populate_editor (GogObject *gobj,
"state", state, (GDestroyNotify) axis_base_pref_free);
w = glade_xml_get_widget (gui, "axis_low");
if (axis_base->position == GOG_AXIS_AT_LOW)
if (axis_base->pos_user == GOG_AXIS_AT_LOW)
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), TRUE);
g_signal_connect (G_OBJECT (w), "toggled",
G_CALLBACK (cb_position_toggled), state);
w = glade_xml_get_widget (gui, "axis_cross");
if (axis_base->position == GOG_AXIS_CROSS)
if (axis_base->pos_user == GOG_AXIS_CROSS)
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), TRUE);
g_signal_connect (G_OBJECT (w), "toggled",
G_CALLBACK (cb_position_toggled), state);
w = glade_xml_get_widget (gui, "axis_high");
if (axis_base->position == GOG_AXIS_AT_HIGH)
if (axis_base->pos_user == GOG_AXIS_AT_HIGH)
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (w), TRUE);
g_signal_connect (G_OBJECT (w), "toggled",
G_CALLBACK (cb_position_toggled), state);
......@@ -584,7 +584,7 @@ gog_axis_base_populate_editor (GogObject *gobj,
gtk_spin_button_set_value (GTK_SPIN_BUTTON (w), axis_base->padding);
g_signal_connect (G_CALLBACK (w), "value-changed",
G_CALLBACK (cb_padding_changed), axis_base);
gtk_widget_set_sensitive (w, axis_base->position != GOG_AXIS_CROSS);
gtk_widget_set_sensitive (w, axis_base->pos_user != GOG_AXIS_CROSS);
hide_position_box = FALSE;
} else {
w = glade_xml_get_widget (gui, "padding_box");
......@@ -724,7 +724,7 @@ gog_axis_base_init (GogAxisBase *gab)
gab->chart = NULL;
gab->axis = NULL;
gab->position = GOG_AXIS_AT_LOW;
gab->pos_user = gab->pos_calculated = GOG_AXIS_AT_LOW;
gab->crossed_axis_id = 0;
gab->minor.tick_in = gab->minor.tick_out = gab->major.tick_in = FALSE;
......@@ -753,13 +753,13 @@ gog_axis_base_get_position (GogAxisBase *axis_base)
{
g_return_val_if_fail (GOG_AXIS_BASE (axis_base) != NULL, GOG_AXIS_AT_LOW);
return axis_base->position;
return axis_base->pos_calculated;
}
static int
gog_axis_base_get_padding (GogAxisBase *axis_base)
{
return (axis_base->position == GOG_AXIS_CROSS ?
return (axis_base->pos_calculated == GOG_AXIS_CROSS ?
0 : axis_base->padding);
}
......@@ -1542,7 +1542,7 @@ xy_process (GogAxisBaseAction action, GogView *view, GogViewPadding *padding,
gog_axis_map_get_extents (a_map, &start, &stop);
gog_axis_map_get_bounds (a_map, &minimum, &maximum);
side = GO_SIDE_RIGHT;
switch (axis_base->position) {
switch (axis_base->pos_calculated) {
case GOG_AXIS_CROSS :
position = gog_axis_base_get_cross_location (axis_base);
if (position < minimum)
......@@ -1633,15 +1633,15 @@ radar_process (GogAxisBaseAction action, GogView *view, GogViewPadding *padding,
a_map = gog_chart_map_get_axis_map (c_map, 0);
gog_axis_map_get_bounds (a_map, &minimum, &maximum);
gog_axis_map_get_extents (a_map, &start, &stop);
if (axis_base->position == GOG_AXIS_CROSS) {
if (axis_base->pos_calculated == GOG_AXIS_CROSS) {
position = gog_axis_base_get_cross_location (axis_base);
if (position < minimum || position > maximum) {
gog_chart_map_free (c_map);
return FALSE;
}
} else
position = axis_base->position == GOG_AXIS_AT_LOW ? start : stop;
side = axis_base->position == GOG_AXIS_AT_LOW ? GO_SIDE_RIGHT : GO_SIDE_LEFT;
position = axis_base->pos_calculated == GOG_AXIS_AT_LOW ? start : stop;
side = axis_base->pos_calculated == GOG_AXIS_AT_LOW ? GO_SIDE_RIGHT : GO_SIDE_LEFT;
a_map = gog_chart_map_get_axis_map (c_map, 1);
gog_axis_map_get_extents (a_map, &start, &stop);
......
......@@ -2245,7 +2245,7 @@ gog_axis_view_padding_request (GogView *view,
label_padding.wr = label_padding.wl = label_padding.ht = label_padding.hb = 0;
axis_pos = GOG_AXIS_BASE (axis)->position;
axis_pos = GOG_AXIS_BASE (axis)->pos_calculated;
for (ptr = view->children; ptr != NULL ; ptr = ptr->next) {
child = ptr->data;
......@@ -2255,15 +2255,18 @@ gog_axis_view_padding_request (GogView *view,
available.h = bbox->h;
gog_view_size_request (child, &available, &req);
if (type == GOG_AXIS_X)
if (axis_pos != GOG_AXIS_AT_HIGH)
label_padding.hb += req.h + pad_h;
else
label_padding.ht += req.h + pad_h;
switch (axis_pos) {
case GOG_AXIS_AT_HIGH : label_padding.ht += req.h + pad_h; break;
case GOG_AXIS_AT_LOW : label_padding.hb += req.h + pad_h; break;
default :
break;
}
else
if (axis_pos != GOG_AXIS_AT_HIGH)
label_padding.wl += req.w + pad_w;
else
label_padding.wr += req.w + pad_w;
switch (axis_pos) {
case GOG_AXIS_AT_HIGH : label_padding.wr += req.w + pad_w; break;
case GOG_AXIS_AT_LOW : label_padding.wl += req.w + pad_w; break;
default : break;
}
}
}
......@@ -2310,7 +2313,7 @@ gog_axis_view_size_allocate (GogView *view, GogViewAllocation const *bbox)
available.w = bbox->w;
available.h = bbox->h;
axis_pos = GOG_AXIS_BASE (axis)->position;
axis_pos = GOG_AXIS_BASE (axis)->pos_calculated;
for (ptr = view->children; ptr != NULL ; ptr = ptr->next) {
child = ptr->data;
......@@ -2329,11 +2332,12 @@ gog_axis_view_size_allocate (GogView *view, GogViewAllocation const *bbox)
(plot_area->w - req.w) / 2.0;
child_bbox.w = req.w;
child_bbox.h = req.h;
if (axis_pos != GOG_AXIS_AT_HIGH) {
child_bbox.y = tmp.y + tmp.h - req.h;
} else {
child_bbox.y = tmp.y;
switch (axis_pos) {
case GOG_AXIS_AT_HIGH : child_bbox.y = tmp.y;
tmp.y += req.h + pad_h;
break;
case GOG_AXIS_AT_LOW : child_bbox.y = tmp.y + tmp.h - req.h; break;
default : break;
}
tmp.h -= req.h + pad_h;
} else {
......@@ -2341,12 +2345,12 @@ gog_axis_view_size_allocate (GogView *view, GogViewAllocation const *bbox)
(plot_area->h - req.h) / 2.0;
child_bbox.h = req.h;
child_bbox.w = req.w;
if (axis_pos != GOG_AXIS_AT_HIGH) {
child_bbox.x = tmp.x;
switch (axis_pos) {
case GOG_AXIS_AT_HIGH : child_bbox.x = tmp.x + tmp.w - req.w;
case GOG_AXIS_AT_LOW : child_bbox.x = tmp.x;
tmp.x += req.w + pad_w;
}
else {
child_bbox.x = tmp.x + tmp.w - req.w;
break;
default : break;
}
tmp.w -= req.w + pad_w;
}
......
......@@ -884,8 +884,7 @@ gog_series_get_name (GogSeries const *series)
void
gog_series_set_name (GogSeries *series, GODataScalar *name_src, GError **err)
{
gog_dataset_set_dim (GOG_DATASET (series),
-1, GO_DATA (name_src), NULL);
gog_dataset_set_dim (GOG_DATASET (series), -1, GO_DATA (name_src), err);
}
/**
......
2007-11-19 Jody Goldberg <jody@gnome.org>
* Release 0.5.3
2007-11-04 Morten Welinder <terra@gnome.org>
* Release 0.5.2
......
2007-11-19 Jody Goldberg <jody@gnome.org>
* Release 0.5.3
2007-11-04 Morten Welinder <terra@gnome.org>
* Release 0.5.2
......
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