Vizard 8 » Command Index » Vizard modules » vizact » <vizact>.onkeychar
8.0

<vizact>.onkeychar

Register a function to handle key character events

<vizact>.onkeychar(  
char  
func  
*args  
)  
char
The character to handle
func
The function to call when the character is entered
*args
The arguments to pass to the function

Remarks

When the specified character is entered, the function will be called.

Return Value

A vizact.EventFunction object with the following methods:

Method

Description

<event>.setEnabled(val)

Enable/Disable the event function. The associated function will not be called while the event function is disabled. viz.TOGGLE can be used to toggle the state. Event functions are initially enabled.

<event>.getEnabled()

Get the enabled state of the event function.

<event>.remove()

Permanently unregister the event function.

See also

<vizact>.onkeydown
<vizact>.onkeyup
<vizact>.whilekeydown