Version 3 of Migration to 8.4: Tk Private Commands

Updated 2002-07-12 13:17:15

Page to record guidelines for dealing with the private commands renamed in Tk 8.4.


An example:

Hey, my script doesn't work with Tk 8.4! It says "invalid command name "tkTabToWindow""

Tk 8.3 defined a private command [tkTabToWindow]. Tk 8.4 no longer does. It was never a public interface, and when you use private interfaces you risk getting caught by changes like this.

Quick workaround. Add this to your script:

    tk::unsupported::ExposePrivateCommand tkTabToWindow

That will restore the existence of the [tkTabToWindow] command. If you've used other private commands you will need to do the same for each of them.

Longer term, you should re-write your script so that it doesn't make use of Tk's private commands. If you find that this is too limiting, and access to the private commands is necessary, then get to work making a TIP proposal for Tk to provide that functionality in a public way:

        http://purl.org/tcl/tip/

Se TIP 44 [L1 ]


See also Changes in Tcl/Tk 8.4