Beispiel #1
0
    def __init__(self, parent=None):
        """ QParameterExplorationTable(parent: QWidget)
                                       -> QParameterExplorationTable
        Create an grid layout and accept drops
        
        """
        QPromptWidget.__init__(self, parent)
        self.pipeline = None
        self.setSizePolicy(QtGui.QSizePolicy.Expanding,
                           QtGui.QSizePolicy.Expanding)
        self.setPromptText('Drag aliases/parameters here for a parameter '
                           'exploration')
        self.showPrompt()
        
        vLayout = QtGui.QVBoxLayout(self)
        vLayout.setSpacing(0)
        vLayout.setMargin(0)
        vLayout.setAlignment(QtCore.Qt.AlignTop)
        self.setLayout(vLayout)

        self.label = QDimensionLabel()

        for labelIcon in self.label.labelIcons:
            self.connect(labelIcon.countWidget,
                         QtCore.SIGNAL('editingFinished()'),
                         self.updateWidgets)
        vLayout.addWidget(self.label)

        for i in xrange(2):
            hBar = QtGui.QFrame()
            hBar.setFrameStyle(QtGui.QFrame.HLine | QtGui.QFrame.Sunken)
            vLayout.addWidget(hBar)
        self._parameterCount = 0
Beispiel #2
0
    def __init__(self, parent=None):
        """ QParameterExplorationTable(parent: QWidget)
                                       -> QParameterExplorationTable
        Create an grid layout and accept drops
        
        """
        QPromptWidget.__init__(self, parent)
        self.pipeline = None
        self.setSizePolicy(QtGui.QSizePolicy.Expanding,
                           QtGui.QSizePolicy.Expanding)
        self.setPromptText('Drag aliases/parameters here for a parameter '
                           'exploration')
        self.showPrompt()
        
        vLayout = QtGui.QVBoxLayout(self)
        vLayout.setSpacing(0)
        vLayout.setMargin(0)
        vLayout.setAlignment(QtCore.Qt.AlignTop)
        self.setLayout(vLayout)

        self.label = QDimensionLabel()

        for labelIcon in self.label.labelIcons:
            self.connect(labelIcon.countWidget,
                         QtCore.SIGNAL('editingFinished()'),
                         self.updateWidgets)
        vLayout.addWidget(self.label)

        for i in xrange(2):
            hBar = QtGui.QFrame()
            hBar.setFrameStyle(QtGui.QFrame.HLine | QtGui.QFrame.Sunken)
            vLayout.addWidget(hBar)
        self._parameterCount = 0
Beispiel #3
0
 def __init__(self, module, controller, parent=None):
     StandardModuleConfigurationWidget.__init__(self, module, controller,
                                                parent)
     self.prompt = QPromptWidget()
     self.prompt.setPromptText("Please use the visibility icon (an eye) in"
                               " the Module Information panel to show or"
                               " hide a port.")
     layout = QtGui.QVBoxLayout()
     layout.addWidget(self.prompt)
     self.setLayout(layout)
     self.prompt.showPrompt()
 def __init__(self, parent=None):
     QtGui.QWidget.__init__(self, parent)
     self.variables = []
     self.plot = None
     self.var_prompt = QPromptWidget()
     self.var_prompt.setPromptText("Drag and drop a variable here")
     self.var_prompt.showPrompt()
     self.plot_prompt = QPromptWidget()
     self.plot_prompt.setPromptText("Drag and drop a plot type here")
     self.plot_prompt.showPrompt()
     layout = QtGui.QVBoxLayout()
     layout.addWidget(self.var_prompt)
     layout.addWidget(self.plot_prompt)
     self.setLayout(layout)
Beispiel #5
0
 def __init__(self, parent=None):
     """ QVerticalWidget(parent: QWidget) -> QVerticalWidget
     Initialize with a vertical layout
     
     """
     QPromptWidget.__init__(self, parent)
     self.setPromptText("Drag a constant from the Modules panel to create a variable")
     self.setLayout(QtGui.QVBoxLayout())
     self.layout().setMargin(0)
     self.layout().setSpacing(5)
     self.layout().setAlignment(QtCore.Qt.AlignTop)
     self.setSizePolicy(QtGui.QSizePolicy.Expanding,
                        QtGui.QSizePolicy.Expanding)
     self.setMinimumHeight(20)
     self._variable_widgets = []
 def __init__(self, parent=None):
     """ QVerticalWidget(parent: QWidget) -> QVerticalWidget
     Initialize with a vertical layout
     
     """
     QPromptWidget.__init__(self, parent)
     self.setPromptText("Drag methods here to set parameters")
     self.setLayout(QtGui.QVBoxLayout())
     self.layout().setMargin(0)
     self.layout().setSpacing(5)
     self.layout().setAlignment(QtCore.Qt.AlignTop)
     self.setSizePolicy(QtGui.QSizePolicy.Expanding,
                        QtGui.QSizePolicy.Expanding)
     self.formType = QMethodInputForm
     self.setMinimumHeight(50)
     self._functions = []
Beispiel #7
0
 def __init__(self, parent=None):
     """ QVerticalWidget(parent: QWidget) -> QVerticalWidget
     Initialize with a vertical layout
     
     """
     QPromptWidget.__init__(self, parent)
     self.setPromptText("Drag methods here to set parameters")
     self.setLayout(QtGui.QVBoxLayout())
     self.layout().setMargin(0)
     self.layout().setSpacing(5)
     self.layout().setAlignment(QtCore.Qt.AlignTop)
     self.setSizePolicy(QtGui.QSizePolicy.Expanding,
                        QtGui.QSizePolicy.Expanding)
     self.formType = QMethodInputForm
     self.setMinimumHeight(50)
     self._functions = []
Beispiel #8
0
class DefaultModuleConfigurationWidget(StandardModuleConfigurationWidget):
    def __init__(self, module, controller, parent=None):
        StandardModuleConfigurationWidget.__init__(self, module, controller, 
                                                   parent)
        self.prompt = QPromptWidget()
        self.prompt.setPromptText("Please use the visibility icon (an eye) in" 
                                  " the Module Information panel to show or"
                                  " hide a port.")
        layout = QtGui.QVBoxLayout()
        layout.addWidget(self.prompt)
        self.setLayout(layout)
        self.prompt.showPrompt()
        
    def saveTriggered(self):
        pass
    
    def resetTriggered(self):
        pass
Beispiel #9
0
class QPromptCellWidget(QCellContainer):
    def __init__(self, parent=None):
        QtGui.QWidget.__init__(self, parent)
        self.variables = []
        self.plot = None
        self.var_prompt = QPromptWidget()
        self.var_prompt.setPromptText("Drag and drop a variable here")
        self.var_prompt.showPrompt()
        self.plot_prompt = QPromptWidget()
        self.plot_prompt.setPromptText("Drag and drop a plot type here")
        self.plot_prompt.showPrompt()

        prompt_font_size = 16
        self.var_prompt.promptFont.setPointSize(prompt_font_size)
        self.plot_prompt.promptFont.setPointSize(prompt_font_size)

        layout = QtGui.QVBoxLayout()
        layout.addWidget(self.var_prompt)
        layout.addWidget(self.plot_prompt)
        self.setLayout(layout)

    def setPlot(self, plot):
        pass

    def addVariable(self, varName):
        pass

    def updateVarPrompt(self):
        pass

    def setVarPromptText(self, text):
        self.var_prompt.setPromptText(text)

    def setPlotPromptText(self, text):
        self.plot_prompt.setPromptText(text)

    def dumpToFile(self, filename):
        #do nothing
        pass

    def saveToPDF(self, filename):
        #do nothing
        pass
Beispiel #10
0
class QPromptCellWidget(QCellContainer):
    def __init__(self, parent=None):
        QtGui.QWidget.__init__(self, parent)
        self.variables = []
        self.plot = None
        self.var_prompt = QPromptWidget()
        self.var_prompt.setPromptText("Drag and drop a variable here")
        self.var_prompt.showPrompt()
        self.plot_prompt = QPromptWidget()
        self.plot_prompt.setPromptText("Drag and drop a plot type here")
        self.plot_prompt.showPrompt()
        layout = QtGui.QVBoxLayout()
        layout.addWidget(self.var_prompt)
        layout.addWidget(self.plot_prompt)
        self.setLayout(layout)
        
    def setPlot(self, plot):
        pass
        
    def addVariable(self, varName):
        pass
        
    def updateVarPrompt(self):
        pass
            
    def setVarPromptText(self, text):
        self.var_prompt.setPromptText(text)
        
    def setPlotPromptText(self, text):
        self.plot_prompt.setPromptText(text)
        
    def dumpToFile(self, filename):
        #do nothing
        pass
    
    def saveToPDF(self, filename):
        #do nothing
        pass