diff options
author | hobbs <hobbs> | 2001-07-03 01:03:16 (GMT) |
---|---|---|
committer | hobbs <hobbs> | 2001-07-03 01:03:16 (GMT) |
commit | 16f4674f9018d263feee538f0197602a4d5e6552 (patch) | |
tree | f0f5765b05f0fcc773bdb417e722c60e2299bbdb /library/entry.tcl | |
parent | f405cff050c7702d93474e0ab6810b2083a2e13e (diff) | |
download | tk-16f4674f9018d263feee538f0197602a4d5e6552.zip tk-16f4674f9018d263feee538f0197602a4d5e6552.tar.gz tk-16f4674f9018d263feee538f0197602a4d5e6552.tar.bz2 |
* library/console.tcl:
* library/entry.tcl:
* library/spinbox.tcl:
* library/text.tcl:
* library/tk.tcl: added private ::tk::GetSelection command to
handle requesting selection. This is to support requesting
UTF8_STRING before generic STRING on Unix. Changed Text, Spinbox,
Entry and Console to use this command.
* tests/select.test:
* generic/tkSelect.c (Tk_CreateSelHandler, Tk_DeleteSelHandler):
on Unix, a UTF8_STRING handler will be created when the user
requests a STRING handler (in addition to the STRING handler).
This provides implicit support for the new UTF8_STRING selection
target.
* unix/tkUnixSelect.c (TkSelEventProc, ConvertSelection): Added
support for UTF8_STRING target. [RFE #418653, Patch #433283]
* generic/tkInt.h: added utf8Atom to TkDisplay structure.
Diffstat (limited to 'library/entry.tcl')
-rw-r--r-- | library/entry.tcl | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/library/entry.tcl b/library/entry.tcl index a826481..5392bcd 100644 --- a/library/entry.tcl +++ b/library/entry.tcl @@ -3,7 +3,7 @@ # This file defines the default bindings for Tk entry widgets and provides # procedures that help in implementing those bindings. # -# RCS: @(#) $Id: entry.tcl,v 1.14 2001/03/29 11:05:49 mdejong Exp $ +# RCS: @(#) $Id: entry.tcl,v 1.15 2001/07/03 01:03:16 hobbs Exp $ # # Copyright (c) 1992-1994 The Regents of the University of California. # Copyright (c) 1994-1997 Sun Microsystems, Inc. @@ -55,7 +55,7 @@ bind Entry <<Paste>> { %W delete sel.first sel.last } } - %W insert insert [selection get -displayof %W -selection CLIPBOARD] + %W insert insert [::tk::GetSelection %W CLIPBOARD] tkEntrySeeInsert %W } } @@ -210,7 +210,7 @@ if {[string equal $tcl_platform(platform) "macintosh"]} { # generates the <<Paste>> event, so we don't need to do anything here. if {[string compare $tcl_platform(platform) "windows"]} { bind Entry <Insert> { - catch {tkEntryInsert %W [selection get -displayof %W]} + catch {tkEntryInsert %W [::tk::GetSelection %W PRIMARY]} } } @@ -408,7 +408,7 @@ proc tkEntryPaste {w x} { global tkPriv $w icursor [tkEntryClosestGap $w $x] - catch {$w insert insert [selection get -displayof $w]} + catch {$w insert insert [::tk::GetSelection $w PRIMARY]} if {[string compare "disabled" [$w cget -state]]} {focus $w} } |