14 .TH XScreenSaver 1 "24-Oct-98 (3.01)" "X Version 11"
16 xscreensaver-command - control a running xscreensaver process
18 .B xscreensaver-command
34 The \fIxscreensaver\-command\fP program controls a running \fIxscreensaver\fP
35 process by sending it client-messages.
38 has a client-server model: the xscreensaver process is a
39 daemon that runs in the background; it is controlled by other
40 foreground programs such as \fIxscreensaver-command\fP and
41 .BR xscreensaver\-demo (1).
43 This program, \fIxscreensaver-command\fP, is a command-line-oriented tool; the
44 .BR xscreensaver\-demo (1).
45 program is a graphical tool.
47 .I xscreensaver-command
48 accepts the following command-line options:
51 Prints a brief summary of command-line options.
54 This just launches the
55 .BR xscreensaver\-demo (1)
56 program, in which one can experiment with the various graphics hacks
57 available, and edit parameters.
59 .B \-demo \fP\fInumber\fP
60 When the \fI\-demo\fP option is followed by an integer, it instructs
61 the \fIxscreensaver\fP daemon to run that hack, and wait for the user
62 to click the mouse before deactivating (i.e., mouse motion does not
63 deactivate.) This is the mechanism by which
64 .BR xscreensaver\-demo (1)
67 daemon. (The first hack in the list is numbered 1, not 0.)
70 Like the no-argument form of \fI\-demo\fP, but brings up that program's
71 Preferences panel by default.
74 Tell xscreensaver to turn on immediately (that is, blank the screen, as if
75 the user had been idle for long enough.) The screensaver will deactivate as
76 soon as there is any user activity, as usual.
78 It is useful to run this from a menu; you may wish to run it as
80 sleep 5 ; xscreensaver-command -activate
82 to be sure that you have time to take your hand off the mouse before
83 the screensaver comes on. (Because if you jiggle the mouse, xscreensaver
84 will notice, and deactivate.)
87 If the screensaver is active (the screen is blanked), this command will
88 deactivate it just as if there had been keyboard or mouse activity.
89 If locking is enabled, then the screensaver will prompt for a password
93 If the screensaver is active (the screen is blanked), then stop the current
94 graphics demo and run a new one (chosen randomly.)
97 This is like either \fI\-activate\fP or \fI\-cycle\fP, depending on which is
98 more appropriate, except that the graphics hack that will be run is the next
99 one in the list, instead of a randomly-chosen one. In other words,
100 repeatedly executing -next will cause the xscreensaver process to invoke each
101 graphics demo sequentially. (Though using the \fI\-demo\fP option is probably
102 an easier way to accomplish that.)
105 This is like \fI\-next\fP, but cycles in the other direction.
107 .B \-select \fInumber\fP
108 Like \fI\-activate\fP, but runs the \fIN\fPth element in the list of hacks.
109 By knowing what is in the \fIprograms\fP list, and in what order, you can use
110 this to activate the screensaver with a particular graphics demo. (The first
111 element in the list is numbered 1, not 0.)
114 Causes the xscreensaver process to exit gracefully. This is roughly the same
115 as killing the process with
117 but it is easier, since you don't need to first figure out the pid.
120 never use \fIkill -9\fP with \fIxscreensaver\fP while the screensaver is
121 active. If you are using a virtual root window manager, that can leave
122 things in an inconsistent state, and you may need to restart your window
123 manager to repair the damage.
126 Tells the running xscreensaver process to lock the screen immediately.
127 This is like \fI\-activate\fP, but forces locking as well, even if locking
128 is not the default (that is, even if xscreensaver's \fIlock\fP resource is
129 false, and even if the \fIlockTimeout\fP resource is non-zero.)
131 Note that locking doesn't work unless the \fIxscreensaver\fP process is
137 Prints the version of xscreensaver that is currently running on the display:
138 that is, the actual version number of the running xscreensaver background
139 process, rather than the version number of xscreensaver-command. (To see
140 the version number of \fIxscreensaver-command\fP itself, use
141 the \fI\-help\fP option.)
144 Prints the time at which the screensaver last activated or
145 deactivated (roughly, how long the user has been idle or non-idle: but
146 not quite, since it only tells you when the screen became blanked or
150 Causes the screensaver process to exit and then restart with the same command
151 line arguments as last time. Do this after you've changed the resource
152 database, to cause xscreensaver to notice the changes.
155 if you have a \fI.xscreensaver\fP file, this might not do what you
156 expect. You're probably better off killing the existing
157 xscreensaver (with \fIxscreensaver\-command -exit\fP) and then
160 The important point is, you need to make sure that the xscreensaver
161 process is running as you. If it's not, it won't be reading the
162 right \fI.xscreensaver\fP file.
164 If an error occurs while communicating with the \fIxscreensaver\fP daemon, or
165 if the daemon reports an error, a diagnostic message will be printed to
166 stderr, and \fIxscreensaver-command\fP will exit with a non-zero value. If
167 the command is accepted, an indication of this will be printed to stdout, and
168 the exit value will be zero.
173 to get the host and display number of the screen whose saver is
177 to find the executable to restart (for the \fI\-restart\fP command).
178 Note that this variable is consulted in the environment of
179 the \fIxscreensaver\fP process, not the \fIxscreensaver-command\fP process.
181 The latest version of
183 and related tools can always be found at http://www.jwz.org/xscreensaver/
187 .BR xscreensaver\-demo (1)
189 Copyright \(co 1992, 1993, 1997, 1998
190 by Jamie Zawinski. Permission to use, copy, modify, distribute, and sell
191 this software and its documentation for any purpose is hereby granted without
192 fee, provided that the above copyright notice appear in all copies and that
193 both that copyright notice and this permission notice appear in supporting
194 documentation. No representations are made about the suitability of this
195 software for any purpose. It is provided "as is" without express or implied
198 Jamie Zawinski <jwz@jwz.org>, 13-aug-92.
200 Please let me know if you find any bugs or make any improvements.