diff options
author | hobbs <hobbs> | 2002-06-22 08:50:43 (GMT) |
---|---|---|
committer | hobbs <hobbs> | 2002-06-22 08:50:43 (GMT) |
commit | 59f0eb29c9aa298206a245df18926af40863a504 (patch) | |
tree | 16718d51014bd08d37f4649963a28ed8dcef763f /library/console.tcl | |
parent | f9a9b4d79db23b06a16e0d982180dfdd971630bd (diff) | |
download | tk-59f0eb29c9aa298206a245df18926af40863a504.zip tk-59f0eb29c9aa298206a245df18926af40863a504.tar.gz tk-59f0eb29c9aa298206a245df18926af40863a504.tar.bz2 |
* library/console.tcl: corrected the defaultPrompt substitution
[Bug #553207] and made Tab a default expansion key (like Escape).
Diffstat (limited to 'library/console.tcl')
-rw-r--r-- | library/console.tcl | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/library/console.tcl b/library/console.tcl index ee5fbf8..37739b5 100644 --- a/library/console.tcl +++ b/library/console.tcl @@ -4,7 +4,7 @@ # can be used by non-unix systems that do not have built-in support # for shells. # -# RCS: @(#) $Id: console.tcl,v 1.19 2002/05/20 10:21:23 das Exp $ +# RCS: @(#) $Id: console.tcl,v 1.20 2002/06/22 08:50:43 hobbs Exp $ # # Copyright (c) 1995-1997 Sun Microsystems, Inc. # Copyright (c) 1998-2000 Ajuba Solutions. @@ -25,10 +25,11 @@ namespace eval ::tk::console { variable inPlugin [info exists embed_args] variable defaultPrompt ; # default prompt if tcl_prompt1 isn't used + if {$inPlugin} { - set defaultPrompt {subst "[history nextid] % "} + set defaultPrompt {subst {[history nextid] % }} } else { - set defaultPrompt {subst "([file tail [pwd]]) [history nextid] % "} + set defaultPrompt {subst {([file tail [pwd]]) [history nextid] % }} } } @@ -312,6 +313,7 @@ proc ::tk::ConsoleBind {w} { <<Console_PrevSearch>> <Control-Key-r> <<Console_NextSearch>> <Control-Key-s> + <<Console_Expand>> <Key-Tab> <<Console_Expand>> <Key-Escape> <<Console_ExpandFile>> <Control-Shift-Key-F> <<Console_ExpandProc>> <Control-Shift-Key-P> @@ -331,11 +333,6 @@ proc ::tk::ConsoleBind {w} { bind Console $key {} } - bind Console <Tab> { - tk::ConsoleInsert %W \t - focus %W - break - } bind Console <<Console_Expand>> { if {[%W compare insert > promptEnd]} {::tk::console::Expand %W} } |