13.07.2015 Views

REFERENCE GUIDE

REFERENCE GUIDE

REFERENCE GUIDE

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

WM_CREATEWM_CREATEThis message informs the window procedure that it can perform anyinitialization. The CreateWindow function sends this message before itreturns and before the window is opened.Parameters wParam Is not used.IParamPoints to a CREATESTRUCT data structure that contains copiesof parameters passed to the CreateWindow function.WM_CTLCOLORThis message is sent to the parent window of a predefined control ormessage box when the control or message box is about to be drawn. Byresponding to this message, the parent window can set the text andbackground colors of the child window by using the display-contexthandle given in the wParam parameter.Parameters wParam Contains a handle to the display context for the child window.Default actionCommentsIParamThe low-order word of the IParam parameter contains thehandle to the child window. The high-order word is one of thefollowing values, specifying the type of control:ValueCTLCOLOR_BTNCTLCOLOR_DLGCTLCOLOR_EDITCTLCOLOR_LISTBOXCTLCOLOR_MSGBOXCTLCOLOR_SCROLLBARCTLCOLOR_ST ATICControl TypeButton controlDialog boxEdit controlList-box controlMessage boxScroll-bar controlStatic controlThe DefWindowProc function selects the default system colors.When processing the WM_ CTLCOLOR message, the application mustalign the origin of the intended brush with the window coordinates byfirst calling the UnrealizeObject function for the brush, and then settingthe brush origin to the upper-left corner of the window.If an application processes the WM_ CTLCOLOR message, it must return ahandle to the brush that is to be used for painting the control background.Note that failure to return a valid brush handle will place the system in anunstable state.646Software development kit

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!