IDeviceContext Interface

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Defines methods for obtaining and releasing an existing handle to a Windows device context.

Namespace:   System.Drawing
Assembly:  System.Drawing (in System.Drawing.dll)

public interface IDeviceContext : IDisposable

NameDescription
System_CAPS_pubmethodDispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.(Inherited from IDisposable.)

System_CAPS_pubmethodGetHdc()

Returns the handle to a Windows device context.

System_CAPS_pubmethodReleaseHdc()

Releases the handle of a Windows device context.

A device context defines the graphics object for drawing on a Windows-based device. An example of a class that implements the IDeviceContext interface is the Graphics class.

.NET Framework
Available since 2.0
Return to top
Show: