Draws a rectangle in the port's background color. This function is deprecated.
graphics-ports
clear-rectangle port x y width height
port⇩ |
A graphics port. |
x⇩ |
A real number. |
y⇩ |
A real number. |
width⇩ |
A real number. |
height⇩ |
A real number. |
The function clear-rectangle
(deprecated) draws the rectangle specified by x, y, width, and height in port using the port's background color. All other graphics-state parameters are ignored.
clear-rectangle
is deprecated because it ignores the graphics state args, which means it does not work properly with other drawing functions. In particular, it does not work properly in the display-callback of output-pane.
Use instead:
(draw-rectangle pane x y width height :filled t :foreground color :compositing-mode :copy :shape-mode :plain)
compositing-mode is needed only when the color has alpha.
foreground is needed only if it is different from the foreground in the graphics state.
Note that draw-rectangle does take into account the transformation in the graphics-state.
CAPI User Guide and Reference Manual (Windows version) - 01 Dec 2021 19:34:15