Posted to tcl by egavilan at Tue May 13 23:11:07 GMT 2008view pretty

--- generic/tkPanedWindow.c.orig	2008-05-13 19:52:10.000000000 -0300
+++ generic/tkPanedWindow.c	2008-05-13 20:04:08.000000000 -0300
@@ -2818,7 +2818,17 @@
 		x = 0;
 	    }
 	    y = Tk_InternalBorderWidth(pwPtr->tkwin);
-	    sashWidth = pwPtr->sashWidth;
+
+	    /* If the sashwidth is less than 1, use 1 as the width of the 
+	       proxy window. This workarounds bug #1639824
+	     */
+
+	    if (pwPtr->sashWidth > 0) {
+	        sashWidth = pwPtr->sashWidth;
+	    } else {
+		sashWidth = 1;
+	    }
+
 	    sashHeight = Tk_Height(pwPtr->tkwin) -
 		    (2 * Tk_InternalBorderWidth(pwPtr->tkwin));
 	} else {
@@ -2826,7 +2836,13 @@
 		y = 0;
 	    }
 	    x = Tk_InternalBorderWidth(pwPtr->tkwin);
-	    sashHeight = pwPtr->sashWidth;
+
+	    if (pwPtr->sashWidth > 0) {
+		sashHeight = pwPtr->sashWidth;
+	    } else {
+		sashHeight = 1;
+	    }
+	    
 	    sashWidth = Tk_Width(pwPtr->tkwin) -
 		    (2 * Tk_InternalBorderWidth(pwPtr->tkwin));
 	}