如何修改Code::Blocks中wxSmith插件自动生成代码的方式?
//在头文件中定义
static const long ID_XXXXx;
//并在源文件中实现
const long wxXXXXXXX::ID_XXXXx = wxNewId();
这使得在程序中无法使用 switch……case 语句对控件进行分流操作
虽然可以手动改为#define ID_XXXXx xxx方式或者直接在头文件中初始化static const long ID_XXXXx=xxx;
但是控件多了,这样就很麻烦,而且容易出错,有没有办法让wxSmith自动用上面这两种方法之一来生成代码啊?
P.S 以wxNewId()方法取得控件ID,再生成控件的方法,可能也是wxWidgets程序启动慢的一个原因吧!起码效率不高
相关推荐
wxSmith Plugin
It seems in the platform of Windows.
wxSmith Plugin:跨平台GUI开发的集成利器
wxWidgets是一个C++库,支持跨平台的GUI(图形用户界面)应用程序的创建。它允许开发者使用单一的代码库就能为Windows、Mac OS X、Linux等操作系统开发应用程序。wxWidgets遵循“一次编写,到处运行”的理念,极大地降低了应用程序的移植成本和复杂性。wxSmith是一个强大的wxWidgets图形用户界面(GUI)设计插件,它整合了Code::Blocks IDE中,为开发者提供了一个可视化的界面设计工具。核心功能主要围绕以下几个方面:可视化布局设计。
wxsmith tutorial完整版
Welcome to wxSmith tutorials page. Here you can learn how to create GUI applications for wxWidgets platform using wxSmith. At the beginning we will start with some basic tutorials which will show what can you do with wxSmith and how you can create simple applications. I hope that there will also be some advanced tutorials for those who know wxWidgets very well.
Code::Blocks8.02
Code::Blocks 是一个开放源码的全功能的跨平台C/C++集成开发环境。 Code::Blocks是开放源码软件。Code::Blocks由纯粹的C++语言开发完成,它使用了蓍名的图形界面库wxWidgets(2.6.2 unicode)版。对于追求完美的C++程序员,再也不必忍受Eclipse的缓慢,再也不必忍受VS.NET的庞大和高昂的价格。
wxSmith在Codeblocks中使用示例.doc
Since wxSmith is able to do something already it's high time to write a small tutorial on how to use it. At the very beginning, I must point out that to use wxSmith you MUST have wxWidgets compiled (version 2.6 or later). Build instructions can be found here WARNING: wxSmith is still unstable. So use it at Your own risk. And there's no undo yet. I warned You ;)


工具平台和程序库
