[slicer-devel] Module replication error
julien.finet at kitware.com
Tue Jun 5 11:17:30 EDT 2012
I advice against duplicating the Transforms module, code duplication is
Modules are designed in a way that their "logic" is accessible to other
modules . Maybe you just need to write your own custom panel, and use
the Transforms module logic ? See how "Crop Volume" uses the Volumes logic
Are you sure you need everything from the Transforms module? Maybe there
are few items you don't need or organized differently. If you are
interested in some widgets, maybe you should extract those widgets from the
transform module, and make them accessible for other modules (see  for
an example of a re-usable widget).
Please consider those alternative solutions:
- redirect the user to use the Transforms module and come back to your
module when done
- help us working on the "cloning" of module panels at run time (right now
qSlicerAbstractCoreModule::createWidgetRepresentation() is only call once,
but if called twice, you will have 2 panels for 1 logic (it's equivalent to
having 2 views/controllers for 1 model in the Model View Controller
paradigm) and you would be able to embed the newly created panel in your
own module). Most of the work has been done, it's just a matter of exposing
it into the API.
p.s. your error comes from the EXPORT macro name that needs to be changed
On Tue, Jun 5, 2012 at 3:10 AM, erol yeniaras <eyeniaras at gmail.com> wrote:
> Hello all,
> I want to use the capabilities of the Transforms module within my module.
> To this end, I created a replica of Transforms module and named it
> as LITTPlanV2.
> I did this firstly by creating a new loadable module and copying the
> contents of Transforms module and pasting under new module. Then I have
> changed the names of the files and their contents. (Replaced the word
> `Transforms` with `LITTPlanV2`).
> Then used Cmake gui to configure and generate. In the last step, when
> building with visual studio I faced with such errors:
> : error C2470: 'qSlicerLITTPlanV2ModuleWidget' : looks like a function
> definition, but there is no parameter list; skipping apparent body
> I have been trying to solve this problem since yesterday, but the error
> persists. Does anyone have a suggestion please? Full module and build log
> is attached.
> I appreciate any form of help.
> PS: If replicating modules is not appropriate then I will add those
> features on my module directly.
> slicer-devel mailing list
> slicer-devel at bwh.harvard.edu
> To unsubscribe: send email to
> slicer-devel-request at massmail.spl.harvard.edu with unsubscribe as the
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the slicer-devel