次の方法で共有


GweBypassCoredllThunk_t::GetWindowDC_I (Windows Embedded CE 6.0)

1/6/2010

This method retrieves the device context for the entire window, including title bar, menus, and scroll bars.

Syntax

static HDC WINAPI GetWindowDC_I(
  HWND hwndThis
);

Parameters

  • hwndThis
    [in] Handle to the window with a device context that is to be retrieved. If this value is NULL, GweBypassCoredllThunk_t::GetWindowDC_I retrieves the device context for the entire screen.

Return Value

The handle of a device context for the specified window indicates success. NULL indicates an error or an invalid hWnd parameter. To get extended error information, call GetLastError.

Remarks

This method is an internal version of the GetWindowDC function.

GweBypassCoredllThunk_t::GetWindowDC_I is intended for special painting effects within a the nonclient area of a window. Painting in nonclient areas of any window is not recommended.

The GetSystemMetrics function can be used to retrieve the dimensions of various parts of the nonclient area, such as the title bar, menu, and scroll bars.

The GweBypassCoredllThunk_t::GetDC_I method can be used to retrieve a device context for the entire screen.

After painting is complete, the GweBypassCoredllThunk_t::ReleaseDC_I method must be called to release the device context. Not releasing the window device context has serious effects on painting requested by applications.

Requirements

Header gwebypasscoredllthunk.hpp
Windows Embedded CE Windows CE .NET 4.0 and later

See Also

Reference

GweBypassCoredllThunk_t
GetSystemMetrics
GetWindowDC
GweBypassCoredllThunk_t::BeginPaint_I
GweBypassCoredllThunk_t::GetDC_I
GweBypassCoredllThunk_t::ReleaseDC_I