Friday, November 27, 2009

wxWidgets | Hello World | Unicode | Visual Studio Express 2008

//Project Properties:
//http://wiki.wxwidgets.org/Microsoft_Visual_CPP_Guide
//General>Charset: Use Unicode Character Set (or ansi:not set)
//Include: "C:\Server\wxWidgets-2.8.10\include\msvc";"C:\Server\wxWidgets-2.8.10\include"
//Library: "C:\Server\wxWidgets-2.8.10\lib\vc_lib"
//[preprocessor defines:] WINVER=0x0400;__WXMSW__ ;_WINDOWS
//[linker system subsystem:] Windows (/SUBSYSTEM:WINDOWS)
//[linker libraries (all    ):] comctl32.lib rpcrt4.lib winmm.lib advapi32.lib wsock32.lib 
//[linker libraries (debug  ):] wxbase28ud.lib  wxmsw28ud_core.lib
//[linker libraries (release):] wxbase28u.lib  wxmsw28u_core.lib
//File > Advanced Save Options > UTF8 with signature, CRLF


#include <wx/wx.h>
class MyApp public wxApp
{
  public:
    virtual bool OnInit();
};

IMPLEMENT_APP(MyApp)

bool MyApp::OnInit()
{

    wxFrame *simple new wxFrame(NULLwxID_ANYwxT("你好"), wxDefaultPositionwxSize(250150));
    simple->Centre();
    simple->Show(true);

    return true;

}


No comments: