zoukankan      html  css  js  c++  java
  • 使用VS2013在WIN8.1上运行gaclib的hello world

    首先:gaclib的官网是http://www.gaclib.net/
    需要了解更多信息的请自己去官网,我也是刚刚研究
     
    第一步
    下载gaclib的源码
     
    这些文件是运行程序所必须的
     
    第二步
    用VS2013创建一个空项目,并把字符集设置成unicode
     
    第三步
    加入bigobj的编译器选项
     
    第四步
    把第一步中指出的文件拷贝到项目中
     
    第五步
    修改预编译头,把上一步中的头文件加入预编译头文件列表中
     
     
     
    第五步
    新建一个main.cpp,输入以下代码
    #include "GacUI.h"
    #include <Windows.h>
     
    int CALLBACK WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int CmdShow)
    {
     return SetupWindowsDirect2DRenderer();
    }
     
    void GuiMain()
    {
     GuiWindow* window = g::NewWindow();
     window->SetText(L"Hello, world!");
     window->SetClientSize(Size(640, 480));
     window->MoveToScreenCenter();
     
     GuiControl* label = g::NewLabel();
     label->SetText(L"Welcome to GacUI Library!");
     {
      FontProperties font;
      font.fontFamily = L"Segoe UI";
      font.size = 40;
      font.antialias = true;
      label->SetFont(font);
     }
     window->AddChild(label);
     
     GetApplication()->Run(window);
     delete window;
    }
    第六步
    编译运行程序
     
    第七步
    如果需要RELEASE编译,还应在这里定义一个NDEBUG
     
     
     
     
  • 相关阅读:
    哈希表--扩展数组
    哈希表效率
    P=(1+1/(1-L))/2
    函数推进
    简单函数2
    简单函数
    getting data from the keybroad
    nutch-2.2.1 hadoop-1.2.1 hbase-0.92.1 集群部署(实用)
    hbase zookeeper独立搭建
    Orchard 介绍
  • 原文地址:https://www.cnblogs.com/liulun/p/3603111.html
Copyright © 2011-2022 走看看