NAME

XSetScreenSaver, XForceScreenSaver, XActivateScreenSaver, XResetScreenSaver, XGetScreenSaver - manipulate the screen saver

SYNTAX

int XSetScreenSaver(Display *_d_i_s_p_l_a_y, int _t_i_m_e_o_u_t, int _i_n_t_e_r_v_a_l, int _p_r_e_f_e_r___b_l_a_n_k_i_n_g, int _a_l_l_o_w___e_x_p_o_s_u_r_e_s); int XForceScreenSaver(Display *_d_i_s_p_l_a_y, int _m_o_d_e); int XActivateScreenSaver(Display *_d_i_s_p_l_a_y); int XResetScreenSaver(Display *_d_i_s_p_l_a_y); int XGetScreenSaver(Display *_d_i_s_p_l_a_y, int *_t_i_m_e_o_u_t___r_e_t_u_r_n, int *_i_n_t_e_r_v_a_l___r_e_t_u_r_n, int *_p_r_e_f_e_r___b_l_a_n_k_i_n_g___r_e_t_u_r_n, int *_a_l_l_o_w___e_x_p_o_s_u_r_e_s___r_e_t_u_r_n);

ARGUMENTS

_a_l_l_o_w___e_x_p_o_s_u_r_e_s Specifies the screen save control values.
You can pass _D_o_n_t_A_l_l_o_w_E_x_p_o_s_u_r_e_s, _A_l_l_o_w_E_x_p_o_s_u_r_e_s, or _D_e_f_a_u_l_t_E_x_p_o_s_u_r_e_s.
_a_l_l_o_w___e_x_p_o_s_u_r_e_s___r_e_t_u_r_n Returns the current screen save control value
(_D_o_n_t_A_l_l_o_w_E_x_p_o_s_u_r_e_s, _A_l_l_o_w_E_x_p_o_s_u_r_e_s, or _D_e_f_a_u_l_t_E_x_p_o_s_u_r_e_s).
_d_i_s_p_l_a_y Specifies the connection to the X server.
_i_n_t_e_r_v_a_l Specifies the interval, in seconds, between screen saver alterations.
_i_n_t_e_r_v_a_l___r_e_t_u_r_n Returns the interval between screen saver invocations.
_m_o_d_e Specifies the mode that is to be applied.
You can pass _S_c_r_e_e_n_S_a_v_e_r_A_c_t_i_v_e or _S_c_r_e_e_n_S_a_v_e_r_R_e_s_e_t.
_p_r_e_f_e_r___b_l_a_n_k_i_n_g Specifies how to enable screen blanking.
You can pass _D_o_n_t_P_r_e_f_e_r_B_l_a_n_k_i_n_g, _P_r_e_f_e_r_B_l_a_n_k_i_n_g, or _D_e_f_a_u_l_t_B_l_a_n_k_i_n_g.
_p_r_e_f_e_r___b_l_a_n_k_i_n_g___r_e_t_u_r_n Returns the current screen blanking preference
(_D_o_n_t_P_r_e_f_e_r_B_l_a_n_k_i_n_g, _P_r_e_f_e_r_B_l_a_n_k_i_n_g, or _D_e_f_a_u_l_t_B_l_a_n_k_i_n_g).
_t_i_m_e_o_u_t Specifies the timeout, in seconds, until the screen saver turns on.
_t_i_m_e_o_u_t___r_e_t_u_r_n Returns the timeout, in seconds, until the screen saver turns on.

DESCRIPTION

Timeout and interval are specified in seconds. A timeout of 0 disables the screen saver (but an activated screen saver is not deactivated), and a timeout of -1 restores the default. Other negative values generate a _B_a_d_V_a_l_u_e error. If the timeout value is nonzero, _X_S_e_t_S_c_r_e_e_n_S_a_v_e_r enables the screen saver. An interval of 0 disables the random-pattern motion. Both values are limited to a 16-bit signed integer range by the wire protocol, despite the C prototype. If no input from devices (keyboard, mouse, and so on) is generated for the specified number of timeout seconds once the screen saver is enabled, the screen saver is activated.

For each screen, if blanking is preferred and the hardware supports video blanking, the screen simply goes blank. Otherwise, if either exposures are allowed or the screen can be regenerated without sending _E_x_p_o_s_e events to clients, the screen is tiled with the root window background tile randomly re-origined each interval seconds. Otherwise, the screens' state do not change, and the screen saver is not activated. The screen saver is deactivated, and all screen states are restored at the next keyboard or pointer input or at the next call to _X_F_o_r_c_e_S_c_r_e_e_n_S_a_v_e_r with mode _S_c_r_e_e_n_S_a_v_e_r_R_e_s_e_t.

If the server-dependent screen saver method supports periodic change, the interval argument serves as a hint about how long the change period should be, and zero hints that no periodic change should be made. Examples of ways to change the screen include scrambling the colormap periodically, moving an icon image around the screen periodically, or tiling the screen with the root window background tile, randomly re-origined periodically.

_X_S_e_t_S_c_r_e_e_n_S_a_v_e_r can generate a _B_a_d_V_a_l_u_e error.

If the specified mode is _S_c_r_e_e_n_S_a_v_e_r_A_c_t_i_v_e and the screen saver currently is deactivated, _X_F_o_r_c_e_S_c_r_e_e_n_S_a_v_e_r activates the screen saver even if the screen saver had been disabled with a timeout of zero. If the specified mode is _S_c_r_e_e_n_S_a_v_e_r_R_e_s_e_t and the screen saver currently is enabled, _X_F_o_r_c_e_S_c_r_e_e_n_S_a_v_e_r deactivates the screen saver if it was activated, and the activation timer is reset to its initial state (as if device input had been received).

_X_F_o_r_c_e_S_c_r_e_e_n_S_a_v_e_r can generate a _B_a_d_V_a_l_u_e error.

The _X_A_c_t_i_v_a_t_e_S_c_r_e_e_n_S_a_v_e_r function activates the screen saver.

The _X_R_e_s_e_t_S_c_r_e_e_n_S_a_v_e_r function resets the screen saver.

The _X_G_e_t_S_c_r_e_e_n_S_a_v_e_r function gets the current screen saver values.

DIAGNOSTICS

_B_a_d_V_a_l_u_e
Some numeric value falls outside the range of values accepted by the request. Unless a specific range is specified for an argument, the full range defined by the argument's type is accepted. Any argument defined as a set of alternatives can generate this error.

SEE ALSO

_X_l_i_b _- _C _L_a_n_g_u_a_g_e _X _I_n_t_e_r_f_a_c_e