XScreenSaver(1) XScreenSaver(1) NNAAMMEE xscreensaver-command - control a running xscreensaver pro- cess SSYYNNOOPPSSIISS xxssccrreeeennssaavveerr--ccoommmmaanndd [-help] [-demo] [-prefs] [-activate] [-deactivate] [-cycle] [-next] [-prev] [-select _n] [-exit] [-restart] [-lock] [-throttle] [-unthrottle] [-version] [-time] DDEESSCCRRIIPPTTIIOONN The _x_s_c_r_e_e_n_s_a_v_e_r_-_c_o_m_m_a_n_d program controls a running _x_s_c_r_e_e_n_s_a_v_e_r process by sending it client-messages. xxssccrreeeennssaavveerr(1) has a client-server model: the xscreen- saver process is a daemon that runs in the background; it is controlled by other foreground programs such as _x_s_c_r_e_e_n_s_a_v_e_r_-_c_o_m_m_a_n_d and xxssccrreeeennssaavveerr--ddeemmoo(1). This program, _x_s_c_r_e_e_n_s_a_v_e_r_-_c_o_m_m_a_n_d, is a command-line-ori- ented tool; the xxssccrreeeennssaavveerr--ddeemmoo(1). program is a graph- ical tool. OOPPTTIIOONNSS _x_s_c_r_e_e_n_s_a_v_e_r_-_c_o_m_m_a_n_d accepts the following command-line options: --hheellpp Prints a brief summary of command-line options. --ddeemmoo This just launches the xxssccrreeeennssaavveerr--ddeemmoo(1) pro- gram, in which one can experiment with the various graphics hacks available, and edit parameters. --ddeemmoo _n_u_m_b_e_r When the _-_d_e_m_o option is followed by an integer, it instructs the _x_s_c_r_e_e_n_s_a_v_e_r daemon to run that hack, and wait for the user to click the mouse before deactivating (i.e., mouse motion does not deactivate.) This is the mechanism by which xxssccrreeeennssaavveerr--ddeemmoo(1) communicates with the xxssccrreeeennssaavveerr(1) daemon. (The first hack in the list is numbered 1, not 0.) --pprreeffss Like the no-argument form of _-_d_e_m_o, but brings up that program's Preferences panel by default. --aaccttiivvaattee Tell xscreensaver to turn on immediately (that is, blank the screen, as if the user had been idle for long enough.) The screensaver will deactivate as soon as there is any user activity, as usual. It is useful to run this from a menu; you may wish X Version 11 20-Jun-99 (3.15) 1 XScreenSaver(1) XScreenSaver(1) to run it as sleep 5 ; xscreensaver-command -activate to be sure that you have time to take your hand off the mouse before the screensaver comes on. (Because if you jiggle the mouse, xscreensaver will notice, and deactivate.) --ddeeaaccttiivvaattee If the screensaver is active (the screen is blanked), this command will deactivate it just as if there had been keyboard or mouse activity. If locking is enabled, then the screensaver will prompt for a password as usual. --ccyyccllee If the screensaver is active (the screen is blanked), then stop the current graphics demo and run a new one (chosen randomly.) --nneexxtt This is like either _-_a_c_t_i_v_a_t_e or _-_c_y_c_l_e, depending on which is more appropriate, except that the graphics hack that will be run is the next one in the list, instead of a randomly-chosen one. In other words, repeatedly executing -next will cause the xscreensaver process to invoke each graphics demo sequentially. (Though using the _-_d_e_m_o option is probably an easier way to accomplish that.) --pprreevv This is like _-_n_e_x_t, but cycles in the other direc- tion. --sseelleecctt _n_u_m_b_e_r Like _-_a_c_t_i_v_a_t_e, but runs the _Nth element in the list of hacks. By knowing what is in the _p_r_o_g_r_a_m_s list, and in what order, you can use this to acti- vate the screensaver with a particular graphics demo. (The first element in the list is numbered 1, not 0.) --eexxiitt Causes the xscreensaver process to exit grace- fully. This is roughly the same as killing the process with kkiillll(1), but it is easier, since you don't need to first figure out the pid. WWaarrnniinngg:: never use _k_i_l_l _-_9 with _x_s_c_r_e_e_n_s_a_v_e_r while the screensaver is active. If you are using a virtual root window manager, that can leave things in an inconsistent state, and you may need to restart your window manager to repair the damage. --lloocckk Tells the running xscreensaver process to lock the screen immediately. This is like _-_a_c_t_i_v_a_t_e, but forces locking as well, even if locking is not the X Version 11 20-Jun-99 (3.15) 2 XScreenSaver(1) XScreenSaver(1) default (that is, even if xscreensaver's _l_o_c_k resource is false, and even if the _l_o_c_k_T_i_m_e_o_u_t resource is non-zero.) Note that locking doesn't work unless the _x_s_c_r_e_e_n_- _s_a_v_e_r process is running as you. See xxssccrreeeenn-- ssaavveerr(1) for details. --tthhrroottttllee Temporarily switch to ``blank screen'' mode, and don't run any display modes at all, until the screensaver is next de-activated. This is useful if you're using a machine remotely, and you find that some display modes are using too much CPU. (If you want to do this _p_e_r_m_a_n_e_n_t_l_y, that is, you want the screen saver to only blank the screen and not run demos at all, then set the _p_r_o_g_r_a_m_s resource to an empty list: See xxssccrreeeennssaavveerr(1) for details.) --uunntthhrroottttllee Turn `-throttle' mode off and resume normal behav- ior. --vveerrssiioonn Prints the version of xscreensaver that is cur- rently running on the display: that is, the actual version number of the running xscreensaver back- ground process, rather than the version number of xscreensaver-command. (To see the version number of _x_s_c_r_e_e_n_s_a_v_e_r_-_c_o_m_m_a_n_d itself, use the _-_h_e_l_p option.) --ttiimmee Prints the time at which the screensaver last activated or deactivated (roughly, how long the user has been idle or non-idle: but not quite, since it only tells you when the screen became blanked or un-blanked.) --rreessttaarrtt Causes the screensaver process to exit and then restart with the same command line arguments as last time. Do this after you've changed the resource database, to cause xscreensaver to notice the changes. WWaarrnniinngg:: if you have a _._x_s_c_r_e_e_n_s_a_v_e_r file, this might not do what you expect. You're probably better off killing the existing xscreensaver (with _x_s_c_r_e_e_n_s_a_v_e_r_-_c_o_m_m_a_n_d _-_e_x_i_t) and then launching it again. The important point is, you need to make sure that X Version 11 20-Jun-99 (3.15) 3 XScreenSaver(1) XScreenSaver(1) the xscreensaver process is running as you. If it's not, it won't be reading the right _._x_s_c_r_e_e_n_- _s_a_v_e_r file. DDIIAAGGNNOOSSTTIICCSS If an error occurs while communicating with the _x_s_c_r_e_e_n_- _s_a_v_e_r daemon, or if the daemon reports an error, a diag- nostic message will be printed to stderr, and _x_s_c_r_e_e_n_- _s_a_v_e_r_-_c_o_m_m_a_n_d will exit with a non-zero value. If the command is accepted, an indication of this will be printed to stdout, and the exit value will be zero. EENNVVIIRROONNMMEENNTT DDIISSPPLLAAYY to get the host and display number of the screen whose saver is to be manipulated. PPAATTHH to find the executable to restart (for the _-_r_e_s_t_a_r_t command). Note that this variable is consulted in the environment of the _x_s_c_r_e_e_n_s_a_v_e_r process, not the _x_s_c_r_e_e_n_s_a_v_e_r_-_c_o_m_m_a_n_d process. UUPPGGRRAADDEESS The latest version of xxssccrreeeennssaavveerr(1) and related tools can always be found at http://www.jwz.org/xscreensaver/ SSEEEE AALLSSOO XX(1), xxssccrreeeennssaavveerr(1) xxssccrreeeennssaavveerr--ddeemmoo(1) CCOOPPYYRRIIGGHHTT Copyright (C) 1992, 1993, 1997, 1998, 1999 by Jamie Zawin- ski. Permission to use, copy, modify, distribute, and sell this software and its documentation for any purpose is hereby granted without fee, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in sup- porting documentation. No representations are made about the suitability of this software for any purpose. It is provided "as is" without express or implied warranty. AAUUTTHHOORR Jamie Zawinski , 13-aug-92. Please let me know if you find any bugs or make any improvements. X Version 11 20-Jun-99 (3.15) 4