Hi All,
Here is an update. The wizard code has been modified to enable support for
wxFormBuilder + wxFrame based app. The wizard works fine in generating the files.
But I'm facing couple of problems. Files can be added to a Project by the Wizard in two ways.
- Show C::B a folder and it will copy the contents without processing them.
- Give C::B file name and contents and it'll add them.
Problem with the first method is that it doesn't parse the files. So customisations of files are not possible.
Problem with the second method is that you can parse files, but AFAIK it can't add files with unrecognised extensions. The wxFormBuilder (wxFB) project file extension is unrecognised by C::B and therefore it is not adding to project after parsing it.
There is another problem with the second method
to parse wxFB project file. Pre-processor definition to enable PCH support can't be customised. If I add the wxFB project file with/without parsing, it is going to break the PCH support.
Following piece of code will make my point clear. An example of wxFB generated code is as follows. wxFB uses WX_GCH whereas the project will use USE_PCH.
#ifdef WX_GCH
#include <wx_pch.h>
#else
#include <wx/wx.h>
#endif
I have decided to go with first method for the time being. But the PCH support will remain broken for wxFB generated code. Though PCH support should work with remaining part of the project.
@rjmyst3Is it possible to add customisation of this Pre-processor directive in wxFB project file? I just want to change the Pre-processor directive to USE_PCH and want wxFB to use this while regenerating the source. I don't think this would be quite difficult to implement.
@MandravIs there any better alternative to Second method? A link to help would be sufficient.
@byoI'll implement wxSmith after I fix initial problems. But I have one request. Can you please provide me with two project files, one for Dialog based and one for Frame based? Please include wxs file, cpp and header files.
Regards,
Biplab
Edit 1: Fixed a Typo.