<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    天空是藍(lán)色的

    做好軟件為中國 #gcc -c helloworld.c -o helloworld.o //編譯目標(biāo)文件 #gcc helloworld.o -o helloworld //編譯成可執(zhí)行exe #helloworld //運(yùn)行exe
    數(shù)據(jù)加載中……
    Windows窗體C語言
    #include <windows.h>

    /*  Declare Windows procedure  */
    LRESULT CALLBACK WindowProcedure (HWND
    , UINT, WPARAM, LPARAM);

    /*  Make the class name into a global variable  */
    char szClassName
    [ ] = "WindowsApp";

    int WINAPI WinMain (HINSTANCE hThisInstance
    ,
                        HINSTANCE hPrevInstance
    ,
                        LPSTR lpszArgument
    ,
                        int nFunsterStil)

    {
        HWND hwnd
    ;               /* This is the handle for our window */
        MSG messages;            /* Here messages to the application are saved */
        WNDCLASSEX wincl;        /* Data structure for the windowclass */

        /* The Window structure */
        wincl.hInstance 
    = hThisInstance;
        wincl.lpszClassName = szClassName;
        wincl.lpfnWndProc = WindowProcedure;      /* This function is called by windows */
        wincl.style = CS_DBLCLKS;                 /* Catch double-clicks */
        wincl.cbSize = sizeof (WNDCLASSEX);

        /* Use default icon and mouse-pointer */
        wincl.hIcon 
    = LoadIcon (NULL, IDI_APPLICATION);
        wincl.hIconSm = LoadIcon (NULL, IDI_APPLICATION);
        wincl.hCursor = LoadCursor (NULL, IDC_ARROW);
        wincl.lpszMenuName = NULL;                 /* No menu */
        wincl.cbClsExtra = 0;                      /* No extra bytes after the window class */
        wincl.cbWndExtra = 0;                      /* structure or the window instance */
        /* Use Windows's default color as the background of the window */
        wincl.hbrBackground 
    = (HBRUSH) COLOR_BACKGROUND;

        /* Register the window class
    , and if it fails quit the program */
        if (!RegisterClassEx (&wincl))
            return 
    0;

        /* The class is registered
    , let's create the program*/
        hwnd 
    = CreateWindowEx (
               
    0,                   /* Extended possibilites for variation */
               szClassName
    ,         /* Classname */
               
    "Windows App",       /* Title Text */
               WS_OVERLAPPEDWINDOW
    , /* default window */
               CW_USEDEFAULT
    ,       /* Windows decides the position */
               CW_USEDEFAULT
    ,       /* where the window ends up on the screen */
               
    544,                 /* The programs width */
               
    375,                 /* and height in pixels */
               HWND_DESKTOP
    ,        /* The window is a child-window to desktop */
               NULL
    ,                /* No menu */
               hThisInstance
    ,       /* Program Instance handler */
               NULL                 /* No Window Creation data */
               )
    ;

        /* Make the window visible on the screen */
        ShowWindow (hwnd
    , nFunsterStil);

        /* Run the message loop. It will run until GetMessage() returns 
    0 */
        while (GetMessage (&messages
    , NULL, 0, 0))
        {
            /* Translate virtual-key messages into character messages */
            TranslateMessage(&messages)
    ;
            /* Send message to WindowProcedure */
            DispatchMessage(&messages)
    ;
        }

        /* The program return-value is 
    0 - The value that PostQuitMessage() gave */
        return messages.wParam
    ;
    }


    /*  This function is called by the Windows function DispatchMessage()  */

    LRESULT CALLBACK WindowProcedure (HWND hwnd
    , UINT message, WPARAM wParam, LPARAM lParam)
    {
        switch (message)                  /* handle the messages */
        {
            case WM_DESTROY:
                PostQuitMessage (
    0);       /* send a WM_QUIT to the message queue */
                break;
            default:                      /* for messages that we don't deal with */
                return DefWindowProc (hwnd
    , message, wParam, lParam);
        }

        return 
    0;
    }

    posted on 2006-02-14 10:43 bluesky 閱讀(1028) 評論(0)  編輯  收藏 所屬分類: C/C++

    主站蜘蛛池模板: 亚洲国产欧美一区二区三区| 亚洲嫩草影院久久精品| 亚洲欧美成aⅴ人在线观看| 中文字幕成人免费视频| 亚洲精品美女在线观看| 在线观看免费视频资源| 亚洲偷自精品三十六区| 三年片在线观看免费观看高清电影 | 久久久久国产精品免费看| 国产成人亚洲综合无码精品| 国产午夜成人免费看片无遮挡| 国产亚洲精品va在线| 国内精品免费在线观看| 久久亚洲精品无码AV红樱桃| 精品免费久久久久久久| 亚洲kkk4444在线观看| 日本一道综合久久aⅴ免费| 男人j进女人p免费视频| 亚洲日韩精品A∨片无码| 2019中文字幕在线电影免费| 77777亚洲午夜久久多喷| 国产做床爱无遮挡免费视频| a在线视频免费观看在线视频三区| 亚洲日韩国产精品第一页一区| 免费人成网站在线观看不卡| 亚洲精品成人久久| 国产最新凸凹视频免费| aaa毛片视频免费观看| 亚洲欧洲另类春色校园小说| 欧洲精品免费一区二区三区| 一级毛片**免费看试看20分钟| 亚洲AV日韩AV鸥美在线观看| www.黄色免费网站| 又硬又粗又长又爽免费看 | 日本亚洲色大成网站www久久| 国产伦精品一区二区三区免费迷| 91在线视频免费观看| 亚洲1区1区3区4区产品乱码芒果 | 亚洲精品成人在线| 亚洲精品视频在线观看免费| 九九精品国产亚洲AV日韩|