began for maemo
[xscreensaver] / xscreensaver / hacks / phosphor.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 "5-May-2004" "X Version 11"
15 .SH NAME
16 phosphor - simulates an old terminal with long-sustain phosphor
17 .SH SYNOPSIS
18 .B phosphor
19 [\-display \fIhost:display.screen\fP] [\-window] [\-root] [\-install]
20 [\-visual \fIvisual\fP] [\-font \fIfont\fP] [\-scale \fIint\fP]
21 [\-ticks \fIint\fP] [\-delay \fIusecs\fP] [\-program \fIcommand\fP]
22 [\-meta] [\-esc] [\-bs] [\-del]
23 .SH DESCRIPTION
24 The \fIphosphor\fP program draws text on the screen in a very large 
25 pixelated font that looks like an old low resolution dumb tty.  The
26 pixels flare and fade out as if the phosphor was very
27 long-sustain.  It is also a fully functional vt100 terminal emulator.
28 .SH OPTIONS
29 .I phosphor
30 accepts the following options:
31 .TP 8
32 .B \-window
33 Draw on a newly-created window.  This is the default.
34 .TP 8
35 .B \-root
36 Draw on the root window.
37 .TP 8
38 .B \-install
39 Install a private colormap for the window.
40 .TP 8
41 .B \-visual \fIvisual\fP\fP
42 Specify which visual to use.  Legal values are the name of a visual class,
43 or the id number (decimal or hex) of a specific visual.
44 .TP 8
45 .B \-font \fIfont-name\fP
46 The X font to use.  Phosphor can take any font and scale it up to pixelate
47 it.  The default is \fIfixed\fP.
48 .TP 8
49 .B \-scale \fIint\fP
50 How much to scale the font up: in other words, the size in real pixels of
51 the simulated pixels.  Default 6.
52 .TP 8
53 .B \-ticks \fIint\fP
54 The number of colors to use when fading to black.  Default 20.
55 .TP 8
56 .B \-delay \fIusecs\fP
57 The speed of the terminal: how long to wait between drawing each character.
58 Default 50000, or about 1/20th second.
59 .TP 8
60 .B \-pty
61 Launch the sub-program under a PTY, so that it can address the screen
62 directly.  This is the default.
63 .TP 8
64 .B \-pipe
65 Launch the sub-program at the end of a pipe: do not let it address the
66 screen directly.
67 .TP 8
68 .B \-program \fIsh-command\fP
69 The command to run to generate the text to display.  This option may
70 be any string acceptable to /bin/sh.  The program will be run at the
71 end of a pty or pipe, and any characters that it prints to \fIstdout\fP
72 will be printed on phosphor's window.  The characters will be printed
73 artificially slowly, as per the \fI\-delay\fP option above.  If the
74 program exits, it will be launched again after 5 seconds.
75
76 For example:
77 .EX
78 phosphor -program 'cat /usr/src/linux*/README'
79 phosphor -program 'ping localhost'
80 phosphor -program 'ps -e'
81 phosphor -program 'od -txC -w6 /dev/random'
82 phosphor -program 'cat /dev/random'
83 phosphor -scale 2 -geom =1280x1024 -program 'top'
84 phosphor -scale 4 -geom =1280x1024 \\
85          -program 'mtr www.kernel.org'
86 phosphor -program 'xemacs -nw -q -f life'
87 phosphor -scale 5 -geom =1280x1024 \\
88          -program 'xemacs -nw -q --eval "(hanoi 5)"'
89 .EE
90 If you have the
91 .BR festival (1)
92 text-to-speech system installed, you can have it read the screen as
93 phosphor prints it:
94 .EX
95 phosphor -program \\
96     'xscreensaver-text | tee /dev/stderr | festival --tts'
97 .EE
98 You can also use \fIphosphor\fP as a lo-fi replacement for the
99 .BR xterm (1)
100 and
101 .BR gnome-terminal (1)
102 terminal emulators:
103 .EX
104 phosphor -delay 0 -program tcsh
105 .EE
106 .TP 8
107 .B \-esc
108 When the user types a key with the Alt or Meta keys held down, send an
109 ESC character first.  This is the default.
110 .TP 8
111 .B \-meta
112 When Meta or Alt are held down, set the high bit on the character instead.
113 .TP 8
114 .B \-del
115 Swap Backspace and Delete.  This is the default.
116 .TP 8
117 .B \-bs
118 Do not swap Backspace and Delete.
119 .SH TERMINAL EMULATION
120 By default, \fIphosphor\fP allocates a pseudo-tty for the sub-process to
121 run under.  This has the desirable side effect that the program will be
122 able to use
123 .BR ioctl (2)
124 to fetch information about terminal parameters and window size, which
125 many programs (such as
126 .BR top (1))
127 need to run properly. \fIphosphor\fP will also set the environment
128 variable \fITERM\fP to \fIvt100\fP in the child process.
129
130 Any characters typed on the phosphor window will be passed along to
131 the sub-process.  (Note that this only works when running in "window"
132 mode, not when running in \fI\-root\fP mode under xscreensaver.)
133 .SH ENVIRONMENT
134 .PP
135 .TP 8
136 .B DISPLAY
137 to get the default host and display number.
138 .TP 8
139 .B XENVIRONMENT
140 to get the name of a resource file that overrides the global resources
141 stored in the RESOURCE_MANAGER property.
142 .TP 8
143 .B TERM
144 to inform the sub-process of the type of terminal emulation.
145 .SH SEE ALSO
146 .BR xscreensaver (1),
147 .BR xscreensaver-text (1),
148 .BR fortune (1),
149 .BR apple2 (MANSUFFIX),
150 .BR starwars (MANSUFFIX),
151 .BR fontglide (MANSUFFIX),
152 .BR ljlatest (MANSUFFIX),
153 .BR dadadodo (1),
154 .BR webcollage (MANSUFFIX),
155 .BR driftnet (1)
156 .BR EtherPEG ,
157 .BR EtherPeek ,
158 .BR console_codes (4).
159 .SH COPYRIGHT
160 Copyright \(co 1999 by Jamie Zawinski.  Permission to use, copy, modify, 
161 distribute, and sell this software and its documentation for any purpose is 
162 hereby granted without fee, provided that the above copyright notice appear 
163 in all copies and that both that copyright notice and this permission notice
164 appear in supporting documentation.  No representations are made about the 
165 suitability of this software for any purpose.  It is provided "as is" without
166 express or implied warranty.
167 .SH AUTHOR
168 Jamie Zawinski <jwz@jwz.org>, 27-Apr-99.
169 Pty and vt100 emulation by Fredrik Tolf <fredrik@dolda2000.com>.