The InvertLine function applies an inversion effect to a line segment within an existing memory surface. The blend parameters of the effect can be set by calling SetInvert.
Parameter | Description |
---|---|
x |
X coordinate of the line segment's enclosing rectangle, in pixels. |
y |
Y coordinate of the line segment's enclosing rectangle, in pixels. |
w |
Width of the line segment's enclosing rectangle, in pixels. |
h |
Height of the line segment's enclosing rectangle, in pixels. |
format |
Same as in Draw. See the Draw function for details. |
subformat |
Same as in Draw. See the Draw function for details. |
memory_surface |
A pointer to the DT_MDC structure that describes the surface. See D-Type Standard Engine Manual for details. |
This function can be used to invert the color of an area within an existing memory surface without the need to redraw the entire area by calling the Draw function. Depending on the blend parameters (set by calling the SetInvert function), certain inversion effects are reversible. This means that when applied two times successively to the same pixels, the result will be the same as if the effect was not applied at all. For this reason, these inversion effect can be used to visually indicate various types of temporary user selections (e.g. the cursor movements, text or block selections).