Hi, I think that to achieve that, you just need to bind some your own code 'business logic' to wxLua, and use wxLua extended with your own classes/code.
I myself only use wxLua as an extension language in wxArt2D. The sample/app in wxLua called wxluacan, is something in between. It creates the interface and canvas with wxWidgets, and next a wxLua binding can do extra things using a wxLua script. Like adding canvas objects from the wxLua script. For that i did bind the canvas class/members to wxLua as an extension to wxLua. I found it difficult to communicate information from C++ back to the wxLua script. In the end i used some static pointers from C++ to get to the information in C++ from lua. My problem was that the top classes are not created in the wxLua script, but i want to add class instances to the C++ created classes from inside the wxLua script. Next to that i wanted to call functions from c++ in the wxLua script. I think all those trick or inside the samples, the script incircles.lua shows how. I think in principle that is the same, if the C++ classes can be used from a script, it can run from wxLua or a C++ application of your own. In the end wxLua is in fact a wxWidgets application, dedicated to run wxLua scripts ;-) Regards, Klaas Wojtek Bocer wrote: > Hello > > I'm a newbie to the Lua and wxLua. > > Is it possible to develop an application which uses wxLua as a GUI > language and C++ as a 'business logic' language? I mean, it is easier > to write wxWidgets apps by means of wxLua, but I would like to use > wxLua only to the user interface part of my application. I presume > some kind of communication is needed between interface part and logic > part (reading user input etc). > > If so, have you got any examples of a C++ code which executes some > wxLua code and exchanges information with it? > -- Unclassified ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ wxlua-users mailing list wxlua-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wxlua-users