[goffice] Fixed graph type selector position. [#667793]
- From: Jean BrÃfort <jbrefort src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [goffice] Fixed graph type selector position. [#667793]
- Date: Thu, 12 Jan 2012 21:45:25 +0000 (UTC)
commit 45a7688d02a7a9431c6de7b9d99bf638339d92cf
Author: Jean Brefort <jean brefort normalesup org>
Date: Thu Jan 12 22:45:03 2012 +0100
Fixed graph type selector position. [#667793]
ChangeLog | 6 ++++++
NEWS | 2 ++
goffice/graph/gog-guru.c | 16 ++++++++--------
goffice/utils/go-cairo.h | 2 +-
4 files changed, 17 insertions(+), 9 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index dd4589b..fbdada9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2012-01-12 Jean Brefort <jean brefort normalesup org>
+
+ * goffice/graph/gog-guru.c (graph_typeselect_minor): fixed selector
+ position. [#667793]
+ * goffice/utils/go-cairo.h: set CAIRO_CLAMP to a larger value. [#645938]
+
2012-01-06 Jean Brefort <jean brefort normalesup org>
* goffice/graph/gog-renderer.h: fixed GdkPixbuf usage. [#667005]
diff --git a/NEWS b/NEWS
index 3642a94..8e5dea4 100644
--- a/NEWS
+++ b/NEWS
@@ -12,6 +12,8 @@ Jean:
[#666292]
* Support wrapped charts labels, partially fixes #643873.
* Fixed GdkPixbuf usage. [#667005]
+ * Don't truncate images when exporting a chart. [#645938]
+ * Fixed graph type selector position. [#667793]
Morten:
* Embed library ui files into library.
diff --git a/goffice/graph/gog-guru.c b/goffice/graph/gog-guru.c
index 16f92e9..b26d815 100644
--- a/goffice/graph/gog-guru.c
+++ b/goffice/graph/gog-guru.c
@@ -176,14 +176,6 @@ graph_typeselect_minor (GraphGuruTypeSelector *typesel, GocItem *item)
g_return_if_fail (type != NULL);
- typesel->current_type = type;
- typesel->current_minor_item = item;
- goc_item_get_bounds (item, &x1, &y1, &x2, &y2);
- goc_item_set (GOC_ITEM (typesel->selector),
- "x", x1-1., "y", y1-1.,
- "width", x2-x1+2., "height", y2-y1+2.,
- NULL);
-
enable_next_button = (s->plot == NULL);
plot = gog_plot_new_by_type (type);
@@ -220,6 +212,14 @@ graph_typeselect_minor (GraphGuruTypeSelector *typesel, GocItem *item)
GINT_TO_POINTER (1));
}
+ typesel->current_type = type;
+ typesel->current_minor_item = item;
+ goc_item_get_bounds (item, &x1, &y1, &x2, &y2);
+ goc_item_set (GOC_ITEM (typesel->selector),
+ "x", x1-1., "y", y1-1.,
+ "width", x2-x1+2., "height", y2-y1+2.,
+ NULL);
+
if (s->chart != NULL) {
GogObject *obj = GOG_OBJECT (s->chart);
gog_object_clear_parent (obj);
diff --git a/goffice/utils/go-cairo.h b/goffice/utils/go-cairo.h
index 75ffad6..e180b87 100644
--- a/goffice/utils/go-cairo.h
+++ b/goffice/utils/go-cairo.h
@@ -33,7 +33,7 @@ G_BEGIN_DECLS
/* This is a workaround for a cairo bug, due to its internal
* handling of coordinates (16.16 fixed point). */
-#define GO_CAIRO_CLAMP(x) CLAMP((x),-15000,15000)
+#define GO_CAIRO_CLAMP(x) CLAMP((x),-8000000,8000000)
#define GO_CAIRO_CLAMP_SNAP(x,even) GO_CAIRO_CLAMP(even ? floor (x + .5):floor (x) + .5)
void go_cairo_emit_svg_path (cairo_t *cr, char const *path);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]