Author: Jacob at home #1

The tgraph::event Command

This Tcl command manages user defined events for tgraph objects. It takes one of three forms:

>     package require tgraph
>     set ec [tgraph::event define]
>     set bv [tgraph::event isdefined $ec]
>     tgraph::event undefine $ec

The first form defines and returns a new event code. In the above example the returned event code is stored in the variable ec. If there are no free event codes available (all available event codes have already been defined) then the command causes an error.

The second form determines whether a value represents a defined event code. Since the value of our previously defined event is stored in ec, the above call is expected to return true.

The third form undefines the event code stored in ec. If ec does not represent a valid event code then the command causes an error.

At present, there is no way to use these event codes to fire events for tgraph objects. This facility will be added in a subsequent release of e4Graph.