[evolution-patches] [gtkhtml] fix for broken headers




Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/gtkhtml/src/ChangeLog,v
retrieving revision 1.2032
diff -u -p -r1.2032 ChangeLog
--- ChangeLog	12 Aug 2004 13:40:56 -0000	1.2032
+++ ChangeLog	12 Aug 2004 16:55:14 -0000
@@ -1,3 +1,10 @@
+2004-08-12  Radek Doulik  <rodo ximian com>
+
+	* htmltable.c (divide_upto_preferred_width): in case we are
+	extending column missing minimal width completely, set min_fill to
+	to_fill minus added width and not whole preferred width of that
+	column (that lead to negative values before)
+
 2004-08-10  Radek Doulik  <rodo ximian com>
 
 	* htmlengine-edit-cursor.c (refresh_under_cursor): do not refresh
Index: htmltable.c
===================================================================
RCS file: /cvs/gnome/gtkhtml/src/htmltable.c,v
retrieving revision 1.178
diff -u -p -r1.178 htmltable.c
--- htmltable.c	11 Aug 2004 17:27:38 -0000	1.178
+++ htmltable.c	12 Aug 2004 16:55:14 -0000
@@ -1508,16 +1508,16 @@ divide_upto_preferred_width (HTMLTable *
 		/* printf ("min: %d left: %d\n", min_col, left); */
 		to_fill = MIN (total, left);
 		if (min_pw - max_size [min_col] < ((gdouble) min_pw * to_fill) / total_fill) {
-			
-			left -= min_pw - max_size [min_col];
-			max_size [min_col] = min_pw;
-			min_fill = to_fill - min_pw;
+			added = min_pw - max_size [min_col];
+			left -= added;
+			min_fill = to_fill - added;
+			max_size [min_col] += added;
 			total_fill -= min_pw;
 		} else {
 			min_fill = to_fill;
 		}
 
-		/* printf ("min satisfied %d, (%d=%d)left: %d\n", min_fill, max_size [min_col], min_pw, left); */
+		/* printf ("min satisfied %d, (%d=%d) left: %d\n", min_fill, max_size [min_col], min_pw, left); */
 		processed_pw = 0;
 		added = 0;
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]