http://ftp.x.org/contrib/applications/xscreensaver-2.24.tar.gz
[xscreensaver] / driver / xscreensaver-command.man
1 .de EX          \"Begin example
2 .ne 5
3 .if n .sp 1
4 .if t .sp .5
5 .nf
6 .in +.5i
7 ..
8 .de EE
9 .fi
10 .in -.5i
11 .if n .sp 1
12 .if t .sp .5
13 ..
14 .TH XScreenSaver 1 "30-Jun-98 (2.24)" "X Version 11"
15 .SH NAME
16 xscreensaver-command - control a running xscreensaver process
17 .SH SYNOPSIS
18 .B xscreensaver-command
19 [\-help] \
20 [\-demo] \
21 [\-activate] \
22 [\-deactivate] \
23 [\-cycle] \
24 [\-next] \
25 [\-prev] \
26 [\-exit] \
27 [\-restart] \
28 [\-lock] \
29 [\-version] \
30 [\-time]
31 .SH DESCRIPTION
32 The \fIxscreensaver\-command\fP program controls a running \fIxscreensaver\fP
33 process by sending it client-messages.
34
35 .BR xscreensaver (1)
36 has a client-server model: the xscreensaver process is a
37 daemon that runs in the background; it is controlled by the 
38 foreground \fIxscreensaver-command\fP program.
39 .SH OPTIONS
40 .I xscreensaver-command
41 accepts the following command-line options:
42 .TP 8
43 .B \-help
44 Prints a brief summary of command-line options.
45 .TP 8
46 .B \-demo
47 Cause the screensaver to enter its interactive demo mode, in which one
48 can experiment with the various graphics hacks available.  See
49 .BR xscreensaver (1)
50 for details.
51 .TP 8
52 .B \-activate
53 Tell xscreensaver to turn on immediately (that is, blank the screen, as if
54 the user had been idle for long enough.)  The screensaver will deactivate as
55 soon as there is any user activity, as usual.
56
57 It is useful to run this from a menu; you may wish to run it as
58 .EX
59 sleep 5 ; xscreensaver-command -activate
60 .EE
61 to be sure that you have time to remove your hand from the mouse before
62 the screensaver comes on.  (Because if you jiggle the mouse, xscreensaver
63 will notice, and deactivate.)
64 .TP 8
65 .B \-deactivate
66 If the screensaver is active (the screen is blanked), this command will
67 deactivate it just as if there had been keyboard or mouse activity.  
68 If locking is enabled, then the screensaver will prompt for a password
69 as usual.
70 .TP 8
71 .B \-cycle
72 If the screensaver is active (the screen is blanked), then stop the current
73 graphics demo and run a new one (chosen randomly.)
74 .TP 8
75 .B \-next
76 This is like either \fI\-activate\fP or \fI\-cycle\fP, depending on which is
77 more appropriate, except that the graphics hack that will be run is the next
78 one in the list, instead of a randomly-chosen one.  In other words, 
79 repeatedly executing -next will cause the xscreensaver process to invoke each
80 graphics demo sequentially.  (Though using the \fI\-demo\fP option is probably
81 an easier way to accomplish that.)
82 .TP 8
83 .B \-prev
84 This is like \fI\-next\fP, but cycles in the other direction.
85 .TP 8
86 .B \-exit
87 Causes the xscreensaver process to exit gracefully.  This is roughly the same
88 as killing the process with
89 .BR kill (1),
90 but it is easier, since you don't need to first figure out the pid.  
91
92 .B Warning:
93 never use \fIkill -9\fP with \fIxscreensaver\fP while the screensaver is
94 active.  If you are using a virtual root window manager, that can leave
95 things in an inconsistent state, and you may need to restart your window
96 manager to repair the damage.
97 .TP 8
98 .B \-restart
99 Causes the screensaver process to exit and then restart with the same command
100 line arguments as last time.  Do this after you've changed the resource
101 database, to cause xscreensaver to notice the changes.
102
103 If the screensaver is run from \fIxdm(1)\fP (that is, it is already running
104 before you log in) then you may want to issue the \fI\-restart\fP command from
105 one of your startup scripts, so that the screensaver gets your resource
106 settings instead of the default ones.
107 .TP 8
108 .B \-lock
109 Tells the running xscreensaver process to lock the screen immediately.  
110 This is like \fI\-activate\fP, but forces locking as well, even if locking
111 is not the default (that is, even if xscreensaver's \fIlock\fP resource is
112 false, and even if the \fIlockTimeout\fP resource is non-zero.)
113 .TP 8
114 .B \-version
115 Prints the version of xscreensaver that is currently running on the display:
116 that is, the actual version number of the running xscreensaver background 
117 process, rather than the version number of xscreensaver-command.  (To see
118 the version number of \fIxscreensaver-command\fP itself, use 
119 the \fI\-help\fP option.)
120 .TP 8
121 .B \-time
122 Prints the time at which the screensaver last activated or 
123 deactivated (roughly, how long the user has been idle or non-idle: but 
124 not quite, since it only tells you when the screen became blanked or
125 un-blanked.)
126 .SH ENVIRONMENT
127 .PP
128 .TP 8
129 .B DISPLAY
130 to get the host and display number of the screen whose saver is
131 to be manipulated.
132 .TP 8
133 .B PATH
134 to find the executable to restart (for the \fI\-restart\fP command).  
135 Note that this variable is consulted in the environment of 
136 the \fIxscreensaver\fP process, not the \fIxscreensaver-command\fP process.
137 .SH UPGRADES
138 The latest version of
139 .BR xscreensaver (1)
140 and \fIxscreensaver\-command\fP can always be found at 
141 http://people.netscape.com/jwz/xscreensaver/
142 .SH "SEE ALSO"
143 .BR X (1),
144 .BR xscreensaver (1)
145 .SH BUGS
146 Some diagnostics are reported on the stderr of the \fIxscreensaver\fP
147 process, not this process, so the caller of \fIxscreensaver-command\fP
148 may not see the error messages.
149 .SH COPYRIGHT
150 Copyright \(co 1992, 1993, 1997, 1998
151 by Jamie Zawinski.  Permission to use, copy, modify, distribute, and sell
152 this software and its documentation for any purpose is hereby granted without
153 fee, provided that the above copyright notice appear in all copies and that
154 both that copyright notice and this permission notice appear in supporting
155 documentation.  No representations are made about the suitability of this
156 software for any purpose.  It is provided "as is" without express or implied
157 warranty.
158 .SH AUTHOR
159 Jamie Zawinski <jwz@netscape.com>, 13-aug-92.
160
161 Please let me know if you find any bugs or make any improvements.