1
.\" Copyright 1990 Gordon Irlam (gordoni@cs.ua.oz.au)
2
.\" Copyright 1992 Rickard E. Faith (faith@cs.unc.edu)
3
.\" Most of this was copied from the source code.
4
.\" Do not restrict distribution.
5
.\" May be distributed under the GNU General Public License
7
.\" Most options documented by Colin Watson (cjw44@cam.ac.uk)
8
.\" Undocumented: -snow, -softscroll, -standout; these are
9
.\" commented out in the source
11
.TH SETTERM 1 "January 2000" "util-linux" "User Commands"
13
setterm \- set terminal attributes
19
writes to standard output a character string that will invoke the
20
specified terminal capabilities. Where possible
22
is consulted to find the string to use. Some options however (marked
23
"virtual consoles only" below) do not correspond to a
25
capability. In this case, if the terminal type is "con" or "linux" the
26
string that invokes the specified capabilities on the PC Minix virtual
27
console driver is output. Options that are not implemented by the terminal
30
For boolean options (\fBon\fP or \fBoff\fP), the default is \fBon\fP.
32
For conciseness, an \fI8-color\fP below is \fBblack\fP, \fBred\fP,
33
\fBgreen\fP, \fByellow\fP, \fBblue\fP, \fBmagenta\fP, \fBcyan\fP, or
36
A \fI16-color\fP is an \fI8-color\fP, \fBgrey\fP, or \fBbright\fP followed
37
by \fBred\fP, \fBgreen\fP, \fByellow\fP, \fBblue\fP, \fBmagenta\fP,
38
\fBcyan\fP, or \fBwhite\fP.
40
The various color options may be set independently, at least at virtual
41
consoles, though the results of setting multiple modes (for example,
42
.BR \-underline " and " \-half-bright )
43
are hardware-dependent.
45
.BR \-term " terminal_name"
46
Overrides the TERM environment variable.
49
Displays the terminal reset string, which typically resets the terminal to
53
Displays the terminal initialization string, which typically sets the
54
terminal's rendering options, and other attributes to the default values.
56
.BR \-cursor " [" on | off ]
57
Turns the terminal's cursor on or off.
59
.BR \-repeat " [" on | off "] (virtual consoles only)"
60
Turns keyboard repeat on or off.
62
.BR \-appcursorkeys " [" on | off "] (virtual consoles only)"
63
Sets Cursor Key Application Mode on or off. When on, ESC O A, ESC O B, etc.
64
will be sent for the cursor keys instead of ESC [ A, ESC [ B, etc. See the
65
"vi and Cursor-Keys" section of the Text-Terminal-HOWTO for how this can
66
cause problems for vi users.
68
.BR \-linewrap " [" on | off "] (virtual consoles only)"
69
Turns automatic line-wrapping on or off.
72
Sets the terminal's rendering options to the default values.
74
\fB\-foreground\fP \fI8-color\fP|\fBdefault\fP (virtual consoles only)
75
Sets the foreground text color.
77
\fB\-background\fP \fI8-color\fP|\fBdefault\fP (virtual consoles only)
78
Sets the background text color.
80
\fB\-ulcolor\fP \fI16-color\fP (virtual consoles only)
81
Sets the color for underlined characters.
83
\fB\-hbcolor\fP \fI16-color\fP (virtual consoles only)
84
Sets the color for half-bright characters.
86
.BR \-inversescreen " [" on | off "] (virtual consoles only)"
87
Inverts the screen colors. Foreground and background are swapped, as are
88
underline and half-brightness.
90
.BR \-bold " [" on | off ]
91
Turns bold (extra bright) mode on or off. Except at a virtual console,
92
\fB\-bold off\fP turns off all attributes (bold, half-brightness, blink,
95
.BR \-half-bright " [" on | off ]
96
Turns dim (half-brightness) mode on or off (see \fB\-hbcolor\fP). Except at
97
a virtual console, \fB\-half-bright off\fP turns off all attributes (bold,
98
half-brightness, blink, reverse).
100
.BR \-blink " [" on | off ]
101
Turns blink mode on or off. Except at a virtual console, \fB\-blink off\fP
102
turns off all attributes (bold, half-brightness, blink, reverse).
104
.BR \-reverse " [" on | off ]
105
Turns reverse video mode on or off. Except at a virtual console,
106
\fB\-reverse off\fP turns off all attributes (bold, half-brightness, blink,
109
.BR \-underline " [" on | off ]
110
Turns underline mode on or off (see \fB\-ulcolor\fP).
112
.BR \-store " (virtual consoles only)"
113
Stores the terminal's current rendering options (foreground and
114
background colors) as the values to be used at reset-to-default.
116
.BR \-clear " [" all ]
117
Clears the screen and "homes" the cursor, as
121
Clears from the current cursor position to the end of the screen.
123
.BR \-tabs " [\fItab1 tab2 tab3\fP ...] (virtual consoles only)"
124
Sets tab stops at the given horizontal cursor positions, in the range 1-160.
125
Without arguments, shows the current tab stop settings.
127
.BR \-clrtabs " [\fItab1 tab2 tab3\fP ...] (virtual consoles only)"
128
Clears tab stops from the given horizontal cursor positions, in the range
129
1-160. Without arguments, clears all tab stops.
131
.BR \-regtabs " [\fI1-160\fP] (virtual consoles only)"
132
Clears all tab stops, then sets a regular tab stop pattern, with one tab
133
every specified number of positions. Without an argument, defaults to 8.
135
.BR \-blank " [\fI0-60\fP|\fBforce\fP|\fBpoke\fP] (virtual consoles only)"
136
Sets the interval of inactivity, in minutes, after which the screen will be
137
automatically blanked (using APM if available). Without an argument, gets the
138
blank status (returns which vt was blanked or zero for unblanked vt).
142
option keeps screen blank even if a key is pressed.
146
option unblank the screen.
148
.BR \-dump " [\fI1-NR_CONS\fP]"
149
Writes a snapshot of the given virtual console (with attributes) to the file
150
specified in the \fB\-file\fP option, overwriting its contents; the default
151
is screen.dump. Without an argument, dumps the current virtual console.
152
Overrides \fB\-append\fP.
154
.BR \-append " [\fI1-NR_CONS\fP]"
155
Like \fB\-dump\fP, but appends to the snapshot file instead of overwriting
156
it. Only works if no \fB\-dump\fP options are given.
158
.BI \-file " dumpfilename"
159
Sets the snapshot file name for any \fB\-dump\fP or \fB\-append\fP options
160
on the same command line. If this option is not present, the default is
161
screen.dump in the current directory. A path name that exceeds system
162
maximum will be truncated, see PATH_MAX from linux/limits.h for the value.
164
.BR \-msg " [" on | off "] (virtual consoles only)"
165
Enables or disables the sending of kernel \fBprintk()\fP messages to the
168
.BR \-msglevel " \fI1-8\fP (virtual consoles only)"
169
Sets the console logging level for kernel \fBprintk()\fP messages. All
170
messages strictly more important than this will be printed, so a logging
171
level of 0 has the same effect as \fB\-msg on\fP and a logging level of 8
172
will print all kernel messages.
174
may be a more convenient interface to the logging of kernel messages.
176
.BR "\-powersave on" | vsync
177
Puts the monitor into VESA vsync suspend mode.
180
Puts the monitor into VESA hsync suspend mode.
182
.B \-powersave powerdown
183
Puts the monitor into VESA powerdown mode.
185
.BR \-powersave " [" off "]"
186
Turns off monitor VESA powersaving features.
188
.BR \-powerdown " [\fI0-60\fP]"
189
Sets the VESA powerdown interval in minutes. Without an argument, defaults
190
to 0 (disable powerdown). If the console is blanked or the monitor is in
191
suspend mode, then the monitor will go into vsync suspend mode or powerdown
192
mode respectively after this period of time has elapsed.
194
.BR \-blength " [\fI0-2000\fP]"
195
Sets the bell duration in milliseconds. Without an argument, defaults to 0.
197
.BR \-bfreq " [\fIfreqnumber\fP]"
198
Sets the bell frequency in Hz. Without an argument, defaults to 0.
201
Output version information and exit.
204
Output help screen and exit.
211
Differences between the Minix and Linux versions are not documented.
213
The setterm command is part of the util-linux package and is available from
214
ftp://ftp.kernel.org/pub/linux/utils/util-linux/.