DECRARA—Reverse Attributes in Rectangular Area

This control function lets you reverse the visual character attributes (bold, blink, reverse video, and underline) of a specified rectangular area in page memory. The select attribute change extent (DECSACE) control function determines whether all or some of the character positions in the rectangle are affected.

Reversing a visual attribute means changing the attribute to its opposite setting, on or off. For example, DECRARA can change characters from bold and not underlined to characters that are underlined and not bold. DECRARA does not change the values of characters, just the visual attributes of those characters.

Available in: VT Level 4 mode only


Pt; Pl; Pb; Pr;
area to be reversed
Ps1; . . . Psn
attributes to reverse


Pt, Pl, Pb, and Pr
define the rectangular area to be reversed.

Pt is the top-line border. Pt must be less than or equal to Pb.
Default: Pt = 1.

Pl is the left-column border. Pl must be less than or equal to Pr.
Default: Pr = 1.

Pb is the bottom-line border.
Default: Pb = last line of the active page.

Pr is the right-column border.
Default: Pr = last column of the active page.

Ps1; . . . Psn
select the visual character attributes to reverse. These values correspond to the values used in the select graphic rendition (SGR) function.

Ps Meaning
0 Reverse all attributes (default).
1 Reverse the bold attribute.
4 Reverse the underline attribute.
5 Reverse the blink attribute.
7 Reverse the negative-image attribute.

DECRARA ignores all other parameter values.

When you use more than one parameter in a command, DECRARA executes them cumulatively in sequence.


The following sequence reverses the blink and underscore attributes of the complete screen:

CSI ; ; ; ; 0; 4; 5; $t

The following sequence reverses all attributes except the blink attribute, from position line 10, column 2 to position line 14, column 45 on the current page:

CSI 10; 2; 14; 45; 1; 4; 7 $ t

Notes on DECRARA