+2001-08-24 Jeff Hobbs <jeffh@ActiveState.com>
+
+ * tkcon.tcl (NewSocket, NewDisplay): when nothing is specified,
+ just return.
+ (Display): fixed connecting to interps on other displays.
+
2001-08-22 Jeff Hobbs <jeffh@ActiveState.com>
* docs/bindings.html: noted ^r/^s change.
wm withdraw $t
set host [$t.host get]
set port [$t.port get]
+ if {$host == ""} { return }
if {[catch {
set sock [socket $host $port]
} err]} {
variable DISP
set res {}
- if {[string compare {} $disp]} {
- if {![info exists DISP($disp)]} {
- return
- }
+ if {$disp != ""} {
+ if {![info exists DISP($disp)]} { return }
return [list $DISP($disp) [winfo interps -displayof $DISP($disp)]]
}
- foreach d [array names DISP] {
- lappend res [string range $d 5 end]
- }
- return $res
+ return [lsort -dictionary [array names DISP]]
}
proc ::tkcon::NewDisplay {} {
variable PRIV
+ variable DISP
set t $PRIV(base).newdisp
if {![winfo exists $t]} {
grab release $t
wm withdraw $t
set disp [$t.data get]
+ if {$disp == ""} { return }
regsub -all {\.} [string tolower $disp] ! dt
set dt $PRIV(base).$dt
destroy $dt