def setup(self):
ScriptedLoadableModuleWidget.setup(self)
# Joint collapsible button
jointcollapsibleButton = ctk.ctkCollapsibleButton()
jointcollapsibleButton.text = "Joints"
#jointcollapsibleButton.enabled = False
self.layout.addWidget(jointcollapsibleButton)
I try to write a py module like upper code. But when I add to slicer. I get an error:
Traceback (most recent call last):
File "D:\Program Files\Slicer 4.11.0-2018-12-16\bin\Python\slicer\ScriptedLoadableModule.py", line 87, in init
self.layout = self.parent.layout()
AttributeError: qSlicerScriptedLoadableModule has no attribute named ‘layout’