Expand/Shrink

cdCanvasSetWriteMode

Definition: include pGUI.e

cdCanvasSetWriteMode(cdCanvas canvas, integer mode)
-- or --
integer mode = cdCanvasGetWriteMode(cdCanvas canvas)
Description: Defines or retrieve the writing type for all drawing primitives.
Values: CD_REPLACE, CD_XOR or CD_NOT_XOR. Default value: CD_REPLACE.
pwa/p2js: Not supported.
Comments: The XOR operation is very useful, because, using white as the foreground color and drawing the same image twice, you can go back to the original color, before the drawing. This is commonly used for mouse selection feedback.

When translating C code, cdCanvasWriteMode() must have Set/Get inserted.