updateParameterNodeFromGUI not called when ui is updated because connect() don't work

hi,

I want to create a python module for slicer and i got a problem with the UI.
When the UI is updated it doesn’t call the updateParameterNodeFromGUI() function and i think it’s because the widget i use isn’t supported by the slicer library.
I’ve got the line :

self.ui.thresholdFloatInput.connect(“currentNodeChanged(vtkMRMLNode*)”, self.updateParameterNodeFromGUI)

but there’s this error that show up every time :

PythonQt: QObject::connect() signal ‘currentNodeChanged(vtkMRMLNode*)’ does not exist on qMRMLSpinBox

I already tried to use different widget (from Qt designer, ctkVTK, ctk and qMRML) but none of them worked.
I would greatly appreciate any help on what i should use or what i’m misunderstanding here.
Thanks !

For qMRMLSpinBox, you will want to use the “valueChanged(double)” signal.

1 Like

It worked perfectly, thank you very much !
Do you know where i can get the assigned signal of every widget please ?

The API documentation for Slicer is a good place to start for MRML widgets: Slicer: qMRMLSpinBox Class Reference.

In this case however, despite valueChanged being inherited from ctkDoubleSpinBox it is not documented in in the member list.

For CTK widgets I would check the CTK API documentation, though it appears to be down right now.
For Qt widgets I would check the Qt API documentation.

I already saw the documentation for MRML widget but i never learned c++ so i was a bit lost and i couldn’t find the signaled associated with the widget, but thank you for the other link !