diff options
author | hobbs <hobbs> | 2003-02-25 00:46:41 (GMT) |
---|---|---|
committer | hobbs <hobbs> | 2003-02-25 00:46:41 (GMT) |
commit | da8f7877e119679ac2654359c1053e9947b01938 (patch) | |
tree | 2f84759b83764383bb5b2affa490a72f369f60b6 /tests/entry.test | |
parent | 68b02413629ab3ebad8f39d83c6fac20319f6f08 (diff) | |
download | tk-da8f7877e119679ac2654359c1053e9947b01938.zip tk-da8f7877e119679ac2654359c1053e9947b01938.tar.gz tk-da8f7877e119679ac2654359c1053e9947b01938.tar.bz2 |
* generic/tkEntry.c (SpinboxWidgetObjCmd, EntryWidgetObjCmd):
* tests/entry.test: return 1 if selection is present even if
* tests/spinbox.test: entry/spinbox is disabled, as selection get
will still return the selection (although selection still ignore
modify requests when entry/spinbox is disabled). [Bug #637828]
Diffstat (limited to 'tests/entry.test')
-rw-r--r-- | tests/entry.test | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/tests/entry.test b/tests/entry.test index effa631..101a0c6 100644 --- a/tests/entry.test +++ b/tests/entry.test @@ -6,7 +6,7 @@ # Copyright (c) 1998-1999 by Scriptics Corporation. # All rights reserved. # -# RCS: @(#) $Id: entry.test,v 1.13 2002/10/02 20:59:28 hobbs Exp $ +# RCS: @(#) $Id: entry.test,v 1.14 2003/02/25 00:46:41 hobbs Exp $ package require tcltest 2.1 namespace import -force tcltest::configure @@ -1599,6 +1599,22 @@ test entry-20.7 {widget deletion with textvariable active} { winfo exists .e } 0 +test entry-21.1 {selection present while disabled, bug 637828} { + destroy .e + entry .e + .e insert end 0123456789 + .e select from 3 + .e select to 6 + set out [.e selection present] + .e configure -state disabled + # still return 1 when disabled, because 'selection get' will work, + # but selection cannot be changed (new behavior since 8.4) + .e select to 9 + lappend out [.e selection present] [selection get] +} {1 1 345} + +destroy .e + # XXX Still need to write tests for EntryBlinkProc, EntryFocusProc, # and EntryTextVarProc. |