summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2008-05-14 08:29:05 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2008-05-14 08:29:05 (GMT)
commit55409abda8f00f6af3def7318ec66de03beded37 (patch)
tree6732824a5e938bdbf7ffa280ce0513800fd17ae0 /generic
parentd853863c8bbda281a220cea42a6e295b76ebc8ea (diff)
downloadtk-55409abda8f00f6af3def7318ec66de03beded37.zip
tk-55409abda8f00f6af3def7318ec66de03beded37.tar.gz
tk-55409abda8f00f6af3def7318ec66de03beded37.tar.bz2
Apply fix for [Bug 1639824]
Diffstat (limited to 'generic')
-rw-r--r--generic/tkPanedWindow.c17
1 files changed, 13 insertions, 4 deletions
diff --git a/generic/tkPanedWindow.c b/generic/tkPanedWindow.c
index f80e257..cffac53 100644
--- a/generic/tkPanedWindow.c
+++ b/generic/tkPanedWindow.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkPanedWindow.c,v 1.31 2008/04/27 22:38:56 dkf Exp $
+ * RCS: @(#) $Id: tkPanedWindow.c,v 1.32 2008/05/14 08:29:07 dkf Exp $
*/
#include "default.h"
@@ -1459,9 +1459,11 @@ DisplayPanedWindow(
if (slavePtr->hide) {
continue;
}
- Tk_Fill3DRectangle(tkwin, pixmap, pwPtr->background,
- slavePtr->sashx, slavePtr->sashy,
- sashWidth, sashHeight, 1, pwPtr->sashRelief);
+ if (sashWidth > 0 && sashHeight > 0) {
+ Tk_Fill3DRectangle(tkwin, pixmap, pwPtr->background,
+ slavePtr->sashx, slavePtr->sashy, sashWidth, sashHeight,
+ 1, pwPtr->sashRelief);
+ }
if (pwPtr->showHandle) {
Tk_Fill3DRectangle(tkwin, pixmap, pwPtr->background,
slavePtr->handlex, slavePtr->handley,
@@ -2831,6 +2833,13 @@ PanedWindowProxyCommand(
(2 * Tk_InternalBorderWidth(pwPtr->tkwin));
}
+ if (sashWidth < 1) {
+ sashWidth = 1;
+ }
+ if (sashHeight < 1) {
+ sashHeight = 1;
+ }
+
/*
* Stash the proxy coordinates for future "proxy coord" calls.
*/