[C언어] C언어 그림판
- 최초 등록일
- 2004.06.10
- 최종 저작일
- 2004.06
- 9페이지/ 압축파일
- 가격 2,000원
소개글
C언어로 만든 그림판입니다..
기능은 그리기, 선그리기, 원그리기, 사각형 그리기랑, 선 종류 고르기 간단한 그림판입니다.
컴파일 실행환경
총 9파일
resource.h
resource.rc
main.cpp
Paint.dsp
Paint.dsw
Paint.ncb
Paint.opt
Paint.plg
resource.aps
본문내용
main.cpp
#include <windows.h>
#include "resource.h"
LRESULT CALLBACK WndProc(HWND hWnd, UINT iMsg, WPARAM wParam, LPARAM lParam);
HINSTANCE g_hInstance;
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow)
{
MSG msg;
HWND hWnd;
WNDCLASS wndclass;
g_hInstance = hInstance;
wndclass.cbClsExtra = 0;
wndclass.cbWndExtra = 0;
wndclass.hbrBackground = (HBRUSH)GetStockObject(WHITE_BRUSH);
wndclass.hCursor = LoadCursor(NULL, IDC_ARROW);
wndclass.hIcon = LoadIcon(NULL, IDI_APPLICATION);
wndclass.hInstance = hInstance;
wndclass.lpfnWndProc = (WNDPROC)WndProc;
wndclass.lpszClassName = "Paint";
wndclass.lpszMenuName = MAKEINTRESOURCE(IDR_MENU1);
wndclass.style = CS_HREDRAW|CS_VREDRAW;
RegisterClass(&wndclass);
hWnd = CreateWindow("Paint", "Paint", WS_OVERLAPPEDWINDOW,
CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT,
NULL, NULL, hInstance, NULL);
ShowWindow(hWnd, nCmdShow);
while(GetMessage(&msg, NULL, NULL, NULL)) {
TranslateMessage(&msg);
DispatchMessage(&msg);
}
압축파일 내 파일목록
resource.h
resource.rc
main.cpp
Paint.dsp
Paint.dsw
Paint.ncb
Paint.opt
Paint.plg
resource.aps
참고 자료
없음