[Gnucash-changes] r13681 - gnucash/trunk - Rename gtkhtml workaround, non-squared graphs in gtkhtml >= 3.10.1. Fix 328114.

Andreas Köhler andi5 at cvs.gnucash.org
Wed Mar 22 04:30:59 EST 2006


Author: andi5
Date: 2006-03-22 04:30:58 -0500 (Wed, 22 Mar 2006)
New Revision: 13681
Trac: http://svn.gnucash.org/trac/changeset/13681

Modified:
   gnucash/trunk/ChangeLog
   gnucash/trunk/src/gnome-utils/gnc-html-graph-gog.c
Log:
Rename gtkhtml workaround, non-squared graphs in gtkhtml >= 3.10.1. Fix 328114.


Modified: gnucash/trunk/ChangeLog
===================================================================
--- gnucash/trunk/ChangeLog	2006-03-22 09:16:22 UTC (rev 13680)
+++ gnucash/trunk/ChangeLog	2006-03-22 09:30:58 UTC (rev 13681)
@@ -1,3 +1,8 @@
+2006-03-22  Andreas Köhler  <andi5.py at gmx.net>
+
+	* src/gnome-utils/gnc-html-graph-gog.c: Rename gtkhtml workaround,
+	  non-squared graphs in gtkhtml >= 3.10.1. Fix 328114.
+
 2006-03-21  David Hampton  <hampton at employees.org>
 
 	* src/gnome-utils/dialog-account.[ch]:

Modified: gnucash/trunk/src/gnome-utils/gnc-html-graph-gog.c
===================================================================
--- gnucash/trunk/src/gnome-utils/gnc-html-graph-gog.c	2006-03-22 09:16:22 UTC (rev 13680)
+++ gnucash/trunk/src/gnome-utils/gnc-html-graph-gog.c	2006-03-22 09:30:58 UTC (rev 13681)
@@ -75,7 +75,7 @@
 static void set_chart_titles(GogObject *chart, const char *title, const char* sub_title);
 static void set_chart_axis_labels_from_hash(GogObject *chart, GtkHTMLEmbedded * eb);
 static void set_chart_axis_labels(GogObject *chart, const char *x_axis_label, const char* y_axis_label);
-static void gtkhtml_3_3_2_bug_workaround(GtkHTMLEmbedded *eb);
+static void gtkhtml_pre_3_10_1_bug_workaround(GtkHTMLEmbedded *eb);
 
 void
 gnc_html_graph_gog_init(void)
@@ -284,9 +284,11 @@
 }
 
 static void
-gtkhtml_3_3_2_bug_workaround(GtkHTMLEmbedded *eb)
+gtkhtml_pre_3_10_1_bug_workaround(GtkHTMLEmbedded *eb)
 {
-  /* HACK ALERT! Compensate for bug in gtkhtml-3.3.2 */
+  /* HACK ALERT! Compensate for bug in gtkhtml < 3.10.1
+     Gtkhtml set the width parameter twice (=width, =height), so both,
+     width (==height) and height (<1) were incorrect. */
   if (eb->height < 1)
   {
       eb->height = eb->width;  /* only squares here :( */
@@ -315,7 +317,7 @@
   double *data = NULL;
   char **labels = NULL, **colors = NULL;
 
-  gtkhtml_3_3_2_bug_workaround(eb);
+  gtkhtml_pre_3_10_1_bug_workaround(eb);
 
   // parse data from the text-ized params.
   {
@@ -388,7 +390,7 @@
   char *bar_type = "normal";
   int bar_overlap = 0 /*percent*/; // seperate bars; no overlap.
 
-  gtkhtml_3_3_2_bug_workaround (eb);
+  gtkhtml_pre_3_10_1_bug_workaround (eb);
 
   // parse data from the text-ized params
   // series => bars [gnc:cols]
@@ -505,7 +507,7 @@
   int datasize;
   double *xData, *yData;
 
-  gtkhtml_3_3_2_bug_workaround(eb);
+  gtkhtml_pre_3_10_1_bug_workaround(eb);
 
   {
     char *datasizeStr, *xDataStr, *yDataStr;



More information about the gnucash-changes mailing list