static Handle BeginPaint(Handle Window,
                         Paint^ PaintStructure)

This function creates a device context suitable for painting a window.


Handle Window

The handle of the window to be painted.

Paint^ PaintStructure

A pointer to a paint structure that is filled in by the system.



The handle of the device context.


Any region outside the update region is excluded from drawing.

The update region is set by:

If the update region is targeted for erasure, the background erase message is sent to the window.

If the window's class possesses a background brush, that brush is used to paint the background of the update region prior to returning.

This function should be used only during the processing of Message::Paint.

The device context may be released by calling the function EndPaint.


Name Space IPlusPlus::Graphics
Class Gdi
Assembly IPlusPlus.WinPlus.dll