![]() ![]() The main question is though: How to add my own module widget to another module? I mentioned my path to arrive at this question as any advice/ comment on this would be appreciated as well and might allow a better approach. Do I need to implement createNewWidgetRepresentation or add some other bits? I couldn’t find examples for this. ![]() I would have expected to be able to intantiate the widget as it is. Starting from the wizard to create a scriptable module, I end up with a python file containing the following classes: MyModule, MyModuleWidget, MyModuleLogic, MyModuleTest, as well as the GUI file. ![]() I get the following error: 'MyModuleWidget' object has no attribute 'createNewWidgetRepresentation' Trying this command: ("Markups").layout().addWidget(MyModuleWidget()) I managed to clean up and simplify the markups module as desired but struggle to see what needs to be done to instantiate my module as a widget. This might actually make the most sense design wise, according to my current understanding. My next approach was to add my new functionality as a widget into the markups module (and hide all the UI elements not needed). cxx file but seem to not understand enough of it to connect the data node and actually display the control points in the table. I tried replicating the setup according to the. I then used () to include the Markups module into my module but still was missing the functionality of the activeMarkupTableWidget. It seems to have not been made available as a widget or the function logic made accessible from outside so that I could easily replicate the functionality. The widget I am missing would be what is in the Control Points collapsible button - mainly the functions on the activeMarkupTableWidget. Learning more about the concept of reusable widgets, I tried to include the widgets I need from Markups. Initially, my concept was to create a new GUI that mirrors and wraps the relevant functionality of the Markups module. The module should do the communication with an XNAT server to pull the images and push the annotation files (markup JSON files). My concept was to simplify the workflow for a clinician to annotate several images. I have been using Slicer for some basic tasks in the past and just now have started developing my own module. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |