NAME

XtAppAddSignal, XtRemoveSignal, XtNoticeSignal - register and remove a signal source

SYNTAX

XtSignalId XtAppAddSignal(XtAppContext _a_p_p___c_o_n_t_e_x_t, XtSignalCallbackProc _p_r_o_c, XtPointer _c_l_i_e_n_t___d_a_t_a); void XtRemoveSignal(XtSignalId _i_d); void XtNoticeSignal(XtSignalId _i_d);

ARGUMENTS

_a_p_p___c_o_n_t_e_x_t Specifies the application context.
_c_l_i_e_n_t___d_a_t_a Specifies the argument that is to be passed to the specified procedure
when a signal has been raised.
_i_d Specifies the ID returned from the corresponding
_X_t_A_p_p_A_d_d_S_i_g_n_a_l call.
_p_r_o_c Specifies the procedure that is to be called when the signal has been
raised.

DESCRIPTION

The _X_t_A_p_p_A_d_d_S_i_g_n_a_l function initiates a mechanism for handling signals within the context of the Intrinsics. Prior to establishing an operating system dependent signal handler the application may call _X_t_A_p_p_A_d_d_S_i_g_n_a_l and store the returned _i_d in a place accessible to the signal handler.

Upon receipt of a signal from the operating system, the application may call _X_t_N_o_t_i_c_e_S_i_g_n_a_l passing the _i_d returned by the call to _X_t_A_p_p_A_d_d_S_i_g_n_a_l.

_X_t_N_o_t_i_c_e_S_i_g_n_a_l is the only Intrinsics function that can safely be called from a signal handler. If _X_t_N_o_t_i_c_e_S_i_g_n_a_l is called multiple times before the Intrinsics are able to invoke the registered callback, the callback is only called once. Logically the Intrinsics maintain ``pending'' for each registered callback. This flag is initially _F_a_l_s_e and is set to _T_r_u_e by _X_t_N_o_t_i_c_e_S_i_g_n_a_l; the Intrinsics invoke the callback whenever the flag is _T_r_u_e, and the flag is set to _F_a_l_s_e just before the callback is invoked.

The _X_t_R_e_m_o_v_e_S_i_g_n_a_l function is called to remove the specified Intrinsics signal handler. The client should disable the source of the signal before calling _X_t_R_e_m_o_v_e_S_i_g_n_a_l.

SEE ALSO

XtAppAddTimeOut(3Xt),XtAppAddInput(3Xt),XtAppAddWorkProc(3Xt)
_X _T_o_o_l_k_i_t _I_n_t_r_i_n_s_i_c_s _- _C _L_a_n_g_u_a_g_e _I_n_t_e_r_f_a_c_e
_X_l_i_b _- _C _L_a_n_g_u_a_g_e _X _I_n_t_e_r_f_a_c_e