Specify Arguments to Ctor

Post here wxCrafter related issues / features / bugs
evstevemd
CodeLite Guru
Posts: 352
Joined: Sun Nov 29, 2009 7:36 pm
Genuine User: Yes
IDE Question: C++
Contact:

Specify Arguments to Ctor

Post by evstevemd »

I have something like this
wxC allows me to specify a sublclass but I cannot change Ctor.
I want to be able to tell my base class of the Ctors of both the base class as well as how subclass.
Also it would be nice to tell wxC that I want to use my own ctor both in .h and .cpp so generate other stuffs but use this code for ctor in base/subclass

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

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

Re: Specify Arguments to Ctor

Post by evstevemd »

Just a rant, why is there no undo/redo? :o

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

User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Specify Arguments to Ctor

Post by eranif »

evstevemd wrote:Just a rant, why is there no undo/redo?
There is... and it is working fine (for me at least)
Please specify a use case that it fails
evstevemd wrote:wxC allows me to specify a sublclass but I cannot change Ctor.
I want to be able to tell my base class of the Ctors of both the base class as well as how subclass.
Atm, this is how subclass works. Your class needs to have the same signature as the actual class
evstevemd wrote:Also it would be nice to tell wxC that I want to use my own ctor both in .h and .cpp so generate other stuffs but use this code for ctor in base/subclass
I did not understand this part

Eran
Make sure you have read the HOW TO POST thread
evstevemd
CodeLite Guru
Posts: 352
Joined: Sun Nov 29, 2009 7:36 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Specify Arguments to Ctor

Post by evstevemd »

eranif wrote:
evstevemd wrote:Just a rant, why is there no undo/redo?
There is... and it is working fine (for me at least)
Please specify a use case that it fails
It does not work for me. Test case: Add AUI Notebook. Then add new page.
Now try to undo add page (or even remove page) and it does not work.
eranif wrote:
evstevemd wrote:wxC allows me to specify a sublclass but I cannot change Ctor.
I want to be able to tell my base class of the Ctors of both the base class as well as how subclass.
eranif wrote: Atm, this is how subclass works. Your class needs to have the same signature as the actual class
But it might be taking less arguments (eg wxStc taking first three args and the rest should remain as wxDefaults)
eranif wrote:
evstevemd wrote:Also it would be nice to tell wxC that I want to use my own ctor both in .h and .cpp so generate other stuffs but use this code for ctor in base/subclass
I did not understand this part

Eran
I mean to be able to tell wxC how I want my Ctor to be and generate it that way.
Suppose I have a wxPanel. wxC will try to generate a ctor with all wxPanel arguments that is wxPanel(wxWindow parent, id.....)
Now suppose I want my wxPanel ctor to be different just wxPanel(parent, id, SomeClassPointer*) I suggest to be able to tell wxC that in generating Ctor just copy my custom instead of default. Not sure if I have made clear myself!

Thanks for help also!

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

Post Reply