TcxCanvas.CopyMode Property
Specifies the active bitmap draw mode.
Declaration
property CopyMode: TCopyMode read; write;
Property Value
Type |
---|
TCopyMode |
Remarks
Use this property to determine how all bitmap draw routines work. The Windows unit defines the following constants that you can assign to the CopyMode property to achieve different effects:
Value | Description | Source | Destination | Result |
---|---|---|---|---|
cmBlackness | Fills the destination rectangle with the first color on the default palette (solid black). This operation ignores the content of both source and destination rectangles. | |||
cmDstInvert | Inverts the colors within the destination rectangle and ignores the source. | |||
cmMergeCopy | Uses the Boolean AND operator to merge the corresponding pixel colors of the source and destination rectangles. | |||
cmMergePaint | Uses the Boolean OR operator to merge the corresponding pixel colors of the source and destination rectangles. | |||
cmNotSrcCopy | Copies the inverted source rectangle into the destination rectangle whose content is ignored. | |||
cmNotSrcErase | Uses the Boolean OR operator to merge the corresponding pixel colors of the source and destination rectangles and then inverts the resulting pixel colors. | |||
cmPatCopy | Copies the source rectangle’s pattern into the destination rectangle whose content is ignored. | |||
cmPatInvert | Uses the Boolean XOR operator to merge the source rectangle’s pattern and the destination rectangle’s content. | |||
cmPatPaint | The Boolean OR operator combines the inverted source bitmap and the source bitmap’s pattern. Then, another Boolean OR operator combines the resulting pixels and the destination rectangle’s content. | |||
cmSrcAnd | Uses the Boolean AND operator to combine the source and destination rectangles. | |||
cmSrcCopy | Replaces the destination rectangle’s content with the source rectangle. This is the default bitmap draw mode. | |||
cmSrcErase | Inverts content of the destination rectangle and applies the Boolean AND operator to the resulting pixels and the source rectangle. | |||
cmSrcInvert | Uses the Boolean XOR operator to merge the corresponding pixels of the destination and source rectangles. | |||
cmSrcPaint | Uses the Boolean OR operator to merge the corresponding pixels of the destination and source rectangles. | |||
cmWhiteness | Fills the destination rectangle with the second color on the default palette (solid white). This operation ignores content of both source and destination rectangles. |
Note
The CopyMode property maps to the CopyMode property of the underlying canvas.
The CopyMode property’s default value is cmSrcCopy.
See Also