• Welcome to Powerbasic Museum 2020-B.
 

News:

Forum in repository mode. No new members allowed.

Main Menu

Undocumented flag for "GetDCEx"

Started by Theo Gottwald, October 06, 2011, 03:56:33 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Theo Gottwald

GetDCEx can be used to retrieve the device context for a window during processing of %WM_NCPAINT.
The documentation states that this is achieved by using

GetDCEx(hwnd, hrgn, %DCX_WINDOW | %DCX_INTERSECTRGN)


However, this call never works, because there is an undocumented flag to include which is not mentioned anywhere.

And this is how it works:

GetDCEx(hwnd, hrgn, DCX_WINDOW | DCX_INTERSECTRGN | 0x10000)

Source: Catch22.net