←Select platform

Graphics Property

Summary
Gets the GDI+ System.Drawing.Graphics object that represents the display surface of the Leadtools.RasterImage.
Syntax
C#
VB
C++
public Graphics Graphics { get; } 
Public ReadOnly Property Graphics As Graphics 
public: 
property Graphics^ Graphics { 
   Graphics^ get(); 
} 

Property Value

A GDI+ System.Drawing.Graphics object that represents the display surface of the Leadtools.RasterImage.

Remarks

Use the RasterImagePainter.CreateGraphics method to create an infinite number of drawing capabilities such as paint, erase, color erase and brush, pen, spray gun, flood fill, color tube, text overlay, curve, line, rectangle, polygon, ellipse, freehand shapes, cut and paste, and more.

All GDI+ methods can be used to draw to the image using the returned System.Drawing.Graphics object. The graphics object must be disposed after using it.

If a region is defined for the image, GDI functions act only on the region, not on the entire image.

The GDI+ graphics supports only 1, 4, 8, 16 and 24 bit images. If you are using an image that has some other number of bits per pixel, you must use Leadtools.ImageProcessing.ColorResolutionCommand to change the image to a bits per pixel value supported by the DIB driver.

For more information refer to RasterImage and GDI/GDI+.

For more information, refer to Introduction to Image Processing With LEADTOOLS.

Example

For an example, refer to RasterImagePainter.CreateGraphics.

Requirements

Target Platforms

Help Version 21.0.2021.7.2
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.Drawing Assembly
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.