key, string identifier of a DCL tile
as it appears in the DCL file
argument 2:
call to be made when the tile is
activated
return value:
T on success, nil on failure
description:
This function assigns an action to
evaluate when the user activates the specified tile. The second
argument of this function is the call to be made when the tile is
activated. It can contain a few special strings. When the tile is
activated, the special strings will be replaced. This is a list of
the possible special strings and their runtime replacement: $KEY
key, string identifier of the DCL tile that is activated $VALUE
current value of the tile (see get_tile for more) $REASON an
integer code indicating the kind of activation $X the width of the
tile (see dimx_tile) $Y the height of the tile (see dimy_tile)
$DATA client data attached to the tile (see client_data_tile) About
the String "$REASON": Different types of tiles can be activated in
different ways. For instance, a button tile can be clicked or
double clicked. The special string "$REASON" will be replaced with
an integer code indicating the kind of activation. These are the
possible codes: 1, SELECT, the tile has been selected, most DCL
tiles can only be activated with this code 2, LOST_FOCUS, the tile
lost focus, this reason is generated for edit_box only 3, DRAG, the
tile has been dragged, unused in DCL, defined for historic reasons
4, DOUBLE_CLICK, the tile has been double clicked, generated for
image_button and list_box