magnus@itkonsult-olsen.com wrote:
Hi I think it is not wrong with GetWindowDC(GetDesktopWindow()); for we need current desktop, to get the screen width, height and some other data. so I think is pretty clear what it does. we can do same thing with createdc then we need look wich graphic driver are in use. And I do not if GetDC(NULL) work fine in ros.
If it doesn't work in ros, it should. If not, it should be easy to fix. To quote GetDC() documentation from MSDN:
/hWnd/ [in] Handle to the window whose DC is to be retrieved. If this value is NULL, *GetDC* retrieves the DC for the entire screen.
(I frequently use GetDC(NULL) for calls to CreateCompatibleDC and CreateCompatibleBitmap).
In fact, GetWindowDC(NULL), appears to do the same thing as GetDC(NULL), but I personally prefer GetDC(NULL), because it's easier to type ;)