DialogAddXFlags Function (Macro)

AMS 2.00 or higher dialogs.h

HANDLE DialogAddXFlags (HANDLE Handle, short flags, unsigned short xFlags1, unsigned short xFlags2, unsigned short xFlags3, unsigned short xFlags4);

Adds extended dialog properties into a dialog box.

DialogAddXFlags adds extended dialog properties to the dialog structure associated with the handle Handle.
The XFLAGS item defines an array of four extended unsigned short flags (i.e. xFlags1, xFlags2, xFlags3, xFlags4.) Currently only xFlags1 is used: the three remaining values should always be set to zero for future compatibility.

The order of item creation is very important, as it automatically gives each item an identification number (the first created item will get an identification number of 0, the second one will get 1, and so on). Every function that creates an item (i.e. every function beginning with 'DialogAdd...') will increase this identification number.

The parameter xFlags1 may contain a combination of the following flags, defined in the DialogXFlags enumeration:
XF_ALLOW_VARLINK Setting this extended xflag allows all EDIT (=request) items in the dialog box to allow the [VAR-LINK] key to be activated within the dialog box and to paste results to the edit item. If this xflag or XF_VARLINK_SELECT_ONLY is not set, then when [VAR-LINK] is pressed in a dialog box, the dialog will be closed and VAR-LINK will be activated.
XF_NO_ALPHA_LOCK On the TI-89, Alpha-Lock is turned on for all dialog boxes with edit items. Setting this extended xflag disables this feature.
XF_VARLINK_SELECT_ONLY This xflag is similar to XF_ALLOW_VARLINK except thet the user may not make any variable changes inside VAR-LINK (like deleting, copying, renaming, or locking variables).
XF_TE_REPAINT This xflag is unknown for the moment. Do not use.

The parameter flags can be zero or DF_SCREEN_SAVE if you wish the dialog code to save the area underneath the dialog box when it is started and to return DB_MEMFULL if it cannot. Note that if you use this flag, the item must be the first one to be created. These flags are defined in the DialogFlags enumeration.

DialogAddXFlags returns H_NULL in case of an error, may return DB_MEMFULL if you used DF_SCREEN_SAVE, else returns Handle. This routine (as well as all other 'DialogAdd...' routines) may cause heap compression.

DialogAddXFlags is in fact a macro created for your convenience. It calls DialogAdd with D_XFLAGS as the ItemType parameter and with zero passed to the x and y parameters. (These parameters are ignored when you use D_XFLAGS as the ItemType.)


Uses: DialogAdd