NAME
cmBind - binds a script to be executed given a particular
event for a particuluar object.
SYNOPSIS
cmBind objectName
cmBind objectName eventSymbol
cmBind objectName eventSymbol script ?-skip numToSkip ? ?-
blankPeriod seconds ?
OPTIONS
-skip
Indicates how many occurances of the event to skip before
executing the associated script.
-blankPeriod
Indicates how many much time to wait after script is exe-
cuted before script can be exectued again.
DESCRIPTION
The cmBind command allows scripts to be associated with par-
ticular event types for particular objects. The command
works very much like the Tk command bind. With only one
argument, cmBind returns the event symbols defined for that
object type. With two arguments, cmBind returns a list of
scripts associated with the object and event type. With
three arguments, cmBind treats the third argument as a
script to be executed when the object in question reports
the specified event type. If the script begins with "+", the
script is appended to the list of scripts to be executed.
Without the "+" symbol, the script replaces any previous
scripts bound to the event type for the object. The optional
argument flags -skip and -blankPeriod can be used to specify
how many events of this type to skip before the script is
executed and how many seconds to wait after the script is
executed before the script is executed again. The parameter
following -blankPeriod can be a floating point number in
order to specify a non-integer amount of time to wait.
Substitution parameters can be used in the script in much
the same way as the bind command. The cmBind mechanism pro-
vides the following substitutions for all object types:
%N
Number of times this event has occured since the last
time this script was executed.
%D
System time of event.
%%
Replaced by one % symbol.
Other substitution parameters are defined on an object type
basis. Check the man page of the object type in question for
those substitution parameters.
KEYWORDS
cm, cmBind, bind, cm toolkit
AUTHORS
Ketan Patel (kpatel@cs.berkeley.edu)