windows_programming_notes.nbk: Home | Index | Next Page: win32 msgs: WM_PRINTCLIENT | Previous Page: win32 msgs: WM_POWERBROADCAST


 win32 msgs: WM_PRINT

The WM_PRINT message is sent to a window to request that it draw itself in the specified device context, most commonly in a printer device context.

A window receives this message through its WindowProc function.

    LRESULT CALLBACK WindowProc(
      HWND hwnd,       // handle to window
      UINT uMsg,       // WM_PRINT
      WPARAM wParam,   // handle to DC (HDC)
      LPARAM lParam    // drawing options
    );

Parameters

Remarks

The DefWindowProc function processes this message based on which drawing option is specified: if PRF_CHECKVISIBLE is specified and the window is not visible, do nothing, if PRF_NONCLIENT is specified, draw the nonclient area in the specified device context, if PRF_ERASEBKGND is specified, send the window a WM_ERASEBKGND message, if PRF_CLIENT is specified, send the window a WM_PRINTCLIENT message, if PRF_CHILDREN is set, send each visible child window a WM_PRINT message, if PRF_OWNED is set, send each visible owned window a WM_PRINT message.

Requirements


windows_programming_notes.nbk: Home | Index | Next Page: win32 msgs: WM_PRINTCLIENT | Previous Page: win32 msgs: WM_POWERBROADCAST


Notebook exported on Monday, 7 July 2008, 18:56:50 PM Eastern Daylight Time