示例#1
0
def selectPort():
    d = QtWidgets.QDialog()
    l = QtWidgets.QVBoxLayout(d)
    combo = QtWidgets.QComboBox(d)
    combo.addItems(serial_ports())
    ok = QtWidgets.QPushButton("Ok", d)
    ok.clicked.connect(d.close)
    l.addWidget(combo)
    l.addWidget(ok)
    d.exec_()
    return combo.currentText()
示例#2
0
 def __init__(self):
     super(SymbolBrowserPanel, self).__init__()
     self._prevLine = -1
     self._definitions = []
     layout = QtWidgets.QHBoxLayout()
     layout.setContentsMargins(0, 0, 0, 0)
     self.combo_box = QtWidgets.QComboBox()
     self.combo_box.setSizeAdjustPolicy(
         self.combo_box.AdjustToMinimumContentsLength)
     self.combo_box.activated.connect(self._on_definition_activated)
     layout.addWidget(self.combo_box)
     self.setLayout(layout)
     self.combo_box.addItem("Loading symbols...")
示例#3
0
文件: project.py 项目: merbst/QIdle
    def __init__(self, app):
        self.ui = win_prj_ui.Ui_MainWindow()
        super(ProjectWindow, self).__init__(self.ui, app)
        self.restore_state()
        self.ui.dockWidgetProgramOutput.hide()
        self.ui.tabWidget.dirty_changed.connect(self._on_dirty_changed)
        self.ui.tabWidget.register_code_edit(PyCodeEdit)
        self.ui.tabWidget.current_changed.connect(
            self._on_current_editor_changed)
        self.ui.tabWidget.last_tab_closed.connect(self._on_last_tab_closed)
        self.ui.fsTree.set_context_menu(PyFileSystemContextMenu(self))
        self.ui.fsTree.file_deleted.connect(self._on_file_deleted)
        self.ui.fsTree.file_renamed.connect(self._on_file_renamed)
        self.ui.fsTree.file_created.connect(self._on_file_created)
        self.ui.fsTree.ignore_directories('.qidle')

        # Edit menu
        self.addActions(self.ui.menuFile.actions())

        self.ui.actionConfigureRun.triggered.connect(self.configure_run)
        self.ui.actionRun.triggered.connect(self.on_action_run_triggered)
        self.ui.textEditPgmOutput.process_finished.connect(
            self._on_script_finished)
        self.ui.textEditPgmOutput.open_file_requested.connect(
            self._goto_requested)

        for a in self.createPopupMenu().actions():
            if a.text() == 'Structure':
                a.setIcon(icons.class_browser)
            if a.text() == 'Python console':
                a.setIcon(icons.python_interpreter)
            if a.text() == 'Program output':
                a.setIcon(
                    QtGui.QIcon.fromTheme(
                        'media-playback-start',
                        QtGui.QIcon(':/icons/media-playback-start.png')))
        self.ui.dockWidgetClassExplorer.setWindowIcon(icons.class_browser)
        self.ui.dockWidgetProgramOutput.setWindowIcon(icons.run)
        self.ui.dockWidgetFiles.setWindowIcon(icons.folder)
        self.ui.dockWidgetPyConsole.setWindowIcon(icons.python_interpreter)
        self.apply_preferences(show_panels=False)

        self.dock_manager_right.add_dock_widget(self.ui.dockWidgetFiles)
        self.dock_manager_right.add_dock_widget(
            self.ui.dockWidgetClassExplorer)
        self.dock_manager_bottom.add_dock_widget(
            self.ui.dockWidgetProgramOutput)
        self.dock_manager_bottom.add_dock_widget(self.ui.dockWidgetPyConsole)

        self.ui.classExplorer.set_editor(None)

        self.ui.fsTree.activated.connect(self._on_tv_activated)
        self.ui.fsTree.setHeaderHidden(True)
        for i in range(1, 4):
            self.ui.fsTree.hideColumn(i)

        self._on_current_editor_changed(None)

        self._lock_combo_run_configs_updates = False
        self._combo_run_configs = QtWidgets.QComboBox()
        self._combo_run_configs.setToolTip('Choose run configuration')
        self.ui.toolBarRun.insertWidget(self.ui.actionRun,
                                        self._combo_run_configs)
        self._combo_run_configs.activated.connect(
            self._on_run_config_activated)
示例#4
0
    def setupUi(self, Dialog):
        Dialog.setObjectName("Dialog")
        Dialog.resize(356, 180)
        icon = QtGui.QIcon()
        icon.addPixmap(QtGui.QPixmap(":/ide-icons/rc/silex-64x64.png"),
                       QtGui.QIcon.Normal, QtGui.QIcon.Off)
        Dialog.setWindowIcon(icon)
        self.verticalLayout = QtWidgets.QVBoxLayout(Dialog)
        self.verticalLayout.setObjectName("verticalLayout")
        self.formLayout = QtWidgets.QFormLayout()
        self.formLayout.setObjectName("formLayout")
        self.label = QtWidgets.QLabel(Dialog)
        self.label.setObjectName("label")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole,
                                  self.label)
        self.comboBoxType = QtWidgets.QComboBox(Dialog)
        self.comboBoxType.setObjectName("comboBoxType")
        self.comboBoxType.addItem("")
        self.comboBoxType.addItem("")
        self.comboBoxType.addItem("")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole,
                                  self.comboBoxType)
        self.labelDir = QtWidgets.QLabel(Dialog)
        self.labelDir.setObjectName("labelDir")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.LabelRole,
                                  self.labelDir)
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.lineEditPath = QtWidgets.QLineEdit(Dialog)
        self.lineEditPath.setObjectName("lineEditPath")
        self.horizontalLayout.addWidget(self.lineEditPath)
        self.toolButton = QtWidgets.QToolButton(Dialog)
        self.toolButton.setObjectName("toolButton")
        self.horizontalLayout.addWidget(self.toolButton)
        self.formLayout.setLayout(2, QtWidgets.QFormLayout.FieldRole,
                                  self.horizontalLayout)
        self.labelName = QtWidgets.QLabel(Dialog)
        self.labelName.setObjectName("labelName")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole,
                                  self.labelName)
        self.horizontalLayout_2 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_2.setObjectName("horizontalLayout_2")
        self.lineEditName = QtWidgets.QLineEdit(Dialog)
        self.lineEditName.setObjectName("lineEditName")
        self.horizontalLayout_2.addWidget(self.lineEditName)
        self.comboBoxExtension = QtWidgets.QComboBox(Dialog)
        self.comboBoxExtension.setObjectName("comboBoxExtension")
        self.horizontalLayout_2.addWidget(self.comboBoxExtension)
        self.formLayout.setLayout(1, QtWidgets.QFormLayout.FieldRole,
                                  self.horizontalLayout_2)
        self.verticalLayout.addLayout(self.formLayout)
        self.buttonBox = QtWidgets.QDialogButtonBox(Dialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Cancel
                                          | QtWidgets.QDialogButtonBox.Ok)
        self.buttonBox.setCenterButtons(False)
        self.buttonBox.setObjectName("buttonBox")
        self.verticalLayout.addWidget(self.buttonBox)

        self.retranslateUi(Dialog)
        self.buttonBox.accepted.connect(Dialog.accept)
        self.buttonBox.rejected.connect(Dialog.reject)
        QtCore.QMetaObject.connectSlotsByName(Dialog)
        Dialog.setTabOrder(self.buttonBox, self.comboBoxType)
        Dialog.setTabOrder(self.comboBoxType, self.lineEditName)
        Dialog.setTabOrder(self.lineEditName, self.comboBoxExtension)
        Dialog.setTabOrder(self.comboBoxExtension, self.lineEditPath)
        Dialog.setTabOrder(self.lineEditPath, self.toolButton)
    def setupUi(self, Form):
        Form.setObjectName("Form")
        Form.resize(594, 487)
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setObjectName("verticalLayout")
        self.header = QtWidgets.QLabel(Form)
        self.header.setStyleSheet("border-radius: 3px;\n"
                                  "background-color: rgb(161, 161, 161);\n"
                                  "padding: 10px;")
        self.header.setAlignment(QtCore.Qt.AlignCenter)
        self.header.setObjectName("header")
        self.verticalLayout.addWidget(self.header)
        self.groupBox = QtWidgets.QGroupBox(Form)
        self.groupBox.setObjectName("groupBox")
        self.gridLayout = QtWidgets.QGridLayout(self.groupBox)
        self.gridLayout.setObjectName("gridLayout")
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.combo_interpreters = QtWidgets.QComboBox(self.groupBox)
        self.combo_interpreters.setObjectName("combo_interpreters")
        self.horizontalLayout.addWidget(self.combo_interpreters)
        self.bt_cfg = QtWidgets.QToolButton(self.groupBox)
        icon = QtGui.QIcon.fromTheme("system-run")
        self.bt_cfg.setIcon(icon)
        self.bt_cfg.setPopupMode(QtWidgets.QToolButton.InstantPopup)
        self.bt_cfg.setArrowType(QtCore.Qt.NoArrow)
        self.bt_cfg.setObjectName("bt_cfg")
        self.horizontalLayout.addWidget(self.bt_cfg)
        self.gridLayout.addLayout(self.horizontalLayout, 0, 0, 1, 1)
        self.verticalLayout.addWidget(self.groupBox)
        self.groupBox_2 = QtWidgets.QGroupBox(Form)
        self.groupBox_2.setObjectName("groupBox_2")
        self.verticalLayout_3 = QtWidgets.QVBoxLayout(self.groupBox_2)
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.horizontalLayout_2 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_2.setObjectName("horizontalLayout_2")
        self.table_packages = QtWidgets.QTableWidget(self.groupBox_2)
        self.table_packages.setEditTriggers(
            QtWidgets.QAbstractItemView.NoEditTriggers)
        self.table_packages.setAlternatingRowColors(True)
        self.table_packages.setSelectionMode(
            QtWidgets.QAbstractItemView.SingleSelection)
        self.table_packages.setSelectionBehavior(
            QtWidgets.QAbstractItemView.SelectRows)
        self.table_packages.setObjectName("table_packages")
        self.table_packages.setColumnCount(3)
        self.table_packages.setRowCount(0)
        item = QtWidgets.QTableWidgetItem()
        self.table_packages.setHorizontalHeaderItem(0, item)
        item = QtWidgets.QTableWidgetItem()
        self.table_packages.setHorizontalHeaderItem(1, item)
        item = QtWidgets.QTableWidgetItem()
        self.table_packages.setHorizontalHeaderItem(2, item)
        self.table_packages.horizontalHeader().setCascadingSectionResizes(
            False)
        self.table_packages.horizontalHeader().setStretchLastSection(True)
        self.table_packages.verticalHeader().setVisible(False)
        self.table_packages.verticalHeader().setCascadingSectionResizes(False)
        self.horizontalLayout_2.addWidget(self.table_packages)
        self.verticalLayout_2 = QtWidgets.QVBoxLayout()
        self.verticalLayout_2.setContentsMargins(0, -1, -1, -1)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.bt_install_package = QtWidgets.QToolButton(self.groupBox_2)
        self.bt_install_package.setText("")
        icon = QtGui.QIcon.fromTheme("list-add")
        self.bt_install_package.setIcon(icon)
        self.bt_install_package.setObjectName("bt_install_package")
        self.verticalLayout_2.addWidget(self.bt_install_package)
        self.bt_uninstall_package = QtWidgets.QToolButton(self.groupBox_2)
        self.bt_uninstall_package.setText("")
        icon = QtGui.QIcon.fromTheme("list-remove")
        self.bt_uninstall_package.setIcon(icon)
        self.bt_uninstall_package.setObjectName("bt_uninstall_package")
        self.verticalLayout_2.addWidget(self.bt_uninstall_package)
        self.bt_upgrade_package = QtWidgets.QToolButton(self.groupBox_2)
        self.bt_upgrade_package.setText("")
        icon = QtGui.QIcon.fromTheme("up")
        self.bt_upgrade_package.setIcon(icon)
        self.bt_upgrade_package.setObjectName("bt_upgrade_package")
        self.verticalLayout_2.addWidget(self.bt_upgrade_package)
        spacerItem = QtWidgets.QSpacerItem(20, 40,
                                           QtWidgets.QSizePolicy.Minimum,
                                           QtWidgets.QSizePolicy.Expanding)
        self.verticalLayout_2.addItem(spacerItem)
        self.horizontalLayout_2.addLayout(self.verticalLayout_2)
        self.verticalLayout_3.addLayout(self.horizontalLayout_2)
        self.widgetInfos = QtWidgets.QWidget(self.groupBox_2)
        self.widgetInfos.setObjectName("widgetInfos")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.widgetInfos)
        self.gridLayout_2.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_2.setSpacing(0)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.layout_infos = QtWidgets.QHBoxLayout()
        self.layout_infos.setContentsMargins(-1, 0, -1, -1)
        self.layout_infos.setObjectName("layout_infos")
        self.lblMovie = QtWidgets.QLabel(self.widgetInfos)
        self.lblMovie.setAlignment(QtCore.Qt.AlignCenter)
        self.lblMovie.setObjectName("lblMovie")
        self.layout_infos.addWidget(self.lblMovie)
        self.lblInfos = QtWidgets.QLabel(self.widgetInfos)
        self.lblInfos.setObjectName("lblInfos")
        self.layout_infos.addWidget(self.lblInfos)
        spacerItem1 = QtWidgets.QSpacerItem(40, 20,
                                            QtWidgets.QSizePolicy.Expanding,
                                            QtWidgets.QSizePolicy.Minimum)
        self.layout_infos.addItem(spacerItem1)
        self.gridLayout_2.addLayout(self.layout_infos, 0, 0, 1, 1)
        self.verticalLayout_3.addWidget(self.widgetInfos)
        self.verticalLayout.addWidget(self.groupBox_2)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
示例#6
0
    def setupUi(self, Dialog):
        Dialog.setObjectName("Dialog")
        Dialog.resize(404, 185)
        icon = QtGui.QIcon()
        icon.addPixmap(QtGui.QPixmap(":/icons/interpreter-venv.png"),
                       QtGui.QIcon.Normal, QtGui.QIcon.Off)
        Dialog.setWindowIcon(icon)
        self.gridLayout = QtWidgets.QGridLayout(Dialog)
        self.gridLayout.setObjectName("gridLayout")
        self.formLayout_2 = QtWidgets.QFormLayout()
        self.formLayout_2.setFieldGrowthPolicy(
            QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout_2.setObjectName("formLayout_2")
        self.label = QtWidgets.QLabel(Dialog)
        self.label.setObjectName("label")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.LabelRole,
                                    self.label)
        self.lineedit_name = QtWidgets.QLineEdit(Dialog)
        self.lineedit_name.setObjectName("lineedit_name")
        self.formLayout_2.setWidget(0, QtWidgets.QFormLayout.FieldRole,
                                    self.lineedit_name)
        self.label_2 = QtWidgets.QLabel(Dialog)
        self.label_2.setObjectName("label_2")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.LabelRole,
                                    self.label_2)
        self.dir_picker = FilePicker(Dialog)
        self.dir_picker.setObjectName("dir_picker")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.FieldRole,
                                    self.dir_picker)
        self.label_3 = QtWidgets.QLabel(Dialog)
        self.label_3.setObjectName("label_3")
        self.formLayout_2.setWidget(3, QtWidgets.QFormLayout.LabelRole,
                                    self.label_3)
        self.combo_interpreters = QtWidgets.QComboBox(Dialog)
        self.combo_interpreters.setObjectName("combo_interpreters")
        self.formLayout_2.setWidget(3, QtWidgets.QFormLayout.FieldRole,
                                    self.combo_interpreters)
        self.label_4 = QtWidgets.QLabel(Dialog)
        font = QtGui.QFont()
        font.setItalic(True)
        self.label_4.setFont(font)
        self.label_4.setObjectName("label_4")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.LabelRole,
                                    self.label_4)
        self.label_full_path = QtWidgets.QLabel(Dialog)
        font = QtGui.QFont()
        font.setItalic(True)
        self.label_full_path.setFont(font)
        self.label_full_path.setObjectName("label_full_path")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.FieldRole,
                                    self.label_full_path)
        self.gridLayout.addLayout(self.formLayout_2, 0, 0, 1, 1)
        self.buttonBox = QtWidgets.QDialogButtonBox(Dialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Cancel
                                          | QtWidgets.QDialogButtonBox.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.gridLayout.addWidget(self.buttonBox, 3, 0, 1, 1)
        self.check_box_site_packages = QtWidgets.QCheckBox(Dialog)
        self.check_box_site_packages.setObjectName("check_box_site_packages")
        self.gridLayout.addWidget(self.check_box_site_packages, 1, 0, 1, 1)
        spacerItem = QtWidgets.QSpacerItem(20, 40,
                                           QtWidgets.QSizePolicy.Minimum,
                                           QtWidgets.QSizePolicy.Expanding)
        self.gridLayout.addItem(spacerItem, 2, 0, 1, 1)

        self.retranslateUi(Dialog)
        self.buttonBox.accepted.connect(Dialog.accept)
        self.buttonBox.rejected.connect(Dialog.reject)
        QtCore.QMetaObject.connectSlotsByName(Dialog)
示例#7
0
    def setupUi(self, Dialog):
        Dialog.setObjectName("Dialog")
        Dialog.resize(854, 525)
        self.verticalLayout_2 = QtWidgets.QVBoxLayout(Dialog)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.horizontalLayout_4 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_4.setContentsMargins(-1, 0, -1, -1)
        self.horizontalLayout_4.setObjectName("horizontalLayout_4")
        self.label_7 = QtWidgets.QLabel(Dialog)
        self.label_7.setObjectName("label_7")
        self.horizontalLayout_4.addWidget(self.label_7)
        self.comboInterpreters = QtWidgets.QComboBox(Dialog)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding,
                                           QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.comboInterpreters.sizePolicy().hasHeightForWidth())
        self.comboInterpreters.setSizePolicy(sizePolicy)
        self.comboInterpreters.setObjectName("comboInterpreters")
        self.horizontalLayout_4.addWidget(self.comboInterpreters)
        self.verticalLayout_2.addLayout(self.horizontalLayout_4)
        self.horizontalLayout_2 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_2.setObjectName("horizontalLayout_2")
        self.groupBox_2 = QtWidgets.QGroupBox(Dialog)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum,
                                           QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.groupBox_2.sizePolicy().hasHeightForWidth())
        self.groupBox_2.setSizePolicy(sizePolicy)
        self.groupBox_2.setFlat(False)
        self.groupBox_2.setCheckable(False)
        self.groupBox_2.setObjectName("groupBox_2")
        self.verticalLayout_3 = QtWidgets.QVBoxLayout(self.groupBox_2)
        self.verticalLayout_3.setSizeConstraint(
            QtWidgets.QLayout.SetDefaultConstraint)
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.listConfigs = QtWidgets.QListWidget(self.groupBox_2)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum,
                                           QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.listConfigs.sizePolicy().hasHeightForWidth())
        self.listConfigs.setSizePolicy(sizePolicy)
        self.listConfigs.setObjectName("listConfigs")
        self.verticalLayout_3.addWidget(self.listConfigs)
        self.horizontalLayout_3 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_3.setSizeConstraint(
            QtWidgets.QLayout.SetMinimumSize)
        self.horizontalLayout_3.setObjectName("horizontalLayout_3")
        self.pushButtonAddConfig = QtWidgets.QPushButton(self.groupBox_2)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed,
                                           QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.pushButtonAddConfig.sizePolicy().hasHeightForWidth())
        self.pushButtonAddConfig.setSizePolicy(sizePolicy)
        self.pushButtonAddConfig.setText("")
        icon = QtGui.QIcon.fromTheme("list-add")
        self.pushButtonAddConfig.setIcon(icon)
        self.pushButtonAddConfig.setObjectName("pushButtonAddConfig")
        self.horizontalLayout_3.addWidget(self.pushButtonAddConfig)
        self.pushButtonRmConfig = QtWidgets.QPushButton(self.groupBox_2)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed,
                                           QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.pushButtonRmConfig.sizePolicy().hasHeightForWidth())
        self.pushButtonRmConfig.setSizePolicy(sizePolicy)
        self.pushButtonRmConfig.setText("")
        icon = QtGui.QIcon.fromTheme("list-remove")
        self.pushButtonRmConfig.setIcon(icon)
        self.pushButtonRmConfig.setObjectName("pushButtonRmConfig")
        self.horizontalLayout_3.addWidget(self.pushButtonRmConfig)
        self.verticalLayout_3.addLayout(self.horizontalLayout_3)
        self.verticalLayout_3.setStretch(0, 1)
        self.horizontalLayout_2.addWidget(self.groupBox_2)
        self.groupBox = QtWidgets.QGroupBox(Dialog)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding,
                                           QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.groupBox.sizePolicy().hasHeightForWidth())
        self.groupBox.setSizePolicy(sizePolicy)
        self.groupBox.setObjectName("groupBox")
        self.gridLayout = QtWidgets.QGridLayout(self.groupBox)
        self.gridLayout.setObjectName("gridLayout")
        self.cfgWidget = RunConfigWidget(self.groupBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding,
                                           QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.cfgWidget.sizePolicy().hasHeightForWidth())
        self.cfgWidget.setSizePolicy(sizePolicy)
        self.cfgWidget.setObjectName("cfgWidget")
        self.gridLayout.addWidget(self.cfgWidget, 0, 0, 1, 1)
        self.horizontalLayout_2.addWidget(self.groupBox)
        self.verticalLayout_2.addLayout(self.horizontalLayout_2)
        self.buttonBox = QtWidgets.QDialogButtonBox(Dialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Cancel
                                          | QtWidgets.QDialogButtonBox.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.verticalLayout_2.addWidget(self.buttonBox)

        self.retranslateUi(Dialog)
        self.buttonBox.accepted.connect(Dialog.accept)
        self.buttonBox.rejected.connect(Dialog.reject)
        QtCore.QMetaObject.connectSlotsByName(Dialog)
        Dialog.setTabOrder(self.comboInterpreters, self.listConfigs)
        Dialog.setTabOrder(self.listConfigs, self.pushButtonAddConfig)
        Dialog.setTabOrder(self.pushButtonAddConfig, self.buttonBox)
示例#8
0
    def setupUi(self, Dialog):
        Dialog.setObjectName("Dialog")
        Dialog.resize(644, 619)
        icon = QtGui.QIcon.fromTheme("preferences-system")
        Dialog.setWindowIcon(icon)
        self.gridLayout_2 = QtWidgets.QGridLayout(Dialog)
        self.gridLayout_2.setContentsMargins(6, 6, 6, 6)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.widget = QtWidgets.QWidget(Dialog)
        self.widget.setStyleSheet("")
        self.widget.setObjectName("widget")
        self.widget_2 = QtWidgets.QGridLayout(self.widget)
        self.widget_2.setContentsMargins(0, 0, 0, 0)
        self.widget_2.setSpacing(0)
        self.widget_2.setObjectName("widget_2")
        self.tabWidget = QtWidgets.QTabWidget(self.widget)
        self.tabWidget.setStyleSheet("")
        self.tabWidget.setTabPosition(QtWidgets.QTabWidget.North)
        self.tabWidget.setTabShape(QtWidgets.QTabWidget.Rounded)
        self.tabWidget.setUsesScrollButtons(True)
        self.tabWidget.setDocumentMode(False)
        self.tabWidget.setObjectName("tabWidget")
        self.tabEditor = QtWidgets.QWidget()
        self.tabEditor.setObjectName("tabEditor")
        self.verticalLayout = QtWidgets.QVBoxLayout(self.tabEditor)
        self.verticalLayout.setObjectName("verticalLayout")
        self.groupBox_3 = QtWidgets.QGroupBox(self.tabEditor)
        self.groupBox_3.setObjectName("groupBox_3")
        self.formLayout = QtWidgets.QFormLayout(self.groupBox_3)
        self.formLayout.setObjectName("formLayout")
        self.label_10 = QtWidgets.QLabel(self.groupBox_3)
        self.label_10.setObjectName("label_10")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole,
                                  self.label_10)
        self.checkBoxViewLineNumber = QtWidgets.QCheckBox(self.groupBox_3)
        self.checkBoxViewLineNumber.setText("")
        self.checkBoxViewLineNumber.setChecked(True)
        self.checkBoxViewLineNumber.setObjectName("checkBoxViewLineNumber")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole,
                                  self.checkBoxViewLineNumber)
        self.label_11 = QtWidgets.QLabel(self.groupBox_3)
        self.label_11.setObjectName("label_11")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole,
                                  self.label_11)
        self.checkBoxHighlightCurrentLine = QtWidgets.QCheckBox(
            self.groupBox_3)
        self.checkBoxHighlightCurrentLine.setText("")
        self.checkBoxHighlightCurrentLine.setChecked(True)
        self.checkBoxHighlightCurrentLine.setObjectName(
            "checkBoxHighlightCurrentLine")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole,
                                  self.checkBoxHighlightCurrentLine)
        self.label_12 = QtWidgets.QLabel(self.groupBox_3)
        self.label_12.setObjectName("label_12")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.LabelRole,
                                  self.label_12)
        self.checkBoxHighlightWhitespaces = QtWidgets.QCheckBox(
            self.groupBox_3)
        self.checkBoxHighlightWhitespaces.setText("")
        self.checkBoxHighlightWhitespaces.setChecked(True)
        self.checkBoxHighlightWhitespaces.setObjectName(
            "checkBoxHighlightWhitespaces")
        self.formLayout.setWidget(2, QtWidgets.QFormLayout.FieldRole,
                                  self.checkBoxHighlightWhitespaces)
        self.label_13 = QtWidgets.QLabel(self.groupBox_3)
        self.label_13.setObjectName("label_13")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.LabelRole,
                                  self.label_13)
        self.checkBoxShowErrors = QtWidgets.QCheckBox(self.groupBox_3)
        self.checkBoxShowErrors.setText("")
        self.checkBoxShowErrors.setObjectName("checkBoxShowErrors")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.FieldRole,
                                  self.checkBoxShowErrors)
        self.verticalLayout.addWidget(self.groupBox_3)
        self.groupBox_2 = QtWidgets.QGroupBox(self.tabEditor)
        self.groupBox_2.setObjectName("groupBox_2")
        self.formLayout_2 = QtWidgets.QFormLayout(self.groupBox_2)
        self.formLayout_2.setObjectName("formLayout_2")
        self.label = QtWidgets.QLabel(self.groupBox_2)
        self.label.setObjectName("label")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.LabelRole,
                                    self.label)
        self.label_14 = QtWidgets.QLabel(self.groupBox_2)
        self.label_14.setText("")
        self.label_14.setObjectName("label_14")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.LabelRole,
                                    self.label_14)
        self.spinBoxEditorTabLen = QtWidgets.QSpinBox(self.groupBox_2)
        self.spinBoxEditorTabLen.setMaximum(99)
        self.spinBoxEditorTabLen.setProperty("value", 4)
        self.spinBoxEditorTabLen.setObjectName("spinBoxEditorTabLen")
        self.formLayout_2.setWidget(1, QtWidgets.QFormLayout.FieldRole,
                                    self.spinBoxEditorTabLen)
        self.checkBoxEditorAutoIndent = QtWidgets.QCheckBox(self.groupBox_2)
        self.checkBoxEditorAutoIndent.setChecked(True)
        self.checkBoxEditorAutoIndent.setObjectName("checkBoxEditorAutoIndent")
        self.formLayout_2.setWidget(2, QtWidgets.QFormLayout.FieldRole,
                                    self.checkBoxEditorAutoIndent)
        self.label_6 = QtWidgets.QLabel(self.groupBox_2)
        self.label_6.setText("")
        self.label_6.setObjectName("label_6")
        self.formLayout_2.setWidget(3, QtWidgets.QFormLayout.LabelRole,
                                    self.label_6)
        self.checkBoxSmartBackspace = QtWidgets.QCheckBox(self.groupBox_2)
        self.checkBoxSmartBackspace.setObjectName("checkBoxSmartBackspace")
        self.formLayout_2.setWidget(3, QtWidgets.QFormLayout.FieldRole,
                                    self.checkBoxSmartBackspace)
        self.verticalLayout.addWidget(self.groupBox_2)
        self.groupBox_4 = QtWidgets.QGroupBox(self.tabEditor)
        self.groupBox_4.setObjectName("groupBox_4")
        self.formLayout_4 = QtWidgets.QFormLayout(self.groupBox_4)
        self.formLayout_4.setObjectName("formLayout_4")
        self.label_2 = QtWidgets.QLabel(self.groupBox_4)
        self.label_2.setObjectName("label_2")
        self.formLayout_4.setWidget(1, QtWidgets.QFormLayout.LabelRole,
                                    self.label_2)
        self.spinBoxEditorCCTriggerLen = QtWidgets.QSpinBox(self.groupBox_4)
        self.spinBoxEditorCCTriggerLen.setProperty("value", 1)
        self.spinBoxEditorCCTriggerLen.setObjectName(
            "spinBoxEditorCCTriggerLen")
        self.formLayout_4.setWidget(1, QtWidgets.QFormLayout.FieldRole,
                                    self.spinBoxEditorCCTriggerLen)
        self.verticalLayout.addWidget(self.groupBox_4)
        self.groupBox = QtWidgets.QGroupBox(self.tabEditor)
        self.groupBox.setObjectName("groupBox")
        self.formLayout_7 = QtWidgets.QFormLayout(self.groupBox)
        self.formLayout_7.setObjectName("formLayout_7")
        self.label_7 = QtWidgets.QLabel(self.groupBox)
        self.label_7.setObjectName("label_7")
        self.formLayout_7.setWidget(0, QtWidgets.QFormLayout.LabelRole,
                                    self.label_7)
        self.lineEditCommentIndicator = QtWidgets.QLineEdit(self.groupBox)
        font = QtGui.QFont()
        font.setFamily("Monospace")
        self.lineEditCommentIndicator.setFont(font)
        self.lineEditCommentIndicator.setObjectName("lineEditCommentIndicator")
        self.formLayout_7.setWidget(0, QtWidgets.QFormLayout.FieldRole,
                                    self.lineEditCommentIndicator)
        self.verticalLayout.addWidget(self.groupBox)
        spacerItem = QtWidgets.QSpacerItem(20, 40,
                                           QtWidgets.QSizePolicy.Minimum,
                                           QtWidgets.QSizePolicy.Expanding)
        self.verticalLayout.addItem(spacerItem)
        icon = QtGui.QIcon()
        icon.addPixmap(QtGui.QPixmap(":/ide-icons/rc/cobol-mimetype.png"),
                       QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.tabWidget.addTab(self.tabEditor, icon, "")
        self.tabStyle = QtWidgets.QWidget()
        self.tabStyle.setObjectName("tabStyle")
        self.verticalLayout_3 = QtWidgets.QVBoxLayout(self.tabStyle)
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.groupBox_5 = QtWidgets.QGroupBox(self.tabStyle)
        self.groupBox_5.setObjectName("groupBox_5")
        self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.groupBox_5)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.horizontalLayout_3 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_3.setObjectName("horizontalLayout_3")
        spacerItem1 = QtWidgets.QSpacerItem(40, 20,
                                            QtWidgets.QSizePolicy.Expanding,
                                            QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_3.addItem(spacerItem1)
        self.radioButtonColorWhite = QtWidgets.QRadioButton(self.groupBox_5)
        self.radioButtonColorWhite.setChecked(True)
        self.radioButtonColorWhite.setObjectName("radioButtonColorWhite")
        self.horizontalLayout_3.addWidget(self.radioButtonColorWhite)
        self.radioButtonColorDark = QtWidgets.QRadioButton(self.groupBox_5)
        self.radioButtonColorDark.setObjectName("radioButtonColorDark")
        self.horizontalLayout_3.addWidget(self.radioButtonColorDark)
        spacerItem2 = QtWidgets.QSpacerItem(40, 20,
                                            QtWidgets.QSizePolicy.Expanding,
                                            QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_3.addItem(spacerItem2)
        self.verticalLayout_2.addLayout(self.horizontalLayout_3)
        self.layoutIconTheme = QtWidgets.QFormLayout()
        self.layoutIconTheme.setContentsMargins(-1, 0, -1, -1)
        self.layoutIconTheme.setObjectName("layoutIconTheme")
        self.lblIconTheme = QtWidgets.QLabel(self.groupBox_5)
        self.lblIconTheme.setObjectName("lblIconTheme")
        self.layoutIconTheme.setWidget(0, QtWidgets.QFormLayout.LabelRole,
                                       self.lblIconTheme)
        self.comboBoxIconTheme = QtWidgets.QComboBox(self.groupBox_5)
        self.comboBoxIconTheme.setObjectName("comboBoxIconTheme")
        self.layoutIconTheme.setWidget(0, QtWidgets.QFormLayout.FieldRole,
                                       self.comboBoxIconTheme)
        self.verticalLayout_2.addLayout(self.layoutIconTheme)
        self.verticalLayout_3.addWidget(self.groupBox_5)
        self.groupBox_6 = QtWidgets.QGroupBox(self.tabStyle)
        self.groupBox_6.setObjectName("groupBox_6")
        self.formLayout_3 = QtWidgets.QFormLayout(self.groupBox_6)
        self.formLayout_3.setObjectName("formLayout_3")
        self.label_3 = QtWidgets.QLabel(self.groupBox_6)
        self.label_3.setObjectName("label_3")
        self.formLayout_3.setWidget(0, QtWidgets.QFormLayout.LabelRole,
                                    self.label_3)
        self.horizontalLayout_4 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_4.setObjectName("horizontalLayout_4")
        self.fontComboBox = QtWidgets.QFontComboBox(self.groupBox_6)
        self.fontComboBox.setFontFilters(
            QtWidgets.QFontComboBox.MonospacedFonts)
        font = QtGui.QFont()
        font.setFamily("DejaVu Sans Mono")
        font.setPointSize(10)
        self.fontComboBox.setCurrentFont(font)
        self.fontComboBox.setObjectName("fontComboBox")
        self.horizontalLayout_4.addWidget(self.fontComboBox)
        self.formLayout_3.setLayout(0, QtWidgets.QFormLayout.FieldRole,
                                    self.horizontalLayout_4)
        self.label_4 = QtWidgets.QLabel(self.groupBox_6)
        self.label_4.setObjectName("label_4")
        self.formLayout_3.setWidget(1, QtWidgets.QFormLayout.LabelRole,
                                    self.label_4)
        self.horizontalLayout_5 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_5.setObjectName("horizontalLayout_5")
        self.spinBoxFontSize = QtWidgets.QSpinBox(self.groupBox_6)
        self.spinBoxFontSize.setProperty("value", 10)
        self.spinBoxFontSize.setObjectName("spinBoxFontSize")
        self.horizontalLayout_5.addWidget(self.spinBoxFontSize)
        self.formLayout_3.setLayout(1, QtWidgets.QFormLayout.FieldRole,
                                    self.horizontalLayout_5)
        self.verticalLayout_3.addWidget(self.groupBox_6)
        self.groupBox_7 = QtWidgets.QGroupBox(self.tabStyle)
        self.groupBox_7.setObjectName("groupBox_7")
        self.gridLayout_4 = QtWidgets.QGridLayout(self.groupBox_7)
        self.gridLayout_4.setObjectName("gridLayout_4")
        self.listWidgetColorSchemes = QtWidgets.QListWidget(self.groupBox_7)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum,
                                           QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.listWidgetColorSchemes.sizePolicy().hasHeightForWidth())
        self.listWidgetColorSchemes.setSizePolicy(sizePolicy)
        self.listWidgetColorSchemes.setObjectName("listWidgetColorSchemes")
        self.gridLayout_4.addWidget(self.listWidgetColorSchemes, 0, 0, 1, 1)
        self.plainTextEdit = CobolCodeEdit(self.groupBox_7)
        self.plainTextEdit.setObjectName("plainTextEdit")
        self.gridLayout_4.addWidget(self.plainTextEdit, 0, 1, 1, 1)
        self.verticalLayout_3.addWidget(self.groupBox_7)
        icon = QtGui.QIcon.fromTheme("applications-graphics")
        self.tabWidget.addTab(self.tabStyle, icon, "")
        self.tabCompiler = QtWidgets.QWidget()
        self.tabCompiler.setObjectName("tabCompiler")
        self.formLayout_6 = QtWidgets.QFormLayout(self.tabCompiler)
        self.formLayout_6.setFieldGrowthPolicy(
            QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout_6.setObjectName("formLayout_6")
        self.label_8 = QtWidgets.QLabel(self.tabCompiler)
        self.label_8.setObjectName("label_8")
        self.formLayout_6.setWidget(0, QtWidgets.QFormLayout.LabelRole,
                                    self.label_8)
        self.label_9 = QtWidgets.QLabel(self.tabCompiler)
        self.label_9.setObjectName("label_9")
        self.formLayout_6.setWidget(2, QtWidgets.QFormLayout.LabelRole,
                                    self.label_9)
        self.checkBoxFreeFormat = QtWidgets.QCheckBox(self.tabCompiler)
        self.checkBoxFreeFormat.setText("")
        self.checkBoxFreeFormat.setObjectName("checkBoxFreeFormat")
        self.formLayout_6.setWidget(2, QtWidgets.QFormLayout.FieldRole,
                                    self.checkBoxFreeFormat)
        self.label_15 = QtWidgets.QLabel(self.tabCompiler)
        self.label_15.setObjectName("label_15")
        self.formLayout_6.setWidget(3, QtWidgets.QFormLayout.LabelRole,
                                    self.label_15)
        self.verticalLayout_4 = QtWidgets.QVBoxLayout()
        self.verticalLayout_4.setObjectName("verticalLayout_4")
        self.cb_g = QtWidgets.QCheckBox(self.tabCompiler)
        self.cb_g.setObjectName("cb_g")
        self.verticalLayout_4.addWidget(self.cb_g)
        self.cb_ftrace = QtWidgets.QCheckBox(self.tabCompiler)
        self.cb_ftrace.setObjectName("cb_ftrace")
        self.verticalLayout_4.addWidget(self.cb_ftrace)
        self.cb_ftraceall = QtWidgets.QCheckBox(self.tabCompiler)
        self.cb_ftraceall.setObjectName("cb_ftraceall")
        self.verticalLayout_4.addWidget(self.cb_ftraceall)
        self.cb_debugging_line = QtWidgets.QCheckBox(self.tabCompiler)
        self.cb_debugging_line.setObjectName("cb_debugging_line")
        self.verticalLayout_4.addWidget(self.cb_debugging_line)
        self.cb_static = QtWidgets.QCheckBox(self.tabCompiler)
        self.cb_static.setObjectName("cb_static")
        self.verticalLayout_4.addWidget(self.cb_static)
        self.le_compiler_flags = QtWidgets.QLineEdit(self.tabCompiler)
        self.le_compiler_flags.setObjectName("le_compiler_flags")
        self.verticalLayout_4.addWidget(self.le_compiler_flags)
        self.formLayout_6.setLayout(3, QtWidgets.QFormLayout.FieldRole,
                                    self.verticalLayout_4)
        self.label_compiler_path = QtWidgets.QLabel(self.tabCompiler)
        self.label_compiler_path.setObjectName("label_compiler_path")
        self.formLayout_6.setWidget(4, QtWidgets.QFormLayout.LabelRole,
                                    self.label_compiler_path)
        self.checkBoxCustomPath = QtWidgets.QCheckBox(self.tabCompiler)
        self.checkBoxCustomPath.setText("")
        self.checkBoxCustomPath.setObjectName("checkBoxCustomPath")
        self.formLayout_6.setWidget(4, QtWidgets.QFormLayout.FieldRole,
                                    self.checkBoxCustomPath)
        self.lineEditCompilerPath = QtWidgets.QLineEdit(self.tabCompiler)
        self.lineEditCompilerPath.setObjectName("lineEditCompilerPath")
        self.formLayout_6.setWidget(5, QtWidgets.QFormLayout.FieldRole,
                                    self.lineEditCompilerPath)
        self.comboBoxStandard = QtWidgets.QComboBox(self.tabCompiler)
        self.comboBoxStandard.setObjectName("comboBoxStandard")
        self.comboBoxStandard.addItem("")
        self.comboBoxStandard.addItem("")
        self.comboBoxStandard.addItem("")
        self.comboBoxStandard.addItem("")
        self.comboBoxStandard.addItem("")
        self.comboBoxStandard.addItem("")
        self.comboBoxStandard.addItem("")
        self.formLayout_6.setWidget(0, QtWidgets.QFormLayout.FieldRole,
                                    self.comboBoxStandard)
        icon = QtGui.QIcon.fromTheme("exec")
        self.tabWidget.addTab(self.tabCompiler, icon, "")
        self.tabRun = QtWidgets.QWidget()
        self.tabRun.setObjectName("tabRun")
        self.formLayout_5 = QtWidgets.QFormLayout(self.tabRun)
        self.formLayout_5.setFieldGrowthPolicy(
            QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout_5.setObjectName("formLayout_5")
        self.label_5 = QtWidgets.QLabel(self.tabRun)
        self.label_5.setObjectName("label_5")
        self.formLayout_5.setWidget(0, QtWidgets.QFormLayout.LabelRole,
                                    self.label_5)
        self.checkBoxRunExtTerm = QtWidgets.QCheckBox(self.tabRun)
        self.checkBoxRunExtTerm.setText("")
        self.checkBoxRunExtTerm.setObjectName("checkBoxRunExtTerm")
        self.formLayout_5.setWidget(0, QtWidgets.QFormLayout.FieldRole,
                                    self.checkBoxRunExtTerm)
        self.lineEditRunTerm = QtWidgets.QLineEdit(self.tabRun)
        self.lineEditRunTerm.setObjectName("lineEditRunTerm")
        self.formLayout_5.setWidget(1, QtWidgets.QFormLayout.FieldRole,
                                    self.lineEditRunTerm)
        icon = QtGui.QIcon.fromTheme("media-playback-start")
        self.tabWidget.addTab(self.tabRun, icon, "")
        self.widget_2.addWidget(self.tabWidget, 0, 0, 1, 1)
        self.gridLayout_2.addWidget(self.widget, 0, 0, 1, 1)
        self.gridLayout_3 = QtWidgets.QGridLayout()
        self.gridLayout_3.setContentsMargins(9, 9, 9, 9)
        self.gridLayout_3.setObjectName("gridLayout_3")
        self.buttonBox = QtWidgets.QDialogButtonBox(Dialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(
            QtWidgets.QDialogButtonBox.Cancel | QtWidgets.QDialogButtonBox.Ok
            | QtWidgets.QDialogButtonBox.Reset
            | QtWidgets.QDialogButtonBox.RestoreDefaults)
        self.buttonBox.setObjectName("buttonBox")
        self.gridLayout_3.addWidget(self.buttonBox, 0, 0, 1, 1)
        self.gridLayout_2.addLayout(self.gridLayout_3, 2, 0, 1, 1)

        self.retranslateUi(Dialog)
        self.tabWidget.setCurrentIndex(0)
        self.buttonBox.accepted.connect(Dialog.accept)
        self.buttonBox.rejected.connect(Dialog.reject)
        QtCore.QMetaObject.connectSlotsByName(Dialog)
示例#9
0
    def setupUi(self, Form):
        Form.setObjectName("Form")
        Form.resize(558, 381)
        self.formLayout = QtWidgets.QFormLayout(Form)
        self.formLayout.setFieldGrowthPolicy(QtWidgets.QFormLayout.AllNonFixedFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.label = QtWidgets.QLabel(Form)
        self.label.setObjectName("label")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole, self.label)
        self.pickerScript = FilePicker(Form)
        self.pickerScript.setObjectName("pickerScript")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole, self.pickerScript)
        self.label_2 = QtWidgets.QLabel(Form)
        self.label_2.setObjectName("label_2")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.LabelRole, self.label_2)
        self.lineEditScriptParams = QtWidgets.QLineEdit(Form)
        self.lineEditScriptParams.setObjectName("lineEditScriptParams")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.FieldRole, self.lineEditScriptParams)
        self.lblInterpreter = QtWidgets.QLabel(Form)
        self.lblInterpreter.setObjectName("lblInterpreter")
        self.formLayout.setWidget(5, QtWidgets.QFormLayout.LabelRole, self.lblInterpreter)
        self.comboBoxInterpreter = QtWidgets.QComboBox(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.comboBoxInterpreter.sizePolicy().hasHeightForWidth())
        self.comboBoxInterpreter.setSizePolicy(sizePolicy)
        self.comboBoxInterpreter.setObjectName("comboBoxInterpreter")
        self.formLayout.setWidget(5, QtWidgets.QFormLayout.FieldRole, self.comboBoxInterpreter)
        self.label_4 = QtWidgets.QLabel(Form)
        self.label_4.setObjectName("label_4")
        self.formLayout.setWidget(6, QtWidgets.QFormLayout.LabelRole, self.label_4)
        self.lineEdidInterpreterOpts = QtWidgets.QLineEdit(Form)
        self.lineEdidInterpreterOpts.setObjectName("lineEdidInterpreterOpts")
        self.formLayout.setWidget(6, QtWidgets.QFormLayout.FieldRole, self.lineEdidInterpreterOpts)
        self.label_6 = QtWidgets.QLabel(Form)
        self.label_6.setObjectName("label_6")
        self.formLayout.setWidget(7, QtWidgets.QFormLayout.LabelRole, self.label_6)
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.tableWidgetEnvVars = QtWidgets.QTableWidget(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(1)
        sizePolicy.setHeightForWidth(self.tableWidgetEnvVars.sizePolicy().hasHeightForWidth())
        self.tableWidgetEnvVars.setSizePolicy(sizePolicy)
        self.tableWidgetEnvVars.setAlternatingRowColors(False)
        self.tableWidgetEnvVars.setSelectionMode(QtWidgets.QAbstractItemView.SingleSelection)
        self.tableWidgetEnvVars.setSelectionBehavior(QtWidgets.QAbstractItemView.SelectRows)
        self.tableWidgetEnvVars.setGridStyle(QtCore.Qt.SolidLine)
        self.tableWidgetEnvVars.setRowCount(0)
        self.tableWidgetEnvVars.setObjectName("tableWidgetEnvVars")
        self.tableWidgetEnvVars.setColumnCount(2)
        item = QtWidgets.QTableWidgetItem()
        self.tableWidgetEnvVars.setHorizontalHeaderItem(0, item)
        item = QtWidgets.QTableWidgetItem()
        self.tableWidgetEnvVars.setHorizontalHeaderItem(1, item)
        self.tableWidgetEnvVars.horizontalHeader().setCascadingSectionResizes(False)
        self.tableWidgetEnvVars.horizontalHeader().setStretchLastSection(True)
        self.tableWidgetEnvVars.verticalHeader().setVisible(False)
        self.horizontalLayout.addWidget(self.tableWidgetEnvVars)
        self.verticalLayout = QtWidgets.QVBoxLayout()
        self.verticalLayout.setContentsMargins(0, -1, -1, -1)
        self.verticalLayout.setObjectName("verticalLayout")
        self.toolButtonAdd = QtWidgets.QToolButton(Form)
        self.toolButtonAdd.setText("")
        icon = QtGui.QIcon.fromTheme("list-add")
        self.toolButtonAdd.setIcon(icon)
        self.toolButtonAdd.setObjectName("toolButtonAdd")
        self.verticalLayout.addWidget(self.toolButtonAdd)
        self.toolButtonRemove = QtWidgets.QToolButton(Form)
        self.toolButtonRemove.setText("")
        icon = QtGui.QIcon.fromTheme("list-remove")
        self.toolButtonRemove.setIcon(icon)
        self.toolButtonRemove.setObjectName("toolButtonRemove")
        self.verticalLayout.addWidget(self.toolButtonRemove)
        spacerItem = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
        self.verticalLayout.addItem(spacerItem)
        self.horizontalLayout.addLayout(self.verticalLayout)
        self.formLayout.setLayout(7, QtWidgets.QFormLayout.FieldRole, self.horizontalLayout)
        self.label_5 = QtWidgets.QLabel(Form)
        self.label_5.setObjectName("label_5")
        self.formLayout.setWidget(4, QtWidgets.QFormLayout.LabelRole, self.label_5)
        self.pickerWorkingDir = FilePicker(Form)
        self.pickerWorkingDir.setObjectName("pickerWorkingDir")
        self.formLayout.setWidget(4, QtWidgets.QFormLayout.FieldRole, self.pickerWorkingDir)
        self.lblName = QtWidgets.QLabel(Form)
        self.lblName.setObjectName("lblName")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole, self.lblName)
        self.lineEditName = QtWidgets.QLineEdit(Form)
        self.lineEditName.setObjectName("lineEditName")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.FieldRole, self.lineEditName)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
        Form.setTabOrder(self.lineEditName, self.lineEditScriptParams)
        Form.setTabOrder(self.lineEditScriptParams, self.comboBoxInterpreter)
        Form.setTabOrder(self.comboBoxInterpreter, self.lineEdidInterpreterOpts)
        Form.setTabOrder(self.lineEdidInterpreterOpts, self.tableWidgetEnvVars)
        Form.setTabOrder(self.tableWidgetEnvVars, self.toolButtonAdd)
        Form.setTabOrder(self.toolButtonAdd, self.toolButtonRemove)