Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
| DrawingAttributes.RasterOperation Property | 
Gets or sets a value that defines how the colors of the pen and background interact.
Definition
Visual Basic .NET Public Property RasterOperation As RasterOperation C# public RasterOperation RasterOperation { get; set; } Managed C++ public: __property RasterOperation* get_RasterOperation(); 
public: __property void set_RasterOperation(RasterOperation*);
Property Value
Microsoft.Ink.RasterOperation. The value that defines how the colors of the pen and background interact.
This property is read/write. This property has no default value.
Black1Specifies black pen color. NotMergePen2Specifies the inverse of MergePen. MaskNotPen3Specifies a combination of the colors are common to the background color and the inverse of the pen. NotCopyPen4Specifies the inverse of CopyPen. MakePenNot5Specifies a combination of the colors are common to both the pen and the inverse of the display. Not6Specifies the inverse of the display color. XOrPen7Specifies a combination of the colors in the pen and in the display color, but not in both. NotMaskPen8Specifies the inverse of MaskPen. MaskPen9Specifies a combination of the colors common to both the pen and the display. NotXOrPen10Specifies an inverse of XOrPen. NoOperation11Specifies no operation; the output remains unchanged. MergeNotPen12Specifies a combination of the display color and the inverse of the pen color. CopyPen13Specifies the pen color. MergePenNot14Specifies a combination of the pen color and the inverse of the display color. MergePen15Specifies a combination of the pen color and the display color. White16Specifies a white pen color. 
Remarks
The RasterOperation enumeration defines values for performing raster operations on drawn ink. For example, if you want to perform subtractive transparency, set the raster value to
MaskPen.For a complete list of available raster operations, see the RasterOperation enumeration type.
Note: Many printers do not support many of the available raster operations. Because of this, the colors displayed may be different than the colors printed. This is directly related to the printer drivers or printer hardware. You may have to experiment to determine which printers can produce the correct output when various raster operations are set on ink.
When the RasterOperation value is set to anything other than
CopyPen, all drawing attributes—anti-aliasing, smoothing, transparency, and pressure—are ignored.
Examples
[C#]
This C# example sets the raster operation of the InkCollector object's default pen to
XOrPen.theInkCollector.DefaultDrawingAttributes.RasterOperation = RasterOperation.XOrPen;[VB.NET]
This Microsoft® Visual Basic® .NET example sets the raster operation of the InkCollector object's default pen to
XOrPen.theInkCollector.DefaultDrawingAttributes.RasterOperation = _ RasterOperation.XOrPen
See Also