Diff
Not logged in

Differences From Artifact [211857a65a]:

To Artifact [66de68b4b7]:


1
2
3
4
5
6
7
8
9
10
#!/usr/local/bin/tclsh
# FILE: "/home/joze/src/tclreadline/tclreadlineSetup.tcl.in"
# LAST MODIFICATION: "Tue Aug 24 03:04:10 1999 (joze)"
# (C) 1998, 1999 by Johannes Zellner, <johannes@zellner.org>
# $Id$
# ---
#
# tclreadline -- gnu readline for tcl
# Copyright (C) 1999  Johannes Zellner
#


|







1
2
3
4
5
6
7
8
9
10
#!/usr/local/bin/tclsh
# FILE: "/home/joze/src/tclreadline/tclreadlineSetup.tcl.in"
# LAST MODIFICATION: "Wed Aug 25 02:00:47 1999 (joze)"
# (C) 1998, 1999 by Johannes Zellner, <johannes@zellner.org>
# $Id$
# ---
#
# tclreadline -- gnu readline for tcl
# Copyright (C) 1999  Johannes Zellner
#
277
278
279
280
281
282
283
284


285
286
287
288
289
290
291
        set new_end [expr $end - ($start - $new_start)]
        set new_line [lindex $sub 1]
        # puts stderr "(SubCmd) $new_start $new_end $new_line"
        return \
            [tclreadline::ScriptCompleter $part $new_start $new_end $new_line]
    } elseif {0 == [set pos [tclreadline::PartPosition $part $start $end $line]]} {
        # puts stderr "(PartPosition) $part $start $end $line"
        set matches [array names known_cmds "[string trim ${part}]*"]


        # puts matches=|$matches|
        if {1 == [llength $matches]} { ; # unique match
            return $matches
        } elseif {"" != $matches} {
            set common [tclreadline::GetCommon ${matches}]
            # puts stderr common=|$common|
            if {"" == $common} {







|
>
>







277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
        set new_end [expr $end - ($start - $new_start)]
        set new_line [lindex $sub 1]
        # puts stderr "(SubCmd) $new_start $new_end $new_line"
        return \
            [tclreadline::ScriptCompleter $part $new_start $new_end $new_line]
    } elseif {0 == [set pos [tclreadline::PartPosition $part $start $end $line]]} {
        # puts stderr "(PartPosition) $part $start $end $line"
        # set matches [array names known_cmds "[string trim ${part}]*"]
        set cmd "[string trim ${part}]*"
        set matches "[info commands $cmd] [info proc $cmd]"
        # puts matches=|$matches|
        if {1 == [llength $matches]} { ; # unique match
            return $matches
        } elseif {"" != $matches} {
            set common [tclreadline::GetCommon ${matches}]
            # puts stderr common=|$common|
            if {"" == $common} {