Python PyQt5.QtWidgets 模块,QFormLayout() 实例源码

我们从Python开源项目中,提取了以下50个代码示例,用于说明如何使用PyQt5.QtWidgets.QFormLayout()

项目:pytc-gui    作者:harmslab    | 项目源码 | 文件源码
def layout(self):
        """
        """
        main_layout = QW.QVBoxLayout(self)
        form_layout = QW.QFormLayout()

        version = pkg_resources.require("pytc-gui")[0].version

        name_label = QW.QLabel("pytc: GUI")
        name_font = name_label.font()
        name_font.setPointSize(20)
        name_label.setFont(name_font)
        name_label.setAlignment(Qt.AlignCenter)

        version_label = QW.QLabel("Version " + version)
        version_font = version_label.font()
        version_font.setPointSize(14)
        version_label.setFont(version_font)
        version_label.setAlignment(Qt.AlignCenter)

        author_info = QW.QLabel("Hiranmayi Duvvuri, Mike Harms")
        author_font = author_info.font()
        author_font.setPointSize(10)
        author_info.setFont(author_font)

        OK_button = QW.QPushButton("OK", self)
        OK_button.clicked.connect(self.close)

        main_layout.addWidget(name_label)
        main_layout.addWidget(version_label)
        main_layout.addWidget(author_info)
        main_layout.addWidget(OK_button)

        self.setWindowTitle("About")
项目:pytc-gui    作者:harmslab    | 项目源码 | 文件源码
def layout(self):
        """
        """
        main_layout = QW.QVBoxLayout(self)
        form_layout = QW.QFormLayout()

        pytc_docs = "<a href=\"https://pytc.readthedocs.io/en/latest/\">documentation</a>"
        gui_docs = "<a href=\"https://pytc-gui.readthedocs.io/en/latest/\">documentation</a>"

        pytc_label = QW.QLabel(pytc_docs)
        pytc_label.setOpenExternalLinks(True)

        gui_label = QW.QLabel(gui_docs)
        gui_label.setOpenExternalLinks(True)

        form_layout.addRow(QW.QLabel("pytc:"), pytc_label)
        form_layout.addRow(QW.QLabel("pytc-gui:"), gui_label)

        OK_button = QW.QPushButton("OK", self)
        OK_button.clicked.connect(self.close)

        main_layout.addLayout(form_layout)
        main_layout.addWidget(OK_button)

        self.setWindowTitle("Documentation")
项目:git-annex-metadata-gui    作者:alpernebbi    | 项目源码 | 文件源码
def clear(self):
        try:
            model = self._item.model()
        except (AttributeError, RuntimeError):
            pass
        else:
            model.columnsInserted.disconnect(self._on_columns_inserted)
            self.new_field_requested.disconnect(model.insert_field)

        self._item = None
        self._fields = []
        self._new_field_edit = None
        self.setTitle('')

        if self.layout() is not None:
            while self.layout().count():
                item = self.layout().takeAt(0)
                if item:
                    item.widget().deleteLater()
            sip.delete(self.layout())

        layout = QtWidgets.QFormLayout()
        layout.setFieldGrowthPolicy(layout.FieldsStayAtSizeHint)
        self.setLayout(layout)
项目:axopy    作者:ucdrascal    | 项目源码 | 文件源码
def __init__(self, configurations=None, parent=None):
        super(SessionInfoWidget, self).__init__(parent=parent)

        main_layout = QtWidgets.QVBoxLayout()
        self.setLayout(main_layout)

        form_layout = QtWidgets.QFormLayout()
        form_layout.setFormAlignment(QtCore.Qt.AlignVCenter)
        main_layout.addLayout(form_layout)

        if configurations is not None:
            self._config_combo_box = QtWidgets.QComboBox()
            form_layout.addRow("Configuration", self._config_combo_box)

            for config in configurations:
                self._config_combo_box.addItem(config)

        self._subject_line_edit = QtWidgets.QLineEdit()
        form_layout.addRow("Subject", self._subject_line_edit)

        self._button = QtWidgets.QPushButton("Start")
        main_layout.addWidget(self._button)

        self._button.clicked.connect(self._on_button_click)
项目:plexdesktop    作者:coryo    | 项目源码 | 文件源码
def __init__(self, parent=None):
        super().__init__(parent)
        self.setWindowTitle('Manual Add Server')
        self.form = QtWidgets.QFormLayout(self)
        self.secure = QtWidgets.QCheckBox()
        self.address = QtWidgets.QLineEdit()
        self.port = QtWidgets.QLineEdit('32400')
        self.token = QtWidgets.QLineEdit()
        self.form.addRow(QtWidgets.QLabel('HTTPS?'), self.secure)
        self.form.addRow(QtWidgets.QLabel('Address'), self.address)
        self.form.addRow(QtWidgets.QLabel('Port'), self.port)
        self.form.addRow(QtWidgets.QLabel('Access Token (optional)'), self.token)
        self.buttons = QtWidgets.QDialogButtonBox(
            QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, QtCore.Qt.Horizontal, self)
        self.form.addRow(self.buttons)
        self.buttons.rejected.connect(self.reject)
        self.buttons.accepted.connect(self.accept)
项目:vivisect-py3    作者:bat-serjo    | 项目源码 | 文件源码
def __init__(self, config, parent=None):
        QtWidgets.QWidget.__init__(self, parent=parent)
        self.enviconfig = config

        lyt = QtWidgets.QFormLayout()

        optnames = list(config.keys())
        optnames.sort()

        for optname in optnames:
            optval = config.get(optname)
            cls = cfgtypes.get(type(optval))
            if cls is None:
                # print('no class: %r' % val)
                continue

            label = QtWidgets.QLabel(optname)
            clsobj = cls(config, optname, optval, parent=self)
            doc = config.getOptionDoc(optname)
            if doc is not None:
                label.setToolTip(doc)
            lyt.addRow(label, clsobj)

        self.setLayout(lyt)
项目:pysport    作者:sportorg    | 项目源码 | 文件源码
def init_ui(self):
        self.setWindowTitle(_('Start times'))
        self.setWindowIcon(QIcon(config.ICON))
        self.setSizeGripEnabled(False)
        self.setModal(True)

        self.layout = QFormLayout(self)

        self.text = QTextEdit()
        self.text.setMinimumHeight(450)
        self.text.setMinimumWidth(450)
        self.text.setMaximumHeight(450)
        self.layout.addRow(self.text)

        self.set_text()

        def cancel_changes():
            self.close()

        def apply_changes():
            try:
                self.apply_changes_impl()
            except Exception as e:
                logging.exception(str(e))
            self.close()

        self.button_ok = QPushButton(_('Save to file'))
        self.button_ok.clicked.connect(apply_changes)
        self.button_cancel = QPushButton(_('Cancel'))
        self.button_cancel.clicked.connect(cancel_changes)
        self.layout.addRow(self.button_ok, self.button_cancel)

        self.show()
项目:Mac-Python-3.X    作者:L1nwatch    | 项目源码 | 文件源码
def setupUi(self, Window):
        Window.setObjectName("Window")
        Window.resize(640, 480)
        self.verticalLayout = QtWidgets.QVBoxLayout(Window)
        self.verticalLayout.setObjectName("verticalLayout")
        self.webView = QtWebKitWidgets.QWebView(Window)
        self.webView.setUrl(QtCore.QUrl("http://webkit.org/"))
        self.webView.setObjectName("webView")
        self.verticalLayout.addWidget(self.webView)
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.formLayout = QtWidgets.QFormLayout()
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.ExpandingFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.elementLabel = QtWidgets.QLabel(Window)
        self.elementLabel.setObjectName("elementLabel")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.elementLabel)
        self.elementLineEdit = QtWidgets.QLineEdit(Window)
        self.elementLineEdit.setObjectName("elementLineEdit")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.elementLineEdit)
        self.horizontalLayout.addLayout(self.formLayout)
        self.highlightButton = QtWidgets.QPushButton(Window)
        self.highlightButton.setObjectName("highlightButton")
        self.horizontalLayout.addWidget(self.highlightButton)
        self.verticalLayout.addLayout(self.horizontalLayout)
        self.elementLabel.setBuddy(self.elementLineEdit)

        self.retranslateUi(Window)
        QtCore.QMetaObject.connectSlotsByName(Window)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupBox = QtWidgets.QGroupBox(Form)
        self.groupBox.setObjectName("groupBox")
        self.formLayout = QtWidgets.QFormLayout(self.groupBox)
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.nc_label = QtWidgets.QLabel(self.groupBox)
        self.nc_label.setObjectName("nc_label")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.nc_label)
        self.nc_spin = QtWidgets.QSpinBox(self.groupBox)
        self.nc_spin.setObjectName("nc_spin")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.nc_spin)
        self.verticalLayout.addWidget(self.groupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupbox = QtWidgets.QGroupBox(Form)
        self.groupbox.setObjectName("groupbox")
        self.formLayout_2 = QtWidgets.QFormLayout(self.groupbox)
        self.formLayout_2.setObjectName("formLayout_2")
        self.halfWindowLabel = QtWidgets.QLabel(self.groupbox)
        self.halfWindowLabel.setObjectName("halfWindowLabel")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.halfWindowLabel)
        self.halfWindowSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.halfWindowSpinBox.setObjectName("halfWindowSpinBox")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.halfWindowSpinBox)
        self.numOfErosionsLabel = QtWidgets.QLabel(self.groupbox)
        self.numOfErosionsLabel.setObjectName("numOfErosionsLabel")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.numOfErosionsLabel)
        self.numOfErosionsSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.numOfErosionsSpinBox.setObjectName("numOfErosionsSpinBox")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.numOfErosionsSpinBox)
        self.verticalLayout.addWidget(self.groupbox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupBox = QtWidgets.QGroupBox(Form)
        self.groupBox.setObjectName("groupBox")
        self.formLayout = QtWidgets.QFormLayout(self.groupBox)
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.nc_label = QtWidgets.QLabel(self.groupBox)
        self.nc_label.setObjectName("nc_label")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.nc_label)
        self.nc_spin = QtWidgets.QSpinBox(self.groupBox)
        self.nc_spin.setObjectName("nc_spin")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.nc_spin)
        self.verticalLayout.addWidget(self.groupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupbox = QtWidgets.QGroupBox(Form)
        self.groupbox.setObjectName("groupbox")
        self.formLayout_2 = QtWidgets.QFormLayout(self.groupbox)
        self.formLayout_2.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout_2.setObjectName("formLayout_2")
        self.windowSizeLabel = QtWidgets.QLabel(self.groupbox)
        self.windowSizeLabel.setObjectName("windowSizeLabel")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.windowSizeLabel)
        self.windowSizeSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.windowSizeSpinBox.setObjectName("windowSizeSpinBox")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.windowSizeSpinBox)
        self.numOfRangesLabel = QtWidgets.QLabel(self.groupbox)
        self.numOfRangesLabel.setObjectName("numOfRangesLabel")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.numOfRangesLabel)
        self.numOfRangesSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.numOfRangesSpinBox.setObjectName("numOfRangesSpinBox")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.numOfRangesSpinBox)
        self.verticalLayout.addWidget(self.groupbox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.formGroupBox = QtWidgets.QGroupBox(Form)
        self.formGroupBox.setObjectName("formGroupBox")
        self.formLayout = QtWidgets.QFormLayout(self.formGroupBox)
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.chooseDataToDerivLabel = QtWidgets.QLabel(self.formGroupBox)
        self.chooseDataToDerivLabel.setObjectName("chooseDataToDerivLabel")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.chooseDataToDerivLabel)
        self.chooseDataToDerivComboBox = QtWidgets.QComboBox(self.formGroupBox)
        self.chooseDataToDerivComboBox.setObjectName("chooseDataToDerivComboBox")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.chooseDataToDerivComboBox)
        self.verticalLayout.addWidget(self.formGroupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.formGroupBox = QtWidgets.QGroupBox(Form)
        self.formGroupBox.setObjectName("formGroupBox")
        self.formLayout = QtWidgets.QFormLayout(self.formGroupBox)
        self.formLayout.setObjectName("formLayout")
        self.numOfComponentsLabel = QtWidgets.QLabel(self.formGroupBox)
        self.numOfComponentsLabel.setObjectName("numOfComponentsLabel")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.numOfComponentsLabel)
        self.numOfComponentsLineEdit = QtWidgets.QLineEdit(self.formGroupBox)
        self.numOfComponentsLineEdit.setObjectName("numOfComponentsLineEdit")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.numOfComponentsLineEdit)
        self.verticalLayout.addWidget(self.formGroupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupBox = QtWidgets.QGroupBox(Form)
        self.groupBox.setObjectName("groupBox")
        self.formLayout = QtWidgets.QFormLayout(self.groupBox)
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.fitInterceptLabel = QtWidgets.QLabel(self.groupBox)
        self.fitInterceptLabel.setObjectName("fitInterceptLabel")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.fitInterceptLabel)
        self.fitInterceptCheckBox = QtWidgets.QCheckBox(self.groupBox)
        self.fitInterceptCheckBox.setChecked(True)
        self.fitInterceptCheckBox.setObjectName("fitInterceptCheckBox")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.fitInterceptCheckBox)
        self.verticalLayout.addWidget(self.groupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupBox = QtWidgets.QGroupBox(Form)
        self.groupBox.setObjectName("groupBox")
        self.formLayout = QtWidgets.QFormLayout(self.groupBox)
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.nc_label = QtWidgets.QLabel(self.groupBox)
        self.nc_label.setObjectName("nc_label")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.nc_label)
        self.nc_spin = QtWidgets.QSpinBox(self.groupBox)
        self.nc_spin.setObjectName("nc_spin")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.nc_spin)
        self.verticalLayout.addWidget(self.groupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.formGroupBox = QtWidgets.QGroupBox(Form)
        self.formGroupBox.setObjectName("formGroupBox")
        self.formLayout = QtWidgets.QFormLayout(self.formGroupBox)
        self.formLayout.setObjectName("formLayout")
        self.numOfComponentsLabel = QtWidgets.QLabel(self.formGroupBox)
        self.numOfComponentsLabel.setObjectName("numOfComponentsLabel")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.numOfComponentsLabel)
        self.numOfComponentsLineEdit = QtWidgets.QLineEdit(self.formGroupBox)
        self.numOfComponentsLineEdit.setObjectName("numOfComponentsLineEdit")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.numOfComponentsLineEdit)
        self.verticalLayout.addWidget(self.formGroupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupbox = QtWidgets.QGroupBox(Form)
        self.groupbox.setObjectName("groupbox")
        self.formLayout_2 = QtWidgets.QFormLayout(self.groupbox)
        self.formLayout_2.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout_2.setObjectName("formLayout_2")
        self.windowSizeLabel = QtWidgets.QLabel(self.groupbox)
        self.windowSizeLabel.setObjectName("windowSizeLabel")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.windowSizeLabel)
        self.windowSizeSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.windowSizeSpinBox.setObjectName("windowSizeSpinBox")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.windowSizeSpinBox)
        self.verticalLayout.addWidget(self.groupbox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:songscreen    作者:maccesch    | 项目源码 | 文件源码
def __init__(self, *args, **kwargs):
        super(EpubsPage, self).__init__(*args, **kwargs)

        self.existing = False

        self.setTitle(self.tr("Import Songbooks"))

        self.setSubTitle(self.tr("Download the old and new songbooks as EPUB files from jw.org to import them here"))

        layout = QFormLayout()

        self.old_epub_button = QPushButton(text=self.tr("Select File..."), clicked=self._old_epub_dialog)
        self.new_epub_button = QPushButton(text=self.tr("Select File..."), clicked=self._new_epub_dialog)

        layout.addRow(self.tr("Songbook as EPUB"), self.old_epub_button)
        layout.addRow(self.tr("New Songs as EPUB"), self.new_epub_button)

        self.setLayout(layout)

        self.old_epub = ""
        self.new_epub = ""
项目:blog    作者:benhoff    | 项目源码 | 文件源码
def __init__(self, parent=None):
        super().__init__(parent)
        self.label = QtWidgets.QLabel()
        number_label = QtWidgets.QLabel('Number of Pictures to Take')
        self.number_chooser = QtWidgets.QComboBox()
        self.number_chooser.addItems(['4', '5', '6', '7', '8', '9', '10'])
        self.delay_label = QtWidgets.QLabel('Number of Seconds to Delay')
        self.delay_chooser = QtWidgets.QComboBox()
        self.delay_chooser.addItems(['1', '1.5', '2', '4', '5', '7', '10'])

        self.go_button = QtWidgets.QPushButton('Run')

        form_layout = QtWidgets.QFormLayout()
        form_layout.addRow(number_label, self.number_chooser)
        form_layout.addRow(self.delay_label, self.delay_chooser)

        layout = QtWidgets.QVBoxLayout()
        layout.addLayout(form_layout)
        layout.addWidget(self.label)
        layout.addWidget(self.go_button)

        self.setLayout(layout)
项目:pytc-gui    作者:harmslab    | 项目源码 | 文件源码
def layout(self):
        """
        Populate the window.
        """

        self._main_layout = QW.QVBoxLayout(self)
        self._form_layout = QW.QFormLayout()

        # Combobox widget holding possible connectors
        self._connector_select_widget = QW.QComboBox(self)

        connector_names = list(self._fit.avail_connectors.keys())
        connector_names.sort()
        for n in connector_names:
            self._connector_select_widget.addItem(n)

        self._connector_select_widget.setCurrentIndex(0)
        self._connector_select_widget.activated.connect(self._update_dialog)

        # Input box holding name
        self._connector_name_input = QW.QLineEdit(self)
        self._connector_name_input.setText("connector")
        self._connector_name_input.textChanged.connect(self._update_connector_name)

        # Final OK button
        self._OK_button = QW.QPushButton("OK", self)
        self._OK_button.clicked.connect(self._ok_button_handler)

        # Add to form
        self._form_layout.addRow(QW.QLabel("Select Model:"), self._connector_select_widget)
        self._form_layout.addRow(QW.QLabel("Name:"), self._connector_name_input)

        # Populate widgets
        self._arg_widgets = {}
        self._update_dialog()

        # add to main layout
        self._main_layout.addLayout(self._form_layout)
        self._main_layout.addWidget(self._OK_button)

        self.setWindowTitle('Add new global connector')
项目:plexdesktop    作者:coryo    | 项目源码 | 文件源码
def __init__(self, media_object, parent=None):
        super().__init__(parent)
        self.setWindowTitle('Preferences')
        self.form = QtWidgets.QFormLayout(self)
        server = media_object.container.server
        settings = server.container(media_object.key)
        self.ids = []
        for item in settings['_children']:
            itype = item['type']
            if itype == 'bool':
                input_widget = QtWidgets.QCheckBox()
                input_widget.setCheckState(QtCore.Qt.Checked if item['value'] == 'true' else QtCore.Qt.Unchecked)
            elif itype == 'enum':
                input_widget = QtWidgets.QComboBox()
                input_widget.addItems(item['values'].split('|'))
                input_widget.setCurrentIndex(int(item['value']))
            elif itype == 'text':
                input_widget = QtWidgets.QLineEdit(item['value'])
                if item['secure'] == 'true':
                    input_widget.setEchoMode(QtWidgets.QLineEdit.PasswordEchoOnEdit)
            else:
                input_widget = QtWidgets.QLabel('...')
            self.form.addRow(QtWidgets.QLabel(item['label']), input_widget)
            self.ids.append((item['id'], input_widget))

        self.buttons = QtWidgets.QDialogButtonBox(
            QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, QtCore.Qt.Horizontal, self)
        self.form.addRow(self.buttons)
        self.buttons.rejected.connect(self.reject)
        self.buttons.accepted.connect(self.accept)
        if self.exec_() == QtWidgets.QDialog.Accepted:
            media_object.container.server.request(media_object.key + '/set', params=self.extract_values())
项目:plexdesktop    作者:coryo    | 项目源码 | 文件源码
def __init__(self, parent=None):
        super().__init__(parent)
        s = plexdesktop.settings.Settings()
        self.setWindowTitle('Preferences')
        self.form = QtWidgets.QFormLayout(self)

        i = QtWidgets.QComboBox()
        i.addItems(plexdesktop.style.Style.Instance().themes)
        i.setCurrentIndex(i.findText(s.value('theme')))
        self.form.addRow(QtWidgets.QLabel('theme'), i)

        bf = QtWidgets.QSpinBox()
        bf.setValue(int(s.value('browser_font', 9)))
        self.form.addRow(QtWidgets.QLabel('browser font size'), bf)

        icon_size = QtWidgets.QLineEdit(str(s.value('thumb_size', 240)))
        icon_size.setValidator(QtGui.QIntValidator(0, 300))
        self.form.addRow(QtWidgets.QLabel('thumbnail size'), icon_size)

        widget_player = QtWidgets.QCheckBox()
        widget_player.setCheckState(QtCore.Qt.Checked if bool(int(s.value('widget_player', 0))) else QtCore.Qt.Unchecked)
        self.form.addRow(QtWidgets.QLabel('use widget player'), widget_player)

        self.buttons = QtWidgets.QDialogButtonBox(
            QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel,
            QtCore.Qt.Horizontal, self)
        self.form.addRow(self.buttons)
        self.buttons.rejected.connect(self.reject)
        self.buttons.accepted.connect(self.accept)

        if self.exec_() == QtWidgets.QDialog.Accepted:
            # s = Settings()
            theme = i.currentText()
            s.setValue('theme', theme)
            plexdesktop.style.Style.Instance().theme(theme)

            s.setValue('browser_font', bf.value())

            s.setValue('thumb_size', int(icon_size.text()))

            s.setValue('widget_player', 1 if widget_player.checkState() == QtCore.Qt.Checked else 0)
项目:plexdesktop    作者:coryo    | 项目源码 | 文件源码
def setupUi(self, Login):
        Login.setObjectName("Login")
        Login.resize(234, 101)
        self.verticalLayout = QtWidgets.QVBoxLayout(Login)
        self.verticalLayout.setObjectName("verticalLayout")
        self.formLayout_2 = QtWidgets.QFormLayout()
        self.formLayout_2.setObjectName("formLayout_2")
        self.username = QtWidgets.QLineEdit(Login)
        self.username.setObjectName("username")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.username)
        self.password = QtWidgets.QLineEdit(Login)
        self.password.setEchoMode(QtWidgets.QLineEdit.Password)
        self.password.setObjectName("password")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.password)
        self.label = QtWidgets.QLabel(Login)
        self.label.setObjectName("label")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.label)
        self.label_2 = QtWidgets.QLabel(Login)
        self.label_2.setObjectName("label_2")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.label_2)
        self.buttonBox = QtWidgets.QDialogButtonBox(Login)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Cancel|QtWidgets.QDialogButtonBox.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.formLayout_2.setWidget(3, QtWidgets.QFormLayout.FieldRole, self.buttonBox)
        self.verticalLayout.addLayout(self.formLayout_2)

        self.retranslateUi(Login)
        self.buttonBox.accepted.connect(Login.accept)
        self.buttonBox.rejected.connect(Login.reject)
        QtCore.QMetaObject.connectSlotsByName(Login)
项目:pysport    作者:sportorg    | 项目源码 | 文件源码
def init_ui(self):
        self.setWindowTitle(_('Start list'))
        self.setWindowIcon(QIcon(config.ICON))
        self.setSizeGripEnabled(False)
        self.setModal(True)

        self.layout = QFormLayout(self)

        self.label_template = QLabel(_('Template'))
        self.item_template = AdvComboBox()
        self.item_template.addItems(get_templates(config.template_dir('start')))
        self.layout.addRow(self.label_template, self.item_template)

        self.item_custom_path = QPushButton(_('Choose template'))

        def select_custom_path():
            file_name = get_open_file_name(_('Open HTML template'), _("HTML file (*.html)"))
            self.item_template.setCurrentText(file_name)

        self.item_custom_path.clicked.connect(select_custom_path)
        self.layout.addRow(self.item_custom_path)

        def cancel_changes():
            self.close()

        def apply_changes():
            try:
                self.apply_changes_impl()
            except Exception as e:
                logging.exception(str(e))
            self.close()

        self.button_ok = QPushButton(_('OK'))
        self.button_ok.clicked.connect(apply_changes)
        self.button_cancel = QPushButton(_('Cancel'))
        self.button_cancel.clicked.connect(cancel_changes)
        self.layout.addRow(self.button_ok, self.button_cancel)

        self.show()
        self.button_ok.setFocus()
项目:pysport    作者:sportorg    | 项目源码 | 文件源码
def init_ui(self):
        self.setWindowTitle(_('Rank calculation'))
        self.setWindowIcon(QIcon(config.ICON))
        self.setSizeGripEnabled(False)
        self.setModal(True)

        self.layout = QFormLayout(self)

        for i in self.group.ranking.rank:
            cur_item = self.group.ranking.rank[i]
            try:
                self.layout.addRow(get_widget_from_ranking(cur_item))
            except:
                logging.exception()

        def cancel_changes():
            self.close()

        def apply_changes():
            try:
                self.apply_changes_impl()
            except Exception as e:
                logging.exception(str(e))
            self.close()

        self.button_ok = QPushButton(_('OK'))
        self.button_ok.clicked.connect(apply_changes)
        self.button_cancel = QPushButton(_('Cancel'))
        self.button_cancel.clicked.connect(cancel_changes)
        self.layout.addRow(self.button_ok, self.button_cancel)

        self.show()
项目:pysport    作者:sportorg    | 项目源码 | 文件源码
def init_ui(self):
        self.setWindowTitle(_('Settings'))
        self.setWindowIcon(QIcon(config.ICON))
        self.setSizeGripEnabled(False)
        self.setModal(True)
        # self.setMinimumWidth(540)
        # self.setMinimumHeight(250)
        self.layout = QFormLayout(self)

        self.auto_save = QCheckBox(_('Auto save'))
        self.auto_save.setChecked(Config().configuration.get('autosave'))
        self.layout.addRow(self.auto_save)

        self.auto_connect = QCheckBox(_('Auto connect to station'))
        self.auto_connect.setChecked(Config().configuration.get('autoconnect'))
        self.layout.addRow(self.auto_connect)

        self.open_recent_file = QCheckBox(_('Open recent file'))
        self.open_recent_file.setChecked(Config().configuration.get('open_recent_file'))
        self.layout.addRow(self.open_recent_file)

        def cancel_changes():
            self.close()

        def apply_changes():
            try:
                self.apply_changes_impl()
            except Exception as e:
                logging.exception(str(e))
            self.close()

        self.button_ok = QPushButton(_('OK'))
        self.button_ok.clicked.connect(apply_changes)
        self.button_cancel = QPushButton(_('Cancel'))
        self.button_cancel.clicked.connect(cancel_changes)
        self.layout.addRow(self.button_ok, self.button_cancel)

        self.show()
项目:pysport    作者:sportorg    | 项目源码 | 文件源码
def init_ui(self):
        self.setWindowTitle(_('Bib'))
        self.setWindowIcon(QIcon(config.ICON))
        self.setSizeGripEnabled(False)
        self.setModal(True)

        self.layout = QFormLayout(self)

        if self.text:
            self.label_text = QLabel(self.text)
            self.layout.addRow(self.label_text)

        self.label_bib = QLabel(_('Bib'))
        self.item_bib = QSpinBox()
        self.item_bib.setMaximum(memory.Limit.BIB)
        self.item_bib.setValue(self.bib)
        self.item_bib.valueChanged.connect(self.show_person_info)
        self.layout.addRow(self.label_bib, self.item_bib)

        self.label_person_info = QLabel('')
        self.layout.addRow(self.label_person_info)

        def cancel_changes():
            self.person = None
            self.close()

        def apply_changes():
            try:
                self.apply_changes_impl()
            except Exception as e:
                logging.exception(str(e))
            self.close()

        self.button_ok = QPushButton(_('OK'))
        self.button_ok.clicked.connect(apply_changes)
        self.button_cancel = QPushButton(_('Cancel'))
        self.button_cancel.clicked.connect(cancel_changes)
        self.layout.addRow(self.button_ok, self.button_cancel)

        self.show()
项目:pysport    作者:sportorg    | 项目源码 | 文件源码
def init_ui(self):
        self.setWindowTitle(_('Report creating'))
        self.setWindowIcon(QIcon(config.ICON))
        self.setSizeGripEnabled(False)
        self.setModal(True)

        self.layout = QFormLayout(self)

        self.label_template = QLabel(_('Template'))
        self.item_template = AdvComboBox()
        self.item_template.addItems(get_templates(config.template_dir('result')))
        self.layout.addRow(self.label_template, self.item_template)

        self.item_custom_path = QPushButton(_('Choose template'))

        def select_custom_path():
            file_name = get_open_file_name(_('Open HTML template'), _("HTML file (*.html)"))
            self.item_template.setCurrentText(file_name)

        self.item_custom_path.clicked.connect(select_custom_path)
        self.layout.addRow(self.item_custom_path)

        def cancel_changes():
            self.close()

        def apply_changes():
            try:
                self.apply_changes_impl()
            except Exception as e:
                logging.exception(str(e))
            self.close()

        self.button_ok = QPushButton(_('OK'))
        self.button_ok.clicked.connect(apply_changes)
        self.button_cancel = QPushButton(_('Cancel'))
        self.button_cancel.clicked.connect(cancel_changes)
        self.layout.addRow(self.button_ok, self.button_cancel)

        self.show()
        self.button_ok.setFocus()
项目:Mac-Python-3.X    作者:L1nwatch    | 项目源码 | 文件源码
def setupUi(self, embeddedDialog):
        embeddedDialog.setObjectName("embeddedDialog")
        embeddedDialog.resize(407, 134)
        self.formLayout = QtWidgets.QFormLayout(embeddedDialog)
        self.formLayout.setObjectName("formLayout")
        self.label = QtWidgets.QLabel(embeddedDialog)
        self.label.setObjectName("label")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.label)
        self.layoutDirection = QtWidgets.QComboBox(embeddedDialog)
        self.layoutDirection.setObjectName("layoutDirection")
        self.layoutDirection.addItem("")
        self.layoutDirection.addItem("")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.layoutDirection)
        self.label_2 = QtWidgets.QLabel(embeddedDialog)
        self.label_2.setObjectName("label_2")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.label_2)
        self.fontComboBox = QtWidgets.QFontComboBox(embeddedDialog)
        self.fontComboBox.setObjectName("fontComboBox")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.fontComboBox)
        self.label_3 = QtWidgets.QLabel(embeddedDialog)
        self.label_3.setObjectName("label_3")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.label_3)
        self.style = QtWidgets.QComboBox(embeddedDialog)
        self.style.setObjectName("style")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.style)
        self.label_4 = QtWidgets.QLabel(embeddedDialog)
        self.label_4.setObjectName("label_4")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.LabelRole, self.label_4)
        self.spacing = QtWidgets.QSlider(embeddedDialog)
        self.spacing.setOrientation(QtCore.Qt.Horizontal)
        self.spacing.setObjectName("spacing")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.FieldRole, self.spacing)
        self.label.setBuddy(self.layoutDirection)
        self.label_2.setBuddy(self.fontComboBox)
        self.label_3.setBuddy(self.style)
        self.label_4.setBuddy(self.spacing)

        self.retranslateUi(embeddedDialog)
        QtCore.QMetaObject.connectSlotsByName(embeddedDialog)
项目:examples    作者:pyqt    | 项目源码 | 文件源码
def setupUi(self, Window):
        Window.setObjectName("Window")
        Window.resize(640, 480)
        self.verticalLayout = QtWidgets.QVBoxLayout(Window)
        self.verticalLayout.setObjectName("verticalLayout")
        self.webView = QtWebKitWidgets.QWebView(Window)
        self.webView.setUrl(QtCore.QUrl("http://webkit.org/"))
        self.webView.setObjectName("webView")
        self.verticalLayout.addWidget(self.webView)
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.formLayout = QtWidgets.QFormLayout()
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.ExpandingFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.elementLabel = QtWidgets.QLabel(Window)
        self.elementLabel.setObjectName("elementLabel")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.elementLabel)
        self.elementLineEdit = QtWidgets.QLineEdit(Window)
        self.elementLineEdit.setObjectName("elementLineEdit")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.elementLineEdit)
        self.horizontalLayout.addLayout(self.formLayout)
        self.highlightButton = QtWidgets.QPushButton(Window)
        self.highlightButton.setObjectName("highlightButton")
        self.horizontalLayout.addWidget(self.highlightButton)
        self.verticalLayout.addLayout(self.horizontalLayout)
        self.elementLabel.setBuddy(self.elementLineEdit)

        self.retranslateUi(Window)
        QtCore.QMetaObject.connectSlotsByName(Window)
项目:examples    作者:pyqt    | 项目源码 | 文件源码
def setupUi(self, embeddedDialog):
        embeddedDialog.setObjectName("embeddedDialog")
        embeddedDialog.resize(407, 134)
        self.formLayout = QtWidgets.QFormLayout(embeddedDialog)
        self.formLayout.setObjectName("formLayout")
        self.label = QtWidgets.QLabel(embeddedDialog)
        self.label.setObjectName("label")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.label)
        self.layoutDirection = QtWidgets.QComboBox(embeddedDialog)
        self.layoutDirection.setObjectName("layoutDirection")
        self.layoutDirection.addItem("")
        self.layoutDirection.addItem("")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.layoutDirection)
        self.label_2 = QtWidgets.QLabel(embeddedDialog)
        self.label_2.setObjectName("label_2")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.label_2)
        self.fontComboBox = QtWidgets.QFontComboBox(embeddedDialog)
        self.fontComboBox.setObjectName("fontComboBox")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.fontComboBox)
        self.label_3 = QtWidgets.QLabel(embeddedDialog)
        self.label_3.setObjectName("label_3")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.label_3)
        self.style = QtWidgets.QComboBox(embeddedDialog)
        self.style.setObjectName("style")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.style)
        self.label_4 = QtWidgets.QLabel(embeddedDialog)
        self.label_4.setObjectName("label_4")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.LabelRole, self.label_4)
        self.spacing = QtWidgets.QSlider(embeddedDialog)
        self.spacing.setOrientation(QtCore.Qt.Horizontal)
        self.spacing.setObjectName("spacing")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.FieldRole, self.spacing)
        self.label.setBuddy(self.layoutDirection)
        self.label_2.setBuddy(self.fontComboBox)
        self.label_3.setBuddy(self.style)
        self.label_4.setBuddy(self.spacing)

        self.retranslateUi(embeddedDialog)
        QtCore.QMetaObject.connectSlotsByName(embeddedDialog)
项目:universal_tool_template.py    作者:shiningdesign    | 项目源码 | 文件源码
def quickLayout(self, type, ui_name=""):
        the_layout = ''
        if type in ("form", "QFormLayout"):
            the_layout = QtWidgets.QFormLayout()
            the_layout.setLabelAlignment(QtCore.Qt.AlignLeft)
            the_layout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)    
        elif type in ("grid", "QGridLayout"):
            the_layout = QtWidgets.QGridLayout()
        elif type in ("hbox", "QHBoxLayout"):
            the_layout = QtWidgets.QHBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        else:        
            the_layout = QtWidgets.QVBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        if ui_name != "":
            self.uiList[ui_name] = the_layout
        return the_layout
项目:universal_tool_template.py    作者:shiningdesign    | 项目源码 | 文件源码
def quickLayout(self, type, ui_name=""):
        the_layout = ''
        if type in ("form", "QFormLayout"):
            the_layout = QtWidgets.QFormLayout()
            the_layout.setLabelAlignment(QtCore.Qt.AlignLeft)
            the_layout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)    
        elif type in ("grid", "QGridLayout"):
            the_layout = QtWidgets.QGridLayout()
        elif type in ("hbox", "QHBoxLayout"):
            the_layout = QtWidgets.QHBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        else:        
            the_layout = QtWidgets.QVBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        if ui_name != "":
            self.uiList[ui_name] = the_layout
        return the_layout
项目:universal_tool_template.py    作者:shiningdesign    | 项目源码 | 文件源码
def quickLayout(self, type, ui_name=""):
        the_layout = ''
        if type in ("form", "QFormLayout"):
            the_layout = QtWidgets.QFormLayout()
            the_layout.setLabelAlignment(QtCore.Qt.AlignLeft)
            the_layout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)    
        elif type in ("grid", "QGridLayout"):
            the_layout = QtWidgets.QGridLayout()
        elif type in ("hbox", "QHBoxLayout"):
            the_layout = QtWidgets.QHBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        else:        
            the_layout = QtWidgets.QVBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        if ui_name != "":
            self.uiList[ui_name] = the_layout
        return the_layout
项目:universal_tool_template.py    作者:shiningdesign    | 项目源码 | 文件源码
def quickLayout(self, type, ui_name=""):
        the_layout = ''
        if type in ("form", "QFormLayout"):
            the_layout = QtWidgets.QFormLayout()
            the_layout.setLabelAlignment(QtCore.Qt.AlignLeft)
            the_layout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)    
        elif type in ("grid", "QGridLayout"):
            the_layout = QtWidgets.QGridLayout()
        elif type in ("hbox", "QHBoxLayout"):
            the_layout = QtWidgets.QHBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        else:        
            the_layout = QtWidgets.QVBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        if ui_name != "":
            self.uiList[ui_name] = the_layout
        return the_layout
项目:universal_tool_template.py    作者:shiningdesign    | 项目源码 | 文件源码
def quickLayout(self, type, ui_name=""):
        the_layout = ''
        if type in ("form", "QFormLayout"):
            the_layout = QtWidgets.QFormLayout()
            the_layout.setLabelAlignment(QtCore.Qt.AlignLeft)
            the_layout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)    
        elif type in ("grid", "QGridLayout"):
            the_layout = QtWidgets.QGridLayout()
        elif type in ("hbox", "QHBoxLayout"):
            the_layout = QtWidgets.QHBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        else:        
            the_layout = QtWidgets.QVBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        if ui_name != "":
            self.uiList[ui_name] = the_layout
        return the_layout
项目:universal_tool_template.py    作者:shiningdesign    | 项目源码 | 文件源码
def qui(self, ui_list_string, parentObject_string='', opt=''):
        # pre-defined user short name syntax
        type_dict = {
            'vbox': 'QVBoxLayout','hbox':'QHBoxLayout','grid':'QGridLayout', 'form':'QFormLayout',
            'split': 'QSplitter', 'grp':'QGroupBox', 'tab':'QTabWidget',
            'btn':'QPushButton', 'btnMsg':'QPushButton', 'label':'QLabel', 'input':'QLineEdit', 'check':'QCheckBox', 'choice':'QComboBox',
            'txtEdit': 'LNTextEdit', 'txt': 'QTextEdit',
            'tree': 'QTreeWidget', 'table': 'QTableWidget',
            'space': 'QSpacerItem', 
        }
        # get ui_list, creation or existing ui object
        ui_list = [x.strip() for x in ui_list_string.split('|')]
        for i in range(len(ui_list)):
            if ui_list[i] in self.uiList:
                # - exisiting object
                ui_list[i] = self.uiList[ui_list[i]]
            else:
                # - string creation: 
                # get part info
                partInfo = ui_list[i].split(';',1)
                uiName = partInfo[0].split('@')[0]
                uiType = uiName.rsplit('_',1)[-1]
                if uiType in type_dict:
                    uiType = type_dict[uiType]
                # set quickUI string format
                ui_list[i] = partInfo[0]+';'+uiType
                if len(partInfo)==1:
                    # give empty button and label a place holder name
                    if uiType in ('btn', 'btnMsg', 'QPushButton','label', 'QLabel'):
                        ui_list[i] = partInfo[0]+';'+uiType + ';'+uiName 
                elif len(partInfo)==2:
                    ui_list[i]=ui_list[i]+";"+partInfo[1]
        # get parentObject or exisiting object
        parentObject = parentObject_string
        if parentObject in self.uiList:
            parentObject = self.uiList[parentObject]
        # process quickUI
        self.quickUI(ui_list, parentObject, opt)
项目:universal_tool_template.py    作者:shiningdesign    | 项目源码 | 文件源码
def quickLayout(self, type, ui_name=""):
        the_layout = ''
        if type in ("form", "QFormLayout"):
            the_layout = QtWidgets.QFormLayout()
            the_layout.setLabelAlignment(QtCore.Qt.AlignLeft)
            the_layout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)    
        elif type in ("grid", "QGridLayout"):
            the_layout = QtWidgets.QGridLayout()
        elif type in ("hbox", "QHBoxLayout"):
            the_layout = QtWidgets.QHBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        else:        
            the_layout = QtWidgets.QVBoxLayout()
            the_layout.setAlignment(QtCore.Qt.AlignTop)
        if ui_name != "":
            self.uiList[ui_name] = the_layout
        return the_layout
项目:Laborejo    作者:hilbrichtsoftware    | 项目源码 | 文件源码
def __init__(self, mainWindow, labelString):
        super().__init__(mainWindow) #if you don't set the parent to the main window the whole screen will be the root and the dialog pops up in the middle of it.
        #self.setModal(True) #we don't need this when called with self.exec() instead of self.show()
        self.layout = QtWidgets.QFormLayout()
        #self.layout = QtWidgets.QVBoxLayout()
        self.setLayout(self.layout)

        label = QtWidgets.QLabel(labelString) #"Choose a clef" or so.
        self.layout.addWidget(label)

        #self.setFocus(); #self.grabKeyboard(); #redundant for a proper modal dialog. Leave here for documentation reasons.
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.formGroupBox = QtWidgets.QGroupBox(Form)
        self.formGroupBox.setObjectName("formGroupBox")
        self.formLayout = QtWidgets.QFormLayout(self.formGroupBox)
        self.formLayout.setObjectName("formLayout")
        self.chooseDataLabel = QtWidgets.QLabel(self.formGroupBox)
        self.chooseDataLabel.setObjectName("chooseDataLabel")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.chooseDataLabel)
        self.chooseDataComboBox = QtWidgets.QComboBox(self.formGroupBox)
        self.chooseDataComboBox.setObjectName("chooseDataComboBox")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.chooseDataComboBox)
        self.chooseMethodLabel = QtWidgets.QLabel(self.formGroupBox)
        self.chooseMethodLabel.setObjectName("chooseMethodLabel")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.chooseMethodLabel)
        self.chooseMethodComboBox = QtWidgets.QComboBox(self.formGroupBox)
        self.chooseMethodComboBox.setObjectName("chooseMethodComboBox")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.chooseMethodComboBox)
        self.dim_reduction_vlayout = QtWidgets.QVBoxLayout()
        self.dim_reduction_vlayout.setObjectName("dim_reduction_vlayout")
        self.formLayout.setLayout(2, QtWidgets.QFormLayout.SpanningRole, self.dim_reduction_vlayout)
        self.verticalLayout.addWidget(self.formGroupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupbox = QtWidgets.QGroupBox(Form)
        self.groupbox.setObjectName("groupbox")
        self.formLayout_2 = QtWidgets.QFormLayout(self.groupbox)
        self.formLayout_2.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout_2.setObjectName("formLayout_2")
        self.orderLabel = QtWidgets.QLabel(self.groupbox)
        self.orderLabel.setObjectName("orderLabel")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.orderLabel)
        self.orderSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.orderSpinBox.setObjectName("orderSpinBox")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.orderSpinBox)
        self.numOfStandardDeviationsLabel = QtWidgets.QLabel(self.groupbox)
        self.numOfStandardDeviationsLabel.setObjectName("numOfStandardDeviationsLabel")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.numOfStandardDeviationsLabel)
        self.numOfStandardDeviationsSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.numOfStandardDeviationsSpinBox.setObjectName("numOfStandardDeviationsSpinBox")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.numOfStandardDeviationsSpinBox)
        self.maxNumOfIterationsLabel = QtWidgets.QLabel(self.groupbox)
        self.maxNumOfIterationsLabel.setObjectName("maxNumOfIterationsLabel")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.maxNumOfIterationsLabel)
        self.maxNumOfIterationsSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.maxNumOfIterationsSpinBox.setObjectName("maxNumOfIterationsSpinBox")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.maxNumOfIterationsSpinBox)
        self.verticalLayout.addWidget(self.groupbox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupbox = QtWidgets.QGroupBox(Form)
        self.groupbox.setObjectName("groupbox")
        self.formLayout = QtWidgets.QFormLayout(self.groupbox)
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.asymmetryLabel = QtWidgets.QLabel(self.groupbox)
        self.asymmetryLabel.setObjectName("asymmetryLabel")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.asymmetryLabel)
        self.asymmetryDoubleSpinBox = QtWidgets.QDoubleSpinBox(self.groupbox)
        self.asymmetryDoubleSpinBox.setObjectName("asymmetryDoubleSpinBox")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.asymmetryDoubleSpinBox)
        self.smoothnessLabel = QtWidgets.QLabel(self.groupbox)
        self.smoothnessLabel.setObjectName("smoothnessLabel")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.smoothnessLabel)
        self.smoothnessDoubleSpinBox = QtWidgets.QDoubleSpinBox(self.groupbox)
        self.smoothnessDoubleSpinBox.setObjectName("smoothnessDoubleSpinBox")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.smoothnessDoubleSpinBox)
        self.maxNumOfIterationsLabel = QtWidgets.QLabel(self.groupbox)
        self.maxNumOfIterationsLabel.setObjectName("maxNumOfIterationsLabel")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.maxNumOfIterationsLabel)
        self.maxNumOfIterationsSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.maxNumOfIterationsSpinBox.setObjectName("maxNumOfIterationsSpinBox")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.maxNumOfIterationsSpinBox)
        self.convergenceThresholdLabel = QtWidgets.QLabel(self.groupbox)
        self.convergenceThresholdLabel.setObjectName("convergenceThresholdLabel")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.LabelRole, self.convergenceThresholdLabel)
        self.convergenceThresholdDoubleSpinBox = QtWidgets.QDoubleSpinBox(self.groupbox)
        self.convergenceThresholdDoubleSpinBox.setObjectName("convergenceThresholdDoubleSpinBox")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.FieldRole, self.convergenceThresholdDoubleSpinBox)
        self.verticalLayout.addWidget(self.groupbox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupbox = QtWidgets.QGroupBox(Form)
        self.groupbox.setObjectName("groupbox")
        self.formLayout_2 = QtWidgets.QFormLayout(self.groupbox)
        self.formLayout_2.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout_2.setObjectName("formLayout_2")
        self.smoothnessLabel = QtWidgets.QLabel(self.groupbox)
        self.smoothnessLabel.setObjectName("smoothnessLabel")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.smoothnessLabel)
        self.smoothnessSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.smoothnessSpinBox.setObjectName("smoothnessSpinBox")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.smoothnessSpinBox)
        self.maxNumOfIterationsLabel = QtWidgets.QLabel(self.groupbox)
        self.maxNumOfIterationsLabel.setObjectName("maxNumOfIterationsLabel")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.maxNumOfIterationsLabel)
        self.maxNumOfIterationsSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.maxNumOfIterationsSpinBox.setObjectName("maxNumOfIterationsSpinBox")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.maxNumOfIterationsSpinBox)
        self.convergenceThresholdLabel = QtWidgets.QLabel(self.groupbox)
        self.convergenceThresholdLabel.setObjectName("convergenceThresholdLabel")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.convergenceThresholdLabel)
        self.convergenceThresholdDoubleSpinBox = QtWidgets.QDoubleSpinBox(self.groupbox)
        self.convergenceThresholdDoubleSpinBox.setObjectName("convergenceThresholdDoubleSpinBox")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.convergenceThresholdDoubleSpinBox)
        self.verticalLayout.addWidget(self.groupbox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupBox = QtWidgets.QGroupBox(Form)
        self.groupBox.setObjectName("groupBox")
        self.formLayout = QtWidgets.QFormLayout(self.groupBox)
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.n_est_label = QtWidgets.QLabel(self.groupBox)
        self.n_est_label.setObjectName("n_est_label")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.n_est_label)
        self.n_est_spin = QtWidgets.QSpinBox(self.groupBox)
        self.n_est_spin.setObjectName("n_est_spin")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.n_est_spin)
        self.prop_outliers_label = QtWidgets.QLabel(self.groupBox)
        self.prop_outliers_label.setToolTip("")
        self.prop_outliers_label.setObjectName("prop_outliers_label")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.prop_outliers_label)
        self.prop_outliers_spin = QtWidgets.QDoubleSpinBox(self.groupBox)
        self.prop_outliers_spin.setDecimals(4)
        self.prop_outliers_spin.setMaximum(0.5)
        self.prop_outliers_spin.setObjectName("prop_outliers_spin")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.prop_outliers_spin)
        self.verticalLayout.addWidget(self.groupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupbox = QtWidgets.QGroupBox(Form)
        self.groupbox.setObjectName("groupbox")
        self.formLayout_2 = QtWidgets.QFormLayout(self.groupbox)
        self.formLayout_2.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout_2.setObjectName("formLayout_2")
        self.polynomialOrderLabel = QtWidgets.QLabel(self.groupbox)
        self.polynomialOrderLabel.setObjectName("polynomialOrderLabel")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.polynomialOrderLabel)
        self.polynomialOrderSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.polynomialOrderSpinBox.setObjectName("polynomialOrderSpinBox")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.polynomialOrderSpinBox)
        self.maximumNumOfIterationsLabel = QtWidgets.QLabel(self.groupbox)
        self.maximumNumOfIterationsLabel.setObjectName("maximumNumOfIterationsLabel")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.maximumNumOfIterationsLabel)
        self.maximumNumOfIterationsDoubleSpinBox = QtWidgets.QDoubleSpinBox(self.groupbox)
        self.maximumNumOfIterationsDoubleSpinBox.setObjectName("maximumNumOfIterationsDoubleSpinBox")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.maximumNumOfIterationsDoubleSpinBox)
        self.toleranceLabel = QtWidgets.QLabel(self.groupbox)
        self.toleranceLabel.setObjectName("toleranceLabel")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.toleranceLabel)
        self.toleranceDoubleSpinBox = QtWidgets.QDoubleSpinBox(self.groupbox)
        self.toleranceDoubleSpinBox.setObjectName("toleranceDoubleSpinBox")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.toleranceDoubleSpinBox)
        self.verticalLayout.addWidget(self.groupbox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.formGroupBox = QtWidgets.QGroupBox(Form)
        self.formGroupBox.setObjectName("formGroupBox")
        self.formLayout = QtWidgets.QFormLayout(self.formGroupBox)
        self.formLayout.setObjectName("formLayout")
        self.dataSet1Label = QtWidgets.QLabel(self.formGroupBox)
        self.dataSet1Label.setObjectName("dataSet1Label")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.dataSet1Label)
        self.dataSet1ComboBox = QtWidgets.QComboBox(self.formGroupBox)
        self.dataSet1ComboBox.setObjectName("dataSet1ComboBox")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.dataSet1ComboBox)
        self.dataSet2Label = QtWidgets.QLabel(self.formGroupBox)
        self.dataSet2Label.setObjectName("dataSet2Label")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.dataSet2Label)
        self.dataSet2ComboBox = QtWidgets.QComboBox(self.formGroupBox)
        self.dataSet2ComboBox.setObjectName("dataSet2ComboBox")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.dataSet2ComboBox)
        self.outputToDataSetLabel = QtWidgets.QLabel(self.formGroupBox)
        self.outputToDataSetLabel.setObjectName("outputToDataSetLabel")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.outputToDataSetLabel)
        self.outputToDataSetComboBox = QtWidgets.QComboBox(self.formGroupBox)
        self.outputToDataSetComboBox.setObjectName("outputToDataSetComboBox")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.outputToDataSetComboBox)
        self.verticalLayout.addWidget(self.formGroupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.formGroupBox = QtWidgets.QGroupBox(Form)
        self.formGroupBox.setObjectName("formGroupBox")
        self.formLayout = QtWidgets.QFormLayout(self.formGroupBox)
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.chooseModelLabel = QtWidgets.QLabel(self.formGroupBox)
        self.chooseModelLabel.setObjectName("chooseModelLabel")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.chooseModelLabel)
        self.chooseDataComboBox = QtWidgets.QComboBox(self.formGroupBox)
        self.chooseDataComboBox.setObjectName("chooseDataComboBox")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.chooseDataComboBox)
        self.chooseModelComboBox = QtWidgets.QComboBox(self.formGroupBox)
        self.chooseModelComboBox.setObjectName("chooseModelComboBox")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.chooseModelComboBox)
        self.chooseDataLabel = QtWidgets.QLabel(self.formGroupBox)
        self.chooseDataLabel.setObjectName("chooseDataLabel")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.chooseDataLabel)
        self.verticalLayout.addWidget(self.formGroupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupbox = QtWidgets.QGroupBox(Form)
        self.groupbox.setObjectName("groupbox")
        self.formLayout_2 = QtWidgets.QFormLayout(self.groupbox)
        self.formLayout_2.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout_2.setObjectName("formLayout_2")
        self.largestWaveletScaleLabel = QtWidgets.QLabel(self.groupbox)
        self.largestWaveletScaleLabel.setObjectName("largestWaveletScaleLabel")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.largestWaveletScaleLabel)
        self.largestWaveletScaleSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.largestWaveletScaleSpinBox.setObjectName("largestWaveletScaleSpinBox")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.largestWaveletScaleSpinBox)
        self.lowestWaveletScaleLabel = QtWidgets.QLabel(self.groupbox)
        self.lowestWaveletScaleLabel.setObjectName("lowestWaveletScaleLabel")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.lowestWaveletScaleLabel)
        self.lowestWaveletScaleSpinBox = QtWidgets.QSpinBox(self.groupbox)
        self.lowestWaveletScaleSpinBox.setObjectName("lowestWaveletScaleSpinBox")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.lowestWaveletScaleSpinBox)
        self.interpolationMethodLabel = QtWidgets.QLabel(self.groupbox)
        self.interpolationMethodLabel.setObjectName("interpolationMethodLabel")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.LabelRole, self.interpolationMethodLabel)
        self.interpolationMethodComboBox = QtWidgets.QComboBox(self.groupbox)
        self.interpolationMethodComboBox.setObjectName("interpolationMethodComboBox")
        self.interpolationMethodComboBox.addItem("")
        self.interpolationMethodComboBox.addItem("")
        self.interpolationMethodComboBox.addItem("")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.FieldRole, self.interpolationMethodComboBox)
        self.verticalLayout.addWidget(self.groupbox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
项目:PySAT_Point_Spectra_GUI    作者:USGS-Astrogeology    | 项目源码 | 文件源码
def setupUi(self, Form):
        Form.setObjectName("Form")
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Form.sizePolicy().hasHeightForWidth())
        Form.setSizePolicy(sizePolicy)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupBox = QtWidgets.QGroupBox(Form)
        self.groupBox.setObjectName("groupBox")
        self.formLayout = QtWidgets.QFormLayout(self.groupBox)
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.fitInterceptLabel = QtWidgets.QLabel(self.groupBox)
        self.fitInterceptLabel.setObjectName("fitInterceptLabel")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.fitInterceptLabel)
        self.fit_intercept_list = QtWidgets.QListWidget(self.groupBox)
        self.fit_intercept_list.setMaximumSize(QtCore.QSize(16777215, 50))
        self.fit_intercept_list.setSelectionMode(QtWidgets.QAbstractItemView.MultiSelection)
        self.fit_intercept_list.setObjectName("fit_intercept_list")
        item = QtWidgets.QListWidgetItem()
        self.fit_intercept_list.addItem(item)
        item = QtWidgets.QListWidgetItem()
        self.fit_intercept_list.addItem(item)
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.fit_intercept_list)
        self.verticalLayout.addWidget(self.groupBox)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)