Draw Rectangle

\i D R bits::mode word::width word::height

Parameter Type Range Description
mode bits Bit 0 ... 7 flags for the rectangle properties
width word 1 ... display width width of the rectangle
height word 1 ... display height height of the rectangle

Draws a rectangle starting from the current cursor position to the ending point specified via width and height. The parameter mode allows to set several properties for the rectangle:

Bit Description
0 rounded corners
1 drop shadow
2 surrounded with background color
3 filled with background color
4 use foreground color for filling (bit 3 must be set too)
5 filled with current fill pattern (bits 3 and 4 ignored if set)
6 draw without frame
7 alpha blending for shadow only

Note

Response: [ACK]

Example

\iDR\x3\D50\D30

Draws a rectangle with a width of 50 pixels and a height of 30 pixels. Moreover, the rectangle has rounded corners and a drop shadow.

See also:

Draw Circle
Draw Styled Circle
Get Cursor Position
Set Inverse Mode
Set Line Style
Set Border Color
Set Border Shadow Color
Set Line Thickness
Set Line Caps Style
Set Filling Color
Set Filling Gradient
Set Filling Tile
Set Alpha
Erase Display Area