[Ctk-developers] Setting name and description of ctkWorkflowWidgetStep
Danielle Pace
danielle.pace at kitware.com
Fri Jun 3 20:13:38 UTC 2011
Hi Daniel,
Actually, I think you exposed something important here.
I'm assuming, from python, that you wrote something similar to:
- create step 1 (with no name/description)
- create step 2 (with no name/description)
- create workflow widget and add steps
- display workflow widget
- set name/description for steps 1 and 2
- expected to see workflow update, and it didn't
Is this correct? I think we are missing some signals on ctkWorkflowStep
such as NameChanged(QString) and DescriptionChanged(QString) that the
ctkWorkflowGroupBox should be listening to.
Perhaps you could still post your snippet of python code that wasn't
working, so I can verify that it is an ordering of commands that we should
support?
Thanks,
Danielle
On Fri, Jun 3, 2011 at 3:57 PM, Daniel Haehn <haehn at bwh.harvard.edu> wrote:
> Hi Danielle,
>
> thanks to your response I checked it again and you are right: it was
> my mistake :)
>
> If the name and description of the steps are set before the steps are
> added to the workflow, it all works as expected.
>
> I set the stuff after adding it and of course it did not recognize it
> until the signal was fired.
>
> Thanks for the great work!
>
> Cheers,
> Daniel
>
> On Fri, Jun 3, 2011 at 3:44 PM, Danielle Pace <danielle.pace at kitware.com>
> wrote:
> > Hi Daniel,
> > You shouldn't have to call the currenStepChanged signal directly. Can
> you
> > please post your bit of code that is not working to the CTK developers
> > mailing list, and I will take a look?
> > Thanks,
> >
> > Danielle
> >
> > On Fri, Jun 3, 2011 at 3:21 PM, Julien Finet <julien.finet at kitware.com>
> > wrote:
> >>
> >>
> >> ---------- Forwarded message ----------
> >> From: Daniel Haehn <haehn at bwh.harvard.edu>
> >> Date: Fri, Jun 3, 2011 at 3:13 PM
> >> Subject: Re: [Ctk-developers] Setting name and description of
> >> ctkWorkflowWidgetStep
> >> To: ctk-developers at commontk.org
> >>
> >>
> >> Hi guys,
> >>
> >> I got it:
> >>
> >> the ctkWorkflowGroupBox listens for the currentStepChanged signal to
> >> update the title (==name) and subTitle (==description) for the current
> >> step.
> >>
> >> So maybe it makes sense to invoke this signal when the
> >> ctkWorkflow.start() gets called?
> >>
> >> If I do it manually like that, it works:
> >>
> >> self.workflow.start()
> >> self.workflow.currentStepChanged(steps[0])
> >>
> >> Cheers,
> >> Daniel
> >>
> >> On Fri, Jun 3, 2011 at 12:17 PM, Daniel Haehn <haehn at bwh.harvard.edu>
> >> wrote:
> >> > Hi devels,
> >> >
> >> > in C++ I can do
> >> >
> >> > this->setName("Title of step");
> >> > this->setDescription("Instructions");
> >> >
> >> > in a ctkWorkflowWidgetStep, which then get nicely displayed in the
> >> > associated ctkWorkflowGroupBox.
> >> >
> >> > In Python, the same methods can be accessed but the
> >> > ctkWorkflowGroupBox does not seem to show them.
> >> >
> >> > Do I need to trigger an update on the box or something similar?
> >> >
> >> > Thank you!
> >> > Daniel
> >> >
> >> _______________________________________________
> >> Ctk-developers mailing list
> >> Ctk-developers at commontk.org
> >> http://public.kitware.com/cgi-bin/mailman/listinfo/ctk-developers
> >>
> >
> >
> >
> > --
> > Danielle Pace, M.ESc.
> > Research and Development Engineer
> > Kitware Inc.,
> > North Carolina Office
> > www.kitware.com
> > 919-969-6990 X 319
> >
>
--
Danielle Pace, M.ESc.
Research and Development Engineer
Kitware Inc.,
North Carolina Office
www.kitware.com
919-969-6990 X 319
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/ctk-developers/attachments/20110603/7a885189/attachment.htm>
More information about the Ctk-developers
mailing list