Exemplo n.º 1
0
 def __init__(self, loc_connections, image_connections,
              props_connections, bbox,
              external_loc=None, parent=None, main_ref=None,
              functional_manager=None):
     """
     Creates a new OverlayWindow type
     """
     self.loc_connections = loc_connections
     self.image_connections = image_connections
     self.props_connections = props_connections
     self.external_loc = external_loc
     TopLevelAuxiliaryWindow.__init__(self, window_name=self.tool_name,
                                      parent=parent, main_ref=main_ref)
     if functional_manager is not None:
         functional_manager.loc_signal=self.loc_changed
         functional_manager.image_signal=self.image_changed
         functional_manager.props_signal=self.image_props_changed
         self.func_man = functional_manager
Exemplo n.º 2
0
 def __init__(self, parent=None, main_ref=None,
              functional_manager=None, manage_overlay=True,
              **traits):
     TopLevelAuxiliaryWindow.__init__(self,
                                      parent=parent,
                                      main_ref=main_ref)
     layout = QtGui.QVBoxLayout(self)
     layout.setMargin(0)
     layout.setSpacing(0)
     if functional_manager:
         traits['func_man'] = functional_manager
     from xipy.vis.mayavi_widgets.ortho_viewer_3d import OrthoViewer3D
     self.mr_vis = OrthoViewer3D(manage_overlay=manage_overlay, **traits)
     vis_panel = self.mr_vis.edit_traits(parent=self,
                                         kind='subpanel').control
     layout.addWidget(vis_panel)
     self.func_widget = None
     self.layout_box = layout
     if functional_manager is not None:
         self.add_toolbar(functional_manager)
     QtGui.QWidget.setSizePolicy(vis_panel,
                                 QtGui.QSizePolicy.Expanding,
                                 QtGui.QSizePolicy.Expanding)
     self.setObjectName('3D Plot')