observe procedure| TkCon Docs | Purpose & Features | Limitations | To Do | Changes | License Terms | Using TkCon with other Tk Languages |
| Getting Started | Special Bindings | Procedures | |
dump |
tkcon |
idebug |
observe |
This command provides runtime debugging output for variables and commands
without the need to edit your code. For variables, the underlying mechanism
uses trace and dump var. For commands, it renames
the observed procedure and uses a special wrapper procedure. WARNING: using this procedure after checkpointing
state will result in major problems if you clean state because the renamed
(true) commands will be lost.
This procedure is experimental. Comments are encouraged.
observe command cmdname ?maxlevel?
dump) the call stack to the console. maxlevel
represents the maximum number of levels of the call stack which will be
printed (defaults to 4).
observe cdelete cmdname
observe cinfo cmdname
observe variable varname operation ?args?
dump to
print out the value of the named variable whenever the specified operation
on that variable occurs (must be read, write or unset).
observe vdelete varname operation
observe vinfo varname