Code generation with CL+wxFB

CodeLite installation/troubleshooting forum
slamjam
CodeLite Curious
Posts: 4
Joined: Tue Oct 26, 2010 12:00 am
Genuine User: Yes
IDE Question: C++
Contact:

Code generation with CL+wxFB

Post by slamjam »

Hi
I am trying out CL and wxFB. Using Ubuntu 9.10 (karmic), CL ver 2.7.0.4375 and wxFB ver 3.1.70(Unicode).
I have a problem with the Code Generation of CL.

Here is what I have tried and was unsuccessful:
  • I use the CL Wizard to create a new wxFB Dialog project by right clicking the Workspace->Create New Project option.
    I then check that the project created compiles and runs with no errors and that is working correctly. CL generates a few files such as gui.fbp, main.cpp/h and gui.cpp/h.
    I then open the wxFB file "gui.fbp" that CL wizard creates and then add a wxSpinCtrl item to the gui.
    I hit F8 to generate a new base class and then recompile my code in CL and make sure that the new wxSpinCtrl is showing up correctly and that works with no errors.
    In wxFB I select the wxSpinCtrl item and then add "OnSpin1" to the event tab under "OnSpinCtrl" and then hit F8 to regenerate the base class and once again check that everything compiles correctly.
    In CL, I select the file "main.h" and then right click and select Code Generation/Refactoring->Implement Inherited virtual Functions... it does not do anything and no changes to the files "main.h" or "main.cpp" occur.
    I have tested the other options "Implement Inherited pure virtual Functions..." and "Implement all Un-implemented Functions..." and "Add Function implementation..." and none of them change any of the files or show any changes that may be made.
What could I be doing incorrectly?
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Code generation with CL+wxFB

Post by eranif »

slamjam wrote:I select the file "main.h" and then right click and select Code Generation/Refactoring->Implement Inherited virtual Functions... it does not do anything and no changes to the files "main.h" or "main.cpp" occur
This is because codelite is not aware that that files were modified outside of the editor.
So it does not really know about the new functions added to the base class.

From the main menu:
'Workspace | ReTag Workspace (Quick)'
This will trigger a re-parsing of all modified files (based on the modification time on the disk)

And the refactoing options will work (this is how I do it)

Eran
Make sure you have read the HOW TO POST thread
slamjam
CodeLite Curious
Posts: 4
Joined: Tue Oct 26, 2010 12:00 am
Genuine User: Yes
IDE Question: C++
Contact:

Re: Code generation with CL+wxFB

Post by slamjam »

Hi Eran

Thanks for the reply.

I tried both methods of retagging (Quick and Full) and it made no difference.
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Code generation with CL+wxFB

Post by eranif »

Make sure that the when you right click and select the option to generate the inherited methods the cursor is placed inside the derived class
Can you compress your project and attach it (assuming that it does not contain any closed sources etc ;) )

Eran
Make sure you have read the HOW TO POST thread
slamjam
CodeLite Curious
Posts: 4
Joined: Tue Oct 26, 2010 12:00 am
Genuine User: Yes
IDE Question: C++
Contact:

Re: Code generation with CL+wxFB

Post by slamjam »

Hi Eran

Attached is the test project Test6.tar.gz that I am using.
You do not have the required permissions to view the files attached to this post.
Last edited by slamjam on Fri Nov 12, 2010 2:46 pm, edited 1 time in total.
slamjam
CodeLite Curious
Posts: 4
Joined: Tue Oct 26, 2010 12:00 am
Genuine User: Yes
IDE Question: C++
Contact:

Re: Code generation with CL+wxFB

Post by slamjam »

Bump
evstevemd
CodeLite Guru
Posts: 352
Joined: Sun Nov 29, 2009 7:36 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Code generation with CL+wxFB

Post by evstevemd »

After generating files with wxFB, add them manually to the project!
That is how I do it ;)

CodeLite 15.x
CodeLite is awesome, I just Love it!

Post Reply