Search found 80 matches

by fancyivan
Mon Jul 19, 2010 1:33 am
Forum: C++ Development
Topic: Advice on implementing simple game
Replies: 4
Views: 1350

Re: Advice on implementing simple game

I want to use wxWidgets to create a simple tic-tac-toe game. I would like this to work (with minimal code changes) under both Linux and Windows. The problem I am having is choosing a way to implement the graphical part of the user interface. I need to start off showing an empty board, and I want th...
by fancyivan
Wed Jul 14, 2010 2:46 am
Forum: wxWidgets Development (Chinese)
Topic: 使用GBK编译wxGLCanvas出错的问题
Replies: 2
Views: 3085

Re: 使用GBK编译wxGLCanvas出错的问题

开发工具C::B,为了使用中文,在setting中设置了-finput-charset=GBK,中文正常使用,但是当加入 #include <wx/glcanvas.h> 加入 wxGLCanvas* canvas = new wxGLCanvas(this, wxID_ANY,wxDefaultPosition,wxDefaultSize,0, wxT("erw") ); 编译时出错,错误指向glcanvas.h中的 #include <GL/gl.h> 错误描述为:failure to convert GBK to UTF-8 去掉-finput-charset=GB...
by fancyivan
Thu Jul 08, 2010 7:12 am
Forum: wxWidgets Development (Chinese)
Topic: 请教下wxwidget的几个问题(犯难了)
Replies: 2
Views: 2937

Re: 请教下wxwidget的几个问题(犯难了)

请教几个wxWidget问题 1.怎么获取所在系统的环境变量 2.怎么判别系统类型 3.怎么执行非EXE的外部程序,例如chm 初学wxwidget,还望各位多多帮忙 1.参考wxGetEnv,如获取系统路径Path: wxGetEnv(wxT("PATH"), &ReturnValue ); 2.你是指这种大类的系统类型?还是说windows下,再细分server, xp, home, vista之类的? 如果是前者 wxString wxbuild(wxVERSION_STRING); #if defined(__WXMSW__) wxbuild << _T(...
by fancyivan
Wed Jul 07, 2010 8:02 am
Forum: C++ Development
Topic: wxBitmap, wxImage IsOk() returns false, but why?
Replies: 10
Views: 4333

Re: wxBitmap, wxImage IsOk() returns false, but why?

In my program I load images for some tool buttons. The code works fine in windows (mingw) and when compiled on ubuntu 9.10 (32 bit) but when I compile on ubuntu 10.04 (64bit) and run it.. I get a nice assertion failed dialog box because the images can't be loaded. If I ignore the dialog boxes and &...
by fancyivan
Wed Jul 07, 2010 7:28 am
Forum: wxWidgets Development (Chinese)
Topic: 使用如何IDE进行wxwidgets开发单文档应用程序
Replies: 5
Views: 4184

Re: codeblock不是只能生成对话框程序吗

woshiyadang wrote:codeblock不是只能生成对话框程序吗
我记得在C::B中,新建wxWidgets项目时,可以选择Dialog Based还是Frame Based,
希望你说的单文档程序就是我理解的Frame Based程序。
在同一设置页面,可以选择GUI设计器,如果选wxSmith,自动生成的将是一个包含菜单和状态栏的示例程序。
by fancyivan
Wed Jul 07, 2010 3:28 am
Forum: C++ Development
Topic: Slider and Resizing Dialogs...
Replies: 6
Views: 1448

I just have a normal dialog, with a Panel inside a sizer. I know that sizers automatically resize the slider and widgets within it, but I like to use panels for a more customized way to place widgets in my dialog... If sizers are the only thing that can automatically resize widgets in frames/dialog...
by fancyivan
Wed Jul 07, 2010 3:20 am
Forum: wxWidgets Development (Chinese)
Topic: 使用如何IDE进行wxwidgets开发单文档应用程序
Replies: 5
Views: 4184

Re: 使用如何IDE进行wxwidgets开发单文档应用程

woshiyadang wrote:如何完全手写代买觉得太慢了,请问大家有什么好的的IDE呢,比如像VC那样的,blockdialog好像只能开发对话框应用程序,不能开发单文档程序!
Code::Blocks不行么? 里面包括了wxSmith, wxFormBuilder等可视化界面设计工具,再结合一些手动调整,可以应付,虽然生成的代码有些冗余。
by fancyivan
Mon Jul 05, 2010 1:35 am
Forum: C++ Development
Topic: How to Create an Application Icon
Replies: 3
Views: 1208

Re: How to Create an Application Icon

Hi, How do I make my app have its own application icon? Using resource files? THANKS!!! -Masoug only for windows OS: first, you can delete everything in your resource file, then add: app ICON ".\\img\\logo.ico" the icon of your application is '.\img\logo.ico'. then in OnInit() function of...
by fancyivan
Wed Jun 30, 2010 5:01 am
Forum: General Development
Topic: how to play .mid file
Replies: 4
Views: 3357

As far as I know there is no cross-platform library for MIDI playback (and no capability inside wxWidgets itself), even though I may have missed something because when I was searching for MIDI librairies for my app (http://ariamaestosa.sf.net) I also wanted editing capabilities. I ended up writing ...
by fancyivan
Tue Jun 29, 2010 6:49 am
Forum: General Development
Topic: how to play .mid file
Replies: 4
Views: 3357

how to play .mid file

hello, does anyone know how to play a midi file? I want to play a .mid as the backgournd music of my application, but i have no idea about how to do it.... pls help me. thanks. I tried to use wxMediaCtrl(with param: wxMEDIABACKEND_DIRECTSHOW) to play a midi, and it works. but..., there is a windows ...
by fancyivan
Mon Jun 28, 2010 10:03 am
Forum: wxCode
Topic: sqlite3.dll depends on MSVCRT.DLL.
Replies: 5
Views: 4794

Re: sqlite3.dll depends on MSVCRT.DLL.

It works, it works!! Thank you Ulrich. :) thanks for your patient to reply my stupid & easy question..... 1. use include directory of wxSQLite3. 2. if link sqlite3 as absolute path, do not need to rename it. if as relative path, sqlited3.a should be renamed to libsqlite3.a. 3. about wxRegex, as ...
by fancyivan
Mon Jun 28, 2010 9:07 am
Forum: wxCode
Topic: sqlite3.dll depends on MSVCRT.DLL.
Replies: 5
Views: 4794

Re: sqlite3.dll depends on MSVCRT.DLL.

About the linking failed messages, I tried to add the sqlite3.a into the link library, the most error messages disappeared. but there are still 10 error messages left, I found that these error are all about wxRegEx. then I tried to add "libwxregexu.a" into the link library, but it does not...
by fancyivan
Mon Jun 28, 2010 8:24 am
Forum: wxCode
Topic: sqlite3.dll depends on MSVCRT.DLL.
Replies: 5
Views: 4794

Re: sqlite3.dll depends on MSVCRT.DLL.

Ulrich, thank u very much for your reply. after i posted this issue this morning, i googled a lot of articles about msvcrt and mingw, and your answer is simple but very clear, Now i'm clear about my question. thank you again. just now, I compiled the wxSQLite3 successfully. Here is my step: btw agai...
by fancyivan
Mon Jun 28, 2010 2:23 am
Forum: wxCode
Topic: sqlite3.dll depends on MSVCRT.DLL.
Replies: 5
Views: 4794

sqlite3.dll depends on MSVCRT.DLL.

hello, I'm a new for wxWidget and wxSQLite3. I only used the SQLite3 with .net wapper. after I read the ReadMe of wxSQLite3, I know that the sqlite3.dll will be used generally. on http://sqlite.org/download.html , sqlitedll-3_6_23_1.zip (253.34 KiB),This is a DLL of the SQLite library without the TC...
by fancyivan
Fri Jun 18, 2010 8:23 am
Forum: wxWidgets Development (Chinese)
Topic: 用wxWidgets写的扫雷
Replies: 1
Views: 2337

用wxWidgets写的扫雷

根据wxWidgets自带的扫雷例子改写的,希望对初学者有用。

程序(win):http://fecsoft.com/down/FecMine_bin.rar
源码:http://fecsoft.com/down/FecMine_src.rar