Jump to content

WinQueryVisibleRegion

From EDM2
Revision as of 18:26, 9 April 2025 by Martini (talk | contribs) (Created page with "This function is similar to WinQueryUpdateRegion. It returns a region which could be NULL, rectangular, or complex, and represents the visible region of the window. ==Syntax== WinQueryVisibleRegion(hwnd, hrgn) ==Parameters== ;hwnd (HWND) - Input : The window handle. ;hrgn (HRGN) - Input : Region handle to receive the current visible region. ==Returns== ;ulretn (ULONG) - returns : RGN_ERROR An error occurred. : RGN_NULL The window currently has no visi...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

This function is similar to WinQueryUpdateRegion. It returns a region which could be NULL, rectangular, or complex, and represents the visible region of the window.

Syntax

WinQueryVisibleRegion(hwnd, hrgn)

Parameters

hwnd (HWND) - Input
The window handle.
hrgn (HRGN) - Input
Region handle to receive the current visible region.

Returns

ulretn (ULONG) - returns
RGN_ERROR An error occurred.
RGN_NULL The window currently has no visible area on screen.
RGN_RECT The region contains a series of rectangular areas.
RGN_COMPLEX The region contains a complex shape.

Remarks

This function returns the current visible region for the given window, even if that window does not receive notification when the visible region is changed. Currently, the region returned will always be a set of rectangular areas.

Related Functions