~ubuntu-branches/ubuntu/trusty/util-linux/trusty-proposed

« back to all changes in this revision

Viewing changes to misc-utils/setterm.1

  • Committer: Package Import Robot
  • Author(s): LaMont Jones
  • Date: 2011-11-03 15:38:23 UTC
  • mto: (4.5.5 sid) (1.6.4)
  • mto: This revision was merged to the branch mainline in revision 85.
  • Revision ID: package-import@ubuntu.com-20111103153823-10sx16jprzxlhkqf
ImportĀ upstreamĀ versionĀ 2.20.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
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
6
 
.\"
7
 
.\" Most options documented by Colin Watson (cjw44@cam.ac.uk)
8
 
.\" Undocumented: -snow, -softscroll, -standout; these are
9
 
.\" commented out in the source
10
 
.\"
11
 
.TH SETTERM 1 "7 January 2000" "Util-Linux 2.10" "Linux Programmer's Manual"
12
 
.SH NAME
13
 
setterm \- set terminal attributes
14
 
.SH SYNOPSIS
15
 
.B setterm
16
 
.RI [ options ]
17
 
.SH DESCRIPTION
18
 
.B setterm
19
 
writes to standard output a character string that will invoke the
20
 
specified terminal capabilities.  Where possible
21
 
.I terminfo
22
 
is consulted to find the string to use.  Some options however (marked
23
 
"virtual consoles only" below) do not correspond to a
24
 
.BR terminfo (5)
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
28
 
are ignored.
29
 
.SH OPTIONS
30
 
For boolean options (\fBon\fP or \fBoff\fP), the default is \fBon\fP.
31
 
.P
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
34
 
\fBwhite\fP.
35
 
.P
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.
39
 
.P
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.
44
 
.TP
45
 
.BR \-term " terminal_name"
46
 
Overrides the TERM environment variable.
47
 
.TP
48
 
.B \-reset
49
 
Displays the terminal reset string, which typically resets the terminal to
50
 
its power on state.
51
 
.TP
52
 
.B \-initialize
53
 
Displays the terminal initialization string, which typically sets the
54
 
terminal's rendering options, and other attributes to the default values.
55
 
.TP
56
 
.BR \-cursor " [" on | off ]
57
 
Turns the terminal's cursor on or off.
58
 
.TP
59
 
.BR \-repeat " [" on | off "] (virtual consoles only)"
60
 
Turns keyboard repeat on or off.
61
 
.TP
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.
67
 
.TP
68
 
.BR \-linewrap " [" on | off "] (virtual consoles only)"
69
 
Turns automatic line-wrapping on or off.
70
 
.TP
71
 
.B \-default
72
 
Sets the terminal's rendering options to the default values.
73
 
.TP
74
 
\fB\-foreground\fP \fI8-color\fP|\fBdefault\fP (virtual consoles only)
75
 
Sets the foreground text color.
76
 
.TP
77
 
\fB\-background\fP \fI8-color\fP|\fBdefault\fP (virtual consoles only)
78
 
Sets the background text color.
79
 
.TP
80
 
\fB\-ulcolor\fP \fI16-color\fP (virtual consoles only)
81
 
Sets the color for underlined characters.
82
 
.TP
83
 
\fB\-hbcolor\fP \fI16-color\fP (virtual consoles only)
84
 
Sets the color for half-bright characters.
85
 
.TP
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.
89
 
.TP
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,
93
 
reverse).
94
 
.TP
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).
99
 
.TP
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).
103
 
.TP
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,
107
 
reverse).
108
 
.TP
109
 
.BR \-underline " [" on | off ]
110
 
Turns underline mode on or off (see \fB\-ulcolor\fP).
111
 
.TP
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.
115
 
.TP
116
 
.BR \-clear " [" all ]
117
 
Clears the screen and "homes" the cursor, as
118
 
.BR clear (1).
119
 
.TP
120
 
.B \-clear rest
121
 
Clears from the current cursor position to the end of the screen.
122
 
.TP
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.
126
 
.TP
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.
130
 
.TP
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.
134
 
.TP
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).
139
 
 
140
 
The
141
 
.B force
142
 
option keeps screen blank even if a key is pressed.
143
 
 
144
 
The
145
 
.B poke
146
 
option unblank the screen.
147
 
.TP
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.
153
 
.TP
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.
157
 
.TP
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.
162
 
.TP
163
 
.BR \-msg " [" on | off "] (virtual consoles only)"
164
 
Enables or disables the sending of kernel \fBprintk()\fP messages to the
165
 
console.
166
 
.TP
167
 
.BR \-msglevel " \fI1-8\fP (virtual consoles only)"
168
 
Sets the console logging level for kernel \fBprintk()\fP messages.  All
169
 
messages strictly more important than this will be printed, so a logging
170
 
level of 0 has the same effect as \fB\-msg on\fP and a logging level of 8
171
 
will print all kernel messages.
172
 
.BR klogd (8)
173
 
may be a more convenient interface to the logging of kernel messages.
174
 
.TP
175
 
.BR "\-powersave on" | vsync
176
 
Puts the monitor into VESA vsync suspend mode.
177
 
.TP
178
 
.B \-powersave hsync
179
 
Puts the monitor into VESA hsync suspend mode.
180
 
.TP
181
 
.B \-powersave powerdown
182
 
Puts the monitor into VESA powerdown mode.
183
 
.TP
184
 
.BR \-powersave " [" off "]"
185
 
Turns off monitor VESA powersaving features.
186
 
.TP
187
 
.BR \-powerdown " [\fI0-60\fP]"
188
 
Sets the VESA powerdown interval in minutes.  Without an argument, defaults
189
 
to 0 (disable powerdown).  If the console is blanked or the monitor is in
190
 
suspend mode, then the monitor will go into vsync suspend mode or powerdown
191
 
mode respectively after this period of time has elapsed.
192
 
.TP
193
 
.BR \-blength " [\fI0-2000\fP]"
194
 
Sets the bell duration in milliseconds.  Without an argument, defaults to 0.
195
 
.TP
196
 
.BR \-bfreq " [\fIfreqnumber\fP]"
197
 
Sets the bell frequency in Hz.  Without an argument, defaults to 0.
198
 
.SH "SEE ALSO"
199
 
.BR tput (1),
200
 
.BR stty (1),
201
 
.BR terminfo (5),
202
 
.BR tty (4)
203
 
.SH BUGS
204
 
Differences between the Minix and Linux versions are not documented.
205
 
.SH AVAILABILITY
206
 
The setterm command is part of the util-linux package and is available from
207
 
ftp://ftp.kernel.org/pub/linux/utils/util-linux/.