Hi,
With the latest CVS the erorr is already in the create binding stage.
%class %noclassinfo a2dDrawRectangleTool
%member static const a2dCommandId COMID_PushTool_DrawRectangle;
%endclass
Results in:
--------------------Configuration: luawraps - Win32 Debug--------------------
Generating C:/data/art2d/wxArt2D/modules/luawraps/src/luabind.cpp
Generating wxWidgets Binding
Loaded rules file: luawraps_rules.lua
Loaded datatypes cache file:
c:/data/art2d/wxluacvs/wxLua/bindings/wxwidgets/wx_datatypes.lua
Timing: BuildDataTypeTable 0 seconds.
ERROR: Expected Member Name, got Tag='static'. File:
'C:/data/art2d/wxArt2D/modules/luawraps/src/luabind.i':(line 92)
' %member static const a2dCommandId COMID_PushTool_DrawRectangle;'
It looks like this static member data is something new, and not used yet in
wxWidgets itself.
Klaas
John Labenski wrote:
> On Dec 19, 2007 9:22 AM, Klaas Holwerda <[EMAIL PROTECTED]> wrote:
>> Hi John or other wrappers,
>>
>> Do you have an idea how i can wrap the next (static const member )
>>
>> class A2DEDITORDLLEXP a2dDrawRectangleTool: public a2dStDrawTool
>> {
>> public:
>> static const a2dCommandId COMID_PushTool_DrawRectangle;
>>
>>
>> I tried:
>>
>> %class %noclassinfo a2dCommandId
>> %endclass
>>
>> %class %noclassinfo a2dDrawRectangleTool
>> %member const a2dCommandId COMID_PushTool_DrawRectangle;
>> %endclass
>>
>> And although this compiles in C++, the next line is a not working in wxLua.
>>
>> wx.a2dMaskProc:PushTool(
>> wx.a2dDrawRectangleTool.COMID_PushTool_DrawRectangle )
>>
>> Error: lua: Syntax error during pre-compilation
>> [string "*tools.lua"]:2: function arguments expected near ')'
>>
>> Or am i doing something wrong to call it?
>
> You don't have the static keyword after the %member tag. I think that
> should work.
>
> Compare the C++ output with that of wxPoint's x %member.
--
Unclassified
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
wxlua-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wxlua-users