setcolor(1)


setcolor, setcolour -- set screen color

Synopsis

setcolor [-nbrgopc] argument [argument]

setcolour [-nbrgopc] argument [argument]

Description

setcolor and setcolour allow the user to set the screen to a specific color. Both foreground and background colors can be set independently in a range of 16 colors. setcolor can also set the reverse video and graphics character colors. setcolor with no arguments produces a usage message that displays all available colors, then resets the screen to its previous state.

For example, the following strings are possible colors:

blue magenta brown black
lt_blue lt_magenta yellow gray
cyan white green red
lt_cyan hi_white lt_green lt_red

 blue      magenta      brown      black
 lt_blue   lt_magenta   yellow     gray
 cyan      white        green      red
 lt_cyan   hi_white     lt_green   lt_red

Options

The following options are available for setcolor and setcolour. In the arguments below, color is taken from the above list.

-n
Sets the screen to normal white characters on black background.

color [color]
Sets the foreground to the first color. Sets background to second color if a second color choice is specified.

-b color
Sets the background to the specified color.

-r color color
Set the foreground reverse video characters to the first color. Set reverse video characters' background to second color.

-g color color
Set the foreground graphics characters to the first color. Set graphics characters' background to second color.

-o color
Sets the color of the screen border (over scan region). To reset border color, use -o black.

-p pitch duration
Set the pitch and duration of the bell. Pitch is the period in microseconds, and duration is measured in fifths of a second. When using this option, a <Ctrl>-G (bell) must be echoed to the screen for the command to work. For example:
   setcolor -p 2500 2
   echo ^G

-cfirst last
Set the first and last scan lines of the cursor.

Notices

The ability of setcolor to set any of these described functions is ultimately dependent on the ability of devices to support them. For example, the -o option does not work on the Color Graphics Adapter (CGA).

setcolor emits an escape sequence that may or may not have an effect on monochrome devices.

Occasionally changing the screen color can help prolong the life of your monitor.


© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004