summaryrefslogtreecommitdiffstats
path: root/unix/tkUnixScrlbr.c
diff options
context:
space:
mode:
authordkf <dkf@noemail.net>2009-10-07 14:28:35 (GMT)
committerdkf <dkf@noemail.net>2009-10-07 14:28:35 (GMT)
commit143f512a1e98af29c23eba8f3498478221559b72 (patch)
tree5c89d53b915a4a0ddc2f587ec112dc7116b2dded /unix/tkUnixScrlbr.c
parent043e30764a96a4c5bc8566ffc1b08ed7d75c7b6a (diff)
downloadtk-143f512a1e98af29c23eba8f3498478221559b72.zip
tk-143f512a1e98af29c23eba8f3498478221559b72.tar.gz
tk-143f512a1e98af29c23eba8f3498478221559b72.tar.bz2
[Patch 2088597]: Stop scrollbars from getting too small at the end.
FossilOrigin-Name: 10ea505d24f3337a71bc313b53d3780f6175adf4
Diffstat (limited to 'unix/tkUnixScrlbr.c')
-rw-r--r--unix/tkUnixScrlbr.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/unix/tkUnixScrlbr.c b/unix/tkUnixScrlbr.c
index fc3e7f8..e4ad751 100644
--- a/unix/tkUnixScrlbr.c
+++ b/unix/tkUnixScrlbr.c
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkUnixScrlbr.c,v 1.3 2000/11/22 01:49:38 ericm Exp $
+ * RCS: @(#) $Id: tkUnixScrlbr.c,v 1.3.6.1 2009/10/07 14:28:37 dkf Exp $
*/
#include "tkScrollbar.h"
@@ -302,8 +302,8 @@ TkpComputeScrollbarGeometry(scrollPtr)
* a minimal width (so it can be grabbed with the mouse).
*/
- if (scrollPtr->sliderFirst > (fieldLength - 2*scrollPtr->borderWidth)) {
- scrollPtr->sliderFirst = fieldLength - 2*scrollPtr->borderWidth;
+ if (scrollPtr->sliderFirst > (fieldLength - MIN_SLIDER_LENGTH)) {
+ scrollPtr->sliderFirst = fieldLength - MIN_SLIDER_LENGTH;
}
if (scrollPtr->sliderFirst < 0) {
scrollPtr->sliderFirst = 0;