示例#1
0
    def __init__(self, parent=None):
        super(Page3, self).__init__(parent)
        integerValidator = QtGui.QIntValidator(0, 10, self)

        coordLabel = QtWidgets.QLabel('Coordinate File:')
        self.coordLine = QtWidgets.QLineEdit()
        coordBtn = QtWidgets.QPushButton('File', self)
        coordBtn.clicked.connect(self.getCoordfile)
        self.registerField('coordFile*', self.coordLine)

        popLabel = QtWidgets.QLabel('Population File:')
        self.popLine = QtWidgets.QLineEdit()
        popBtn = QtWidgets.QPushButton('File', self)
        popBtn.clicked.connect(self.getPopfile)
        self.registerField('popFile*', self.popLine)

        grid = QtWidgets.QGridLayout()
        grid.setSpacing(10)
        grid.addWidget(coordLabel, 1, 0)
        grid.addWidget(self.coordLine, 1, 1)
        grid.addWidget(coordBtn, 1, 2)
        grid.addWidget(popLabel, 2, 0)
        grid.addWidget(self.popLine, 2, 1)
        grid.addWidget(popBtn, 2, 2)
        self.setLayout(grid)
示例#2
0
    def __init__(self, parent=None):
        super(Page1, self).__init__(parent)
        integerValidator = QtGui.QIntValidator(0, 100, self)

        coordLabel = QtWidgets.QLabel('Coordinate File:')
        self.coordLine = QtWidgets.QLineEdit()
        coordBtn = QtWidgets.QPushButton('File', self)
        coordBtn.clicked.connect(self.getCoordfile)
        self.registerField('coordFile*', self.coordLine)

        popLabel = QtWidgets.QLabel('Population File:')
        self.popLine = QtWidgets.QLineEdit()
        popBtn = QtWidgets.QPushButton('File', self)
        popBtn.clicked.connect(self.getPopfile)
        self.registerField('popFile*', self.popLine)

        dataLabel = QtWidgets.QLabel('Data Directory:')
        self.dataLine = QtWidgets.QLineEdit()
        dataBtn = QtWidgets.QPushButton('File', self)
        dataBtn.clicked.connect(self.getDir)
        self.registerField('dataDir*', self.dataLine)

        allelesLabel = QtWidgets.QLabel('Number of alleles:')
        self.allelesLine = QtWidgets.QLineEdit()
        self.allelesLine.setValidator(integerValidator)
        self.registerField('alleleCount*', self.allelesLine)

        groupsLabel = QtWidgets.QLabel('Number of Groups:')
        self.groupsLine = QtWidgets.QLineEdit()
        self.groupsLine.setValidator(integerValidator)
        self.registerField('groupCount*', self.groupsLine)

        grid = QtWidgets.QGridLayout()
        grid.setSpacing(10)
        grid.addWidget(coordLabel, 1, 0)
        grid.addWidget(self.coordLine, 1, 1)
        grid.addWidget(coordBtn, 1, 2)
        grid.addWidget(popLabel, 2, 0)
        grid.addWidget(self.popLine, 2, 1)
        grid.addWidget(popBtn, 2, 2)
        grid.addWidget(dataLabel, 3, 0)
        grid.addWidget(self.dataLine, 3, 1)
        grid.addWidget(dataBtn, 3, 2)
        grid.addWidget(allelesLabel, 4, 0)
        grid.addWidget(self.allelesLine, 4, 1)
        grid.addWidget(groupsLabel, 5, 0)
        grid.addWidget(self.groupsLine, 5, 1)

        self.setLayout(grid)
示例#3
0
    def __init__(self, parent=None):
        super(StartP, self).__init__(parent)
        integerValidator = QtGui.QIntValidator(0, 300, self)

        dataLabel = QtWidgets.QLabel('Data Directory:')
        self.dataLine = QtWidgets.QLineEdit()
        dataBtn = QtWidgets.QPushButton('File', self)
        dataBtn.clicked.connect(self.getDir)
        self.registerField('dataDir*', self.dataLine)

        allelesLabel = QtWidgets.QLabel('Number of alleles:')
        self.allelesLine = QtWidgets.QLineEdit()
        self.allelesLine.setValidator(integerValidator)
        self.registerField('alleleCount*', self.allelesLine)

        groupsLabel = QtWidgets.QLabel('Number of Groups:')
        self.groupsLine = QtWidgets.QLineEdit()
        self.groupsLine.setValidator(integerValidator)
        self.registerField('groupCount*', self.groupsLine)

        self.b1 = QtWidgets.QCheckBox("Females")
        self.b1.setChecked(False)
        self.registerField('females', self.b1)

        comboLabel = QtWidgets.QLabel('Graphic Type:')
        self.combo = QtWidgets.QComboBox(self)
        self.combo.addItem('Allele Counts')
        self.combo.addItem('Allele Heatmap')
        self.combo.addItem('Allele Stack')
        self.combo.addItem('Allele Geo-Map')
        self.registerField('graphic', self.combo)

        grid = QtWidgets.QGridLayout()
        grid.setSpacing(10)
        grid.addWidget(dataLabel, 1, 0)
        grid.addWidget(self.dataLine, 1, 1)
        grid.addWidget(dataBtn, 1, 2)
        grid.addWidget(allelesLabel, 2, 0)
        grid.addWidget(self.allelesLine, 2, 1)
        grid.addWidget(groupsLabel, 3, 0)
        grid.addWidget(self.groupsLine, 3, 1)
        grid.addWidget(self.b1, 5, 1)
        grid.addWidget(comboLabel, 4, 0)
        grid.addWidget(self.combo, 4, 1)
        self.setLayout(grid)
示例#4
0
 def initializePage(self):
     groups = int(self.field('groupCount'))
     alleles = int(self.field('alleleCount'))
     integerValidator = QtGui.QIntValidator(0, 10, self)
     vbox = self.layout()
     for i in range(groups):
         hbox = QtWidgets.QHBoxLayout()
         glabel = QtWidgets.QLabel("group " + str(i + 1) + ":")
         for j in range(alleles):
             label = QtWidgets.QLabel(str(j + 1) + ":")
             line = QtWidgets.QLineEdit()
             line.setValidator(integerValidator)
             line.setText('0')
             self.registerField(str(i) + '-' + str(j), line)
             hbox.addWidget(label)
             hbox.addWidget(line)
         vbox.addWidget(glabel)
         vbox.addLayout(hbox)
示例#5
0
    def __init__(self, parent=None):
        super(Page4, self).__init__(parent)
        integerValidator = QtGui.QIntValidator(0, 10, self)

        comboLabel = QtWidgets.QLabel('Graphic Type:')
        dataLabel = QtWidgets.QLabel('Data Directory:')
        self.dataLine = QtWidgets.QLineEdit()
        dataBtn = QtWidgets.QPushButton('File', self)
        dataBtn.clicked.connect(self.getDir)
        self.registerField('popDir*', self.dataLine)

        allelesLabel = QtWidgets.QLabel('Number of alleles:')
        self.allelesLine = QtWidgets.QLineEdit()
        self.allelesLine.setValidator(integerValidator)
        self.registerField('alleleCount2*', self.allelesLine)

        groupsLabel = QtWidgets.QLabel('Number of Groups:')
        self.groupsLine = QtWidgets.QLineEdit()
        self.groupsLine.setValidator(integerValidator)
        self.registerField('groupCount2*', self.groupsLine)

        self.b1 = QtWidgets.QCheckBox("Females")
        self.b1.setChecked(False)
        self.registerField('females', self.b1)

        grid = QtWidgets.QGridLayout()
        grid.setSpacing(10)
        grid.addWidget(dataLabel, 1, 0)
        grid.addWidget(self.dataLine, 1, 1)
        grid.addWidget(dataBtn, 1, 2)
        grid.addWidget(allelesLabel, 2, 0)
        grid.addWidget(self.allelesLine, 2, 1)
        grid.addWidget(groupsLabel, 3, 0)
        grid.addWidget(self.groupsLine, 3, 1)
        grid.addWidget(self.b1, 4, 1)

        self.setLayout(grid)