Does any Linux Users here know of a C++ Linux Window Skeleton??
I know that in Windows, it's
I am not sure how to properly ask this question. Thanks for the helpCode:#include <windows.h> LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM); static char gszClassName[] = "darkblue"; static HINSTANCE ghInstance = NULL; int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow) { WNDCLASSEX WndClass; HWND hwnd; MSG Msg; ghInstance = hInstance; WndClass.cbSize = sizeof(WNDCLASSEX); WndClass.style = NULL; WndClass.lpfnWndProc = WndProc; WndClass.cbClsExtra = 0; WndClass.cbWndExtra = 0; WndClass.hInstance = ghInstance; WndClass.hIcon = LoadIcon(NULL, IDI_APPLICATION); WndClass.hCursor = LoadCursor(NULL, IDC_ARROW); WndClass.hbrBackground = (HBRUSH)(COLOR_WINDOW+1); WndClass.lpszMenuName = NULL; WndClass.lpszClassName = gszClassName; WndClass.hIconSm = LoadIcon(NULL, IDI_APPLICATION); if(!RegisterClassEx(&WndClass)) { MessageBox(0, "Window Registration Failed!", "Error!", MB_ICONSTOP | MB_OK); return 0; } hwnd = CreateWindowEx( WS_EX_STATICEDGE, gszClassName, "darkblue owNz!", WS_OVERLAPPEDWINDOW, CW_USEDEFAULT, CW_USEDEFAULT, 320, 240, NULL, NULL, ghInstance, NULL); if(hwnd == NULL) { MessageBox(0, "Window Creation Failed!", "Error!", MB_ICONSTOP | MB_OK); return 0; } ShowWindow(hwnd, nCmdShow); UpdateWindow(hwnd); while(GetMessage(&Msg, NULL, 0, 0)) { TranslateMessage(&Msg); DispatchMessage(&Msg); } return Msg.wParam; }.. Even if there is a site that would be even better, I can copy a code off that and then go from there, I would like to do my own Apps from the ground up instead of using a IDE, I know that an IDE would be easier, but I really think doing it by hand would teach me a lot more than a GUI IDE will.. P.S. GUI(only), I really don't like Console Based Apps..


LinkBack URL
About LinkBacks


.. Even if there is a site that would be even better, I can copy a code off that and then go from there, I would like to do my own Apps from the ground up instead of using a IDE, I know that an IDE would be easier, but I really think doing it by hand would teach me a lot more than a GUI IDE will.. P.S. GUI(only), I really don't like Console Based Apps..

Reply With Quote


