반응형 WINAPI3 winapi 흰창띄우기 기본예제 #include LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM); HINSTANCE g_hlnst; LPCTSTR lpszClass = TEXT("First"); int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE hPrevlnstance, LPSTR lpszCmdParam, int nCmdShow) { HWND hWnd; MSG Message; WNDCLASS WndClass; g_hlnst = hInstance; WndClass.cbClsExtra = 0; WndClass.cbWndExtra = 0; WndClass.hbrBackground = (HBRUSH)GetStockObject(WHITE_BRUSH); Wn.. 2019. 6. 2. winapi 마우스를 창안에 가두기 LRESULT CALLBACK WndProc(HWND hWnd, UINT iMessage, WPARAM wParam, LPARAM lParam) { HDC hdc; PAINTSTRUCT ps; RECT rc; POINT p1, p2; GetClientRect(hWnd, &rc); p1.x = rc.left; p1.y = rc.top; p2.x = rc.right; p2.y = rc.bottom; ClientToScreen(hWnd, &p1); ClientToScreen(hWnd, &p2); rc.left = p1.x; rc.top = p1.y; rc.right = p2.x; rc.bottom = p2.y; ClipCursor(&rc); switch (iMessage) { case WM_DESTROY: P.. 2019. 5. 27. WinApi 기본소스[WinApi basic source] WinApi 기본소스 [WinApi basic source] Winapi 기본소스입니다. This is Winapi basic source #include LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM);HINSTANCE g_hlnst;LPCTSTR lpszClass =TEXT("제목"); int APIENTRY WinMain(HINSTANCE hlnstance, HINSTANCE hPrevlnstance, LPSTR lpszCmdParam, int nCmdShow){HWND hWnd;MSG Message;WNDCLASS WndClass;g_hlnst = hlnstance; WndClass.cbClsExtra = 0;WndClass.cbWndExtra = 0.. 2018. 6. 23. 이전 1 다음 반응형 더보기 더보기 더보기 더보기