Example #1
0
 def __init__(self, app):
     super().__init__(app)
     QtGui.QIcon.setThemeName(Settings().icon_theme)
     self._page = -1
     self._perspective = 'default'
     self._nav_was_visible = True
     self._offset_was_visible = True
     self.setup_icons()
     self.ui.tabWidgetEditors.setContextMenuPolicy(
         QtCore.Qt.CustomContextMenu)
     self.ui.tabWidgetEditors.customContextMenuRequested.connect(
         self.show_main_menu_as_context_menu)
     self.ui.tabWidgetEditors.tab_bar_double_clicked.connect(
         self.toggle_perspective)
     self.ui.actionFullscreen.triggered.connect(self.toggle_fullscreen)
     self.bt_mnu = QtWidgets.QToolButton()
     self.main_window.addActions(self.make_main_menu().actions())
     window_mnu = self.main_window.createPopupMenu()
     self.ui.menuWindows.addActions(window_mnu.actions())
     if system.darwin:
         self.ui.toolBarCode.setIconSize(QtCore.QSize(20, 20))
         self.ui.toolBarFile.setIconSize(QtCore.QSize(20, 20))
         self.ui.toolBarFile.setStyleSheet(
             '''QToolButton
             {
                  background-color: rgba(255, 255,255,0);
             }
             ''')
         self.ui.toolBarCode.setStyleSheet(
             '''QToolButton
             {
                  background-color: rgba(255, 255,255,0);
             }
             ''')
     self.ui.actionFullscreen.setChecked(Settings().fullscreen)
Example #2
0
 def create_bt_run(self):
     icon = self.ui.actionRun.icon()
     bt = QtWidgets.QToolButton()
     bt.setIcon(icon)
     bt.setToolTip(self.ui.actionRun.toolTip())
     bt.clicked.connect(self.run)
     self.run_buttons.append(bt)
     bt.setEnabled(self.ui.actionRun.isEnabled())
     return bt
Example #3
0
 def create_bt_compile(self):
     bt_compile = QtWidgets.QToolButton()
     bt_compile.setIcon(self.ui.actionCompile.icon())
     bt_compile.setMenu(self.ui.menuProgramType)
     bt_compile.setToolTip(self.ui.actionCompile.toolTip())
     bt_compile.setPopupMode(bt_compile.MenuButtonPopup)
     bt_compile.clicked.connect(self.compile)
     self.compile_buttons.append(bt_compile)
     bt_compile.setEnabled(self.ui.actionCompile.isEnabled())
     return bt_compile
Example #4
0
 def __init__(self, parent=None):
     super(FilePicker, self).__init__(parent)
     self._default_dir = os.path.expanduser('~')
     self._pick_dirs = True
     layout = QtWidgets.QHBoxLayout()
     layout.setContentsMargins(0, 0, 0, 0)
     self.line_edit = QtWidgets.QLineEdit()
     self.path = os.path.expanduser('~')
     layout.addWidget(self.line_edit)
     self.tool_button = QtWidgets.QToolButton()
     self.tool_button.setText('...')
     layout.addWidget(self.tool_button)
     self.setLayout(layout)
     completer = QtWidgets.QCompleter(self)
     self._mdl = QtWidgets.QDirModel(completer)
     completer.setModel(self._mdl)
     self.line_edit.setCompleter(completer)
     self.pick_dirs = False
     self.tool_button.clicked.connect(self._pick)
     self.line_edit.textChanged.connect(self._on_path_changed)
Example #5
0
 def _add_scope_widgets(self, scopes):
     for scope in scopes:
         name = self.extract_node_name(scope)
         if name is not None:
             w = QtWidgets.QToolButton(self)
             w.setText(name)
             w.scope = scope
             w.setCheckable(True)
             w.toggled.connect(self._on_bt_toggled)
             self._widgets.append(w)
             self._layout.addWidget(w)
     # toggle current and add a spacer
     if self._widgets:
         self._lock = True
         self._widgets[-1].setChecked(True)
         self._lock = False
         self._toggled = self._widgets[-1]
         s = QtWidgets.QSpacerItem(20, 20, QtWidgets.QSizePolicy.Expanding)
         self._widgets.append(s)
         self._layout.addSpacerItem(s)
Example #6
0
    def _setup_status_bar(self):
        """
        Adds some labels to the tool bar:
            - format (free or fixed)
            - encoding
            - cursor position (line:column)
        """
        # encoding
        self._lbl_encoding = QtWidgets.QLabel()
        self._lbl_encoding.setFrameShape(QtWidgets.QFrame.NoFrame)
        self._lbl_encoding.setAlignment(
            QtCore.Qt.AlignHCenter | QtCore.Qt.AlignVCenter)
        self._lbl_encoding.setText('UTF-8')
        # format
        self._cb_free_format = QtWidgets.QCheckBox('Free format')
        self._cb_free_format.setChecked(Settings().free_format)
        self._cb_free_format.toggled.connect(self._on_free_format_toggled)
        # cursor position
        self._lbl_cursor = QtWidgets.QLabel()
        self._lbl_cursor.setFrameShape(QtWidgets.QFrame.NoFrame)
        self._lbl_cursor.setAlignment(QtCore.Qt.AlignHCenter |
                                      QtCore.Qt.AlignVCenter)
        self._lbl_cursor.setText('1:1')

        # path
        self._lbl_path = QtWidgets.QLabel()
        self._lbl_path.setFrameShape(QtWidgets.QFrame.NoFrame)
        self._lbl_path.setText('n/a')

        # linter control button
        linter_btn = QtWidgets.QToolButton(self.ui.statusbar)
        linter_btn.setDefaultAction(self.ui.actionEnableLinter)

        self.ui.statusbar.addWidget(self._lbl_path, True)
        self.ui.statusbar.addAction(self.ui.actionEnableLinter)
        self.ui.statusbar.addPermanentWidget(linter_btn)
        self.ui.statusbar.addPermanentWidget(self._cb_free_format)
        self.ui.statusbar.addPermanentWidget(self._lbl_cursor)
        self.ui.statusbar.addPermanentWidget(self._lbl_encoding)
        self.ui.statusbar.setStyleSheet(
            'QStatusBar::item { border: 0px solid black };')
Example #7
0
    def __init__(self, parent=None, prompt_text=' Search', button_icon=None):
        super(PromptLineEdit, self).__init__(parent)
        self._margin = self.sizeHint().height() - 2
        self._spacing = 0
        self._prompt_text = prompt_text

        self.button = QtWidgets.QToolButton(self)
        if button_icon is None:
            button_icon = QtGui.QIcon.fromTheme(
                'edit-clear', QtGui.QIcon(':/pyqode-icons/rc/clear-left.png'))

        self.button.setIcon(button_icon)
        self.button.setToolTip("Clear")
        self.button.setStyleSheet(
            "QToolButton { border: none; padding: 5px; }")
        self.button.setCursor(QtCore.Qt.ArrowCursor)
        self.button.setFocusPolicy(QtCore.Qt.NoFocus)
        self.set_button_visible(False)
        self.textChanged.connect(self._on_text_changed)
        self.button.clicked.connect(self.clear)
        self.button.clicked.connect(self.clear_clicked.emit)
    def setupUi(self, Form):
        Form.setObjectName("Form")
        Form.resize(668, 645)
        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.formLayout = QtWidgets.QFormLayout(self.groupBox)
        self.formLayout.setFieldGrowthPolicy(
            QtWidgets.QFormLayout.ExpandingFieldsGrow)
        self.formLayout.setObjectName("formLayout")
        self.label = QtWidgets.QLabel(self.groupBox)
        self.label.setObjectName("label")
        self.formLayout.setWidget(0, QtWidgets.QFormLayout.LabelRole,
                                  self.label)
        self.horizontalLayout_2 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_2.setObjectName("horizontalLayout_2")
        self.line_edit_font = QtWidgets.QLineEdit(self.groupBox)
        self.line_edit_font.setObjectName("line_edit_font")
        self.horizontalLayout_2.addWidget(self.line_edit_font)
        self.bt_font = QtWidgets.QToolButton(self.groupBox)
        self.bt_font.setObjectName("bt_font")
        self.horizontalLayout_2.addWidget(self.bt_font)
        self.formLayout.setLayout(0, QtWidgets.QFormLayout.FieldRole,
                                  self.horizontalLayout_2)
        self.label_3 = QtWidgets.QLabel(self.groupBox)
        self.label_3.setObjectName("label_3")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.LabelRole,
                                  self.label_3)
        self.spinbox_font_size = QtWidgets.QSpinBox(self.groupBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding,
                                           QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.spinbox_font_size.sizePolicy().hasHeightForWidth())
        self.spinbox_font_size.setSizePolicy(sizePolicy)
        self.spinbox_font_size.setObjectName("spinbox_font_size")
        self.formLayout.setWidget(1, QtWidgets.QFormLayout.FieldRole,
                                  self.spinbox_font_size)
        self.label_4 = QtWidgets.QLabel(self.groupBox)
        self.label_4.setObjectName("label_4")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.LabelRole,
                                  self.label_4)
        self.list_color_schemes = QtWidgets.QListWidget(self.groupBox)
        self.list_color_schemes.setObjectName("list_color_schemes")
        self.formLayout.setWidget(3, QtWidgets.QFormLayout.FieldRole,
                                  self.list_color_schemes)
        self.label_2 = QtWidgets.QLabel(self.groupBox)
        self.label_2.setObjectName("label_2")
        self.formLayout.setWidget(4, QtWidgets.QFormLayout.LabelRole,
                                  self.label_2)
        self.checkbox_whitespaces = QtWidgets.QCheckBox(self.groupBox)
        self.checkbox_whitespaces.setText("")
        self.checkbox_whitespaces.setObjectName("checkbox_whitespaces")
        self.formLayout.setWidget(4, QtWidgets.QFormLayout.FieldRole,
                                  self.checkbox_whitespaces)
        self.verticalLayout.addWidget(self.groupBox)
        self.groupBox_2 = QtWidgets.QGroupBox(Form)
        self.groupBox_2.setObjectName("groupBox_2")
        self.gridLayout = QtWidgets.QGridLayout(self.groupBox_2)
        self.gridLayout.setObjectName("gridLayout")
        self.edit_preview = PyCodeEdit(self.groupBox_2)
        self.edit_preview.setObjectName("edit_preview")
        self.gridLayout.addWidget(self.edit_preview, 0, 0, 1, 1)
        self.verticalLayout.addWidget(self.groupBox_2)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)
Example #9
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)
Example #10
0
    def setupUi(self, SearchPanel):
        SearchPanel.setObjectName("SearchPanel")
        SearchPanel.resize(884, 90)
        SearchPanel.setStyleSheet("")
        self.verticalLayout = QtWidgets.QVBoxLayout(SearchPanel)
        self.verticalLayout.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout.setSpacing(0)
        self.verticalLayout.setObjectName("verticalLayout")
        self.frame = QtWidgets.QFrame(SearchPanel)
        self.frame.setFrameShape(QtWidgets.QFrame.NoFrame)
        self.frame.setFrameShadow(QtWidgets.QFrame.Raised)
        self.frame.setObjectName("frame")
        self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.frame)
        self.verticalLayout_2.setContentsMargins(9, 9, 9, 9)
        self.verticalLayout_2.setSpacing(9)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.widgetSearch = QtWidgets.QWidget(self.frame)
        self.widgetSearch.setObjectName("widgetSearch")
        self.horizontalLayout = QtWidgets.QHBoxLayout(self.widgetSearch)
        self.horizontalLayout.setContentsMargins(0, 0, 0, 0)
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.labelSearch = QtWidgets.QLabel(self.widgetSearch)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.labelSearch.sizePolicy().hasHeightForWidth())
        self.labelSearch.setSizePolicy(sizePolicy)
        self.labelSearch.setMinimumSize(QtCore.QSize(0, 0))
        self.labelSearch.setMaximumSize(QtCore.QSize(18, 18))
        self.labelSearch.setText("")
        self.labelSearch.setPixmap(QtGui.QPixmap(":/pycode-icons/rc/edit-find.png"))
        self.labelSearch.setScaledContents(True)
        self.labelSearch.setObjectName("labelSearch")
        self.horizontalLayout.addWidget(self.labelSearch)
        self.lineEditSearch = PromptLineEdit(self.widgetSearch)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.lineEditSearch.sizePolicy().hasHeightForWidth())
        self.lineEditSearch.setSizePolicy(sizePolicy)
        self.lineEditSearch.setMinimumSize(QtCore.QSize(200, 0))
        self.lineEditSearch.setObjectName("lineEditSearch")
        self.horizontalLayout.addWidget(self.lineEditSearch)
        self.toolButtonPrevious = QtWidgets.QToolButton(self.widgetSearch)
        self.toolButtonPrevious.setText("")
        icon = QtGui.QIcon()
        icon.addPixmap(QtGui.QPixmap(":/pyqode_icons/rc/go-up.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.toolButtonPrevious.setIcon(icon)
        self.toolButtonPrevious.setObjectName("toolButtonPrevious")
        self.horizontalLayout.addWidget(self.toolButtonPrevious)
        self.toolButtonNext = QtWidgets.QToolButton(self.widgetSearch)
        self.toolButtonNext.setText("")
        icon1 = QtGui.QIcon()
        icon1.addPixmap(QtGui.QPixmap(":/pycode-icons/rc/go-down.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.toolButtonNext.setIcon(icon1)
        self.toolButtonNext.setObjectName("toolButtonNext")
        self.horizontalLayout.addWidget(self.toolButtonNext)
        self.checkBoxRegex = QtWidgets.QCheckBox(self.widgetSearch)
        self.checkBoxRegex.setObjectName("checkBoxRegex")
        self.horizontalLayout.addWidget(self.checkBoxRegex)
        self.checkBoxCase = QtWidgets.QCheckBox(self.widgetSearch)
        self.checkBoxCase.setStyleSheet("")
        self.checkBoxCase.setObjectName("checkBoxCase")
        self.horizontalLayout.addWidget(self.checkBoxCase)
        self.checkBoxWholeWords = QtWidgets.QCheckBox(self.widgetSearch)
        self.checkBoxWholeWords.setObjectName("checkBoxWholeWords")
        self.horizontalLayout.addWidget(self.checkBoxWholeWords)
        self.checkBoxInSelection = QtWidgets.QCheckBox(self.widgetSearch)
        self.checkBoxInSelection.setObjectName("checkBoxInSelection")
        self.horizontalLayout.addWidget(self.checkBoxInSelection)
        spacerItem = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout.addItem(spacerItem)
        self.labelMatches = QtWidgets.QLabel(self.widgetSearch)
        self.labelMatches.setObjectName("labelMatches")
        self.horizontalLayout.addWidget(self.labelMatches)
        self.toolButtonClose = QtWidgets.QToolButton(self.widgetSearch)
        self.toolButtonClose.setText("")
        icon2 = QtGui.QIcon()
        icon2.addPixmap(QtGui.QPixmap(":/pycode-icons/rc/close.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.toolButtonClose.setIcon(icon2)
        self.toolButtonClose.setObjectName("toolButtonClose")
        self.horizontalLayout.addWidget(self.toolButtonClose)
        self.verticalLayout_2.addWidget(self.widgetSearch)
        self.widgetReplace = QtWidgets.QWidget(self.frame)
        self.widgetReplace.setObjectName("widgetReplace")
        self.horizontalLayout_2 = QtWidgets.QHBoxLayout(self.widgetReplace)
        self.horizontalLayout_2.setContentsMargins(0, 0, 0, 0)
        self.horizontalLayout_2.setObjectName("horizontalLayout_2")
        self.labelReplace = QtWidgets.QLabel(self.widgetReplace)
        self.labelReplace.setMaximumSize(QtCore.QSize(18, 18))
        self.labelReplace.setText("")
        self.labelReplace.setPixmap(QtGui.QPixmap(":/pycode-icons/rc/edit-find-replace.png"))
        self.labelReplace.setScaledContents(True)
        self.labelReplace.setObjectName("labelReplace")
        self.horizontalLayout_2.addWidget(self.labelReplace)
        self.lineEditReplace = PromptLineEdit(self.widgetReplace)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.lineEditReplace.sizePolicy().hasHeightForWidth())
        self.lineEditReplace.setSizePolicy(sizePolicy)
        self.lineEditReplace.setMinimumSize(QtCore.QSize(200, 0))
        self.lineEditReplace.setObjectName("lineEditReplace")
        self.horizontalLayout_2.addWidget(self.lineEditReplace)
        self.toolButtonReplace = QtWidgets.QToolButton(self.widgetReplace)
        self.toolButtonReplace.setObjectName("toolButtonReplace")
        self.horizontalLayout_2.addWidget(self.toolButtonReplace)
        self.toolButtonReplaceAll = QtWidgets.QToolButton(self.widgetReplace)
        self.toolButtonReplaceAll.setObjectName("toolButtonReplaceAll")
        self.horizontalLayout_2.addWidget(self.toolButtonReplaceAll)
        spacerItem1 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_2.addItem(spacerItem1)
        self.lineEditReplace.raise_()
        self.toolButtonReplace.raise_()
        self.toolButtonReplaceAll.raise_()
        self.labelReplace.raise_()
        self.verticalLayout_2.addWidget(self.widgetReplace)
        self.verticalLayout.addWidget(self.frame)
        self.actionSearch = QtWidgets.QAction(SearchPanel)
        icon = QtGui.QIcon.fromTheme("edit-find")
        self.actionSearch.setIcon(icon)
        self.actionSearch.setIconVisibleInMenu(True)
        self.actionSearch.setObjectName("actionSearch")
        self.actionActionSearchAndReplace = QtWidgets.QAction(SearchPanel)
        icon = QtGui.QIcon.fromTheme("edit-find-replace")
        self.actionActionSearchAndReplace.setIcon(icon)
        self.actionActionSearchAndReplace.setIconVisibleInMenu(True)
        self.actionActionSearchAndReplace.setObjectName("actionActionSearchAndReplace")
        self.actionFindNext = QtWidgets.QAction(SearchPanel)
        icon = QtGui.QIcon.fromTheme("go-down")
        self.actionFindNext.setIcon(icon)
        self.actionFindNext.setIconVisibleInMenu(True)
        self.actionFindNext.setObjectName("actionFindNext")
        self.actionFindPrevious = QtWidgets.QAction(SearchPanel)
        icon = QtGui.QIcon.fromTheme("go-up")
        self.actionFindPrevious.setIcon(icon)
        self.actionFindPrevious.setIconVisibleInMenu(True)
        self.actionFindPrevious.setObjectName("actionFindPrevious")

        self.retranslateUi(SearchPanel)
        QtCore.QMetaObject.connectSlotsByName(SearchPanel)
        SearchPanel.setTabOrder(self.lineEditSearch, self.lineEditReplace)
        SearchPanel.setTabOrder(self.lineEditReplace, self.toolButtonPrevious)
        SearchPanel.setTabOrder(self.toolButtonPrevious, self.toolButtonNext)
        SearchPanel.setTabOrder(self.toolButtonNext, self.checkBoxCase)
        SearchPanel.setTabOrder(self.checkBoxCase, self.checkBoxWholeWords)
        SearchPanel.setTabOrder(self.checkBoxWholeWords, self.toolButtonReplace)
        SearchPanel.setTabOrder(self.toolButtonReplace, self.toolButtonReplaceAll)
        SearchPanel.setTabOrder(self.toolButtonReplaceAll, self.toolButtonClose)
    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)
Example #12
0
    def setupUi(self, MainWindow):
        MainWindow.setObjectName("MainWindow")
        MainWindow.resize(1366, 768)
        MainWindow.setMinimumSize(QtCore.QSize(0, 0))
        icon = QtGui.QIcon()
        icon.addPixmap(QtGui.QPixmap(":/ide-icons/rc/silex-192x192.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        MainWindow.setWindowIcon(icon)
        self.centralwidget = QtWidgets.QWidget(MainWindow)
        self.centralwidget.setObjectName("centralwidget")
        self.gridLayout = QtWidgets.QGridLayout(self.centralwidget)
        self.gridLayout.setContentsMargins(0, 0, 0, 0)
        self.gridLayout.setSpacing(0)
        self.gridLayout.setObjectName("gridLayout")
        self.stackedWidget = QtWidgets.QStackedWidget(self.centralwidget)
        self.stackedWidget.setObjectName("stackedWidget")
        self.pageHome = QtWidgets.QWidget()
        self.pageHome.setObjectName("pageHome")
        self.verticalLayout_5 = QtWidgets.QVBoxLayout(self.pageHome)
        self.verticalLayout_5.setObjectName("verticalLayout_5")
        self.widgetHome = QtWidgets.QWidget(self.pageHome)
        self.widgetHome.setObjectName("widgetHome")
        self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.widgetHome)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        spacerItem = QtWidgets.QSpacerItem(20, 0, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
        self.verticalLayout_2.addItem(spacerItem)
        self.horizontalLayout_3 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_3.setContentsMargins(0, -1, 0, -1)
        self.horizontalLayout_3.setObjectName("horizontalLayout_3")
        spacerItem1 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_3.addItem(spacerItem1)
        self.verticalLayout_3 = QtWidgets.QVBoxLayout()
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.label_3 = QtWidgets.QLabel(self.widgetHome)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.label_3.sizePolicy().hasHeightForWidth())
        self.label_3.setSizePolicy(sizePolicy)
        self.label_3.setMinimumSize(QtCore.QSize(0, 0))
        self.label_3.setMaximumSize(QtCore.QSize(16777215, 16777215))
        self.label_3.setWordWrap(True)
        self.label_3.setObjectName("label_3")
        self.verticalLayout_3.addWidget(self.label_3)
        self.horizontalLayout_3.addLayout(self.verticalLayout_3)
        spacerItem2 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_3.addItem(spacerItem2)
        self.verticalLayout_2.addLayout(self.horizontalLayout_3)
        self.horizontalLayout_8 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_8.setContentsMargins(-1, 0, -1, 0)
        self.horizontalLayout_8.setObjectName("horizontalLayout_8")
        spacerItem3 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_8.addItem(spacerItem3)
        self.btNewFile = QtWidgets.QPushButton(self.widgetHome)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.btNewFile.sizePolicy().hasHeightForWidth())
        self.btNewFile.setSizePolicy(sizePolicy)
        self.btNewFile.setMinimumSize(QtCore.QSize(200, 0))
        self.btNewFile.setObjectName("btNewFile")
        self.horizontalLayout_8.addWidget(self.btNewFile)
        self.btOpenFile = QtWidgets.QPushButton(self.widgetHome)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.btOpenFile.sizePolicy().hasHeightForWidth())
        self.btOpenFile.setSizePolicy(sizePolicy)
        self.btOpenFile.setMinimumSize(QtCore.QSize(200, 0))
        self.btOpenFile.setStyleSheet("")
        self.btOpenFile.setObjectName("btOpenFile")
        self.horizontalLayout_8.addWidget(self.btOpenFile)
        spacerItem4 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_8.addItem(spacerItem4)
        self.verticalLayout_2.addLayout(self.horizontalLayout_8)
        self.horizontalLayout_5 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_5.setContentsMargins(0, -1, -1, -1)
        self.horizontalLayout_5.setObjectName("horizontalLayout_5")
        spacerItem5 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_5.addItem(spacerItem5)
        self.frameRecents = QtWidgets.QFrame(self.widgetHome)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.frameRecents.sizePolicy().hasHeightForWidth())
        self.frameRecents.setSizePolicy(sizePolicy)
        self.frameRecents.setMinimumSize(QtCore.QSize(406, 0))
        self.frameRecents.setMaximumSize(QtCore.QSize(16777215, 16777215))
        self.frameRecents.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.frameRecents.setFrameShadow(QtWidgets.QFrame.Raised)
        self.frameRecents.setObjectName("frameRecents")
        self.verticalLayout_4 = QtWidgets.QVBoxLayout(self.frameRecents)
        self.verticalLayout_4.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout_4.setSpacing(0)
        self.verticalLayout_4.setObjectName("verticalLayout_4")
        self.labelRecents = QtWidgets.QLabel(self.frameRecents)
        self.labelRecents.setMaximumSize(QtCore.QSize(16777215, 16777215))
        self.labelRecents.setObjectName("labelRecents")
        self.verticalLayout_4.addWidget(self.labelRecents)
        self.listWidgetRecents = RecentFilesListWidget(self.frameRecents)
        self.listWidgetRecents.setMinimumSize(QtCore.QSize(400, 0))
        self.listWidgetRecents.setMaximumSize(QtCore.QSize(16777215, 16777215))
        self.listWidgetRecents.setObjectName("listWidgetRecents")
        self.verticalLayout_4.addWidget(self.listWidgetRecents)
        self.horizontalLayout_5.addWidget(self.frameRecents)
        spacerItem6 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_5.addItem(spacerItem6)
        self.verticalLayout_2.addLayout(self.horizontalLayout_5)
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setContentsMargins(-1, 0, -1, -1)
        self.horizontalLayout.setObjectName("horizontalLayout")
        spacerItem7 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout.addItem(spacerItem7)
        self.verticalLayout_7 = QtWidgets.QVBoxLayout()
        self.verticalLayout_7.setContentsMargins(0, -1, -1, -1)
        self.verticalLayout_7.setObjectName("verticalLayout_7")
        self.btPreferences = QtWidgets.QPushButton(self.widgetHome)
        self.btPreferences.setMinimumSize(QtCore.QSize(200, 0))
        self.btPreferences.setObjectName("btPreferences")
        self.verticalLayout_7.addWidget(self.btPreferences)
        self.btAbout = QtWidgets.QPushButton(self.widgetHome)
        self.btAbout.setMinimumSize(QtCore.QSize(200, 0))
        self.btAbout.setObjectName("btAbout")
        self.verticalLayout_7.addWidget(self.btAbout)
        self.horizontalLayout.addLayout(self.verticalLayout_7)
        spacerItem8 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout.addItem(spacerItem8)
        self.verticalLayout_2.addLayout(self.horizontalLayout)
        spacerItem9 = QtWidgets.QSpacerItem(20, 1, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
        self.verticalLayout_2.addItem(spacerItem9)
        self.verticalLayout_5.addWidget(self.widgetHome)
        self.stackedWidget.addWidget(self.pageHome)
        self.page_2 = QtWidgets.QWidget()
        self.page_2.setObjectName("page_2")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.page_2)
        self.gridLayout_2.setContentsMargins(3, 3, 3, 3)
        self.gridLayout_2.setHorizontalSpacing(3)
        self.gridLayout_2.setVerticalSpacing(0)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.tabWidgetEditors = TabWidget(self.page_2)
        self.tabWidgetEditors.setOrientation(QtCore.Qt.Horizontal)
        self.tabWidgetEditors.setObjectName("tabWidgetEditors")
        self.gridLayout_2.addWidget(self.tabWidgetEditors, 0, 0, 1, 1)
        self.stackedWidget.addWidget(self.page_2)
        self.gridLayout.addWidget(self.stackedWidget, 0, 0, 1, 1)
        MainWindow.setCentralWidget(self.centralwidget)
        self.statusbar = QtWidgets.QStatusBar(MainWindow)
        self.statusbar.setObjectName("statusbar")
        MainWindow.setStatusBar(self.statusbar)
        self.toolBarFile = QtWidgets.QToolBar(MainWindow)
        self.toolBarFile.setObjectName("toolBarFile")
        MainWindow.addToolBar(QtCore.Qt.TopToolBarArea, self.toolBarFile)
        self.toolBarCOBOL = QtWidgets.QToolBar(MainWindow)
        self.toolBarCOBOL.setObjectName("toolBarCOBOL")
        MainWindow.addToolBar(QtCore.Qt.TopToolBarArea, self.toolBarCOBOL)
        self.dockWidgetLogs = QtWidgets.QDockWidget(MainWindow)
        self.dockWidgetLogs.setObjectName("dockWidgetLogs")
        self.dockWidgetContents = QtWidgets.QWidget()
        self.dockWidgetContents.setObjectName("dockWidgetContents")
        self.gridLayout_3 = QtWidgets.QGridLayout(self.dockWidgetContents)
        self.gridLayout_3.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_3.setSpacing(0)
        self.gridLayout_3.setObjectName("gridLayout_3")
        self.tabWidgetLogs = QtWidgets.QTabWidget(self.dockWidgetContents)
        self.tabWidgetLogs.setObjectName("tabWidgetLogs")
        self.tabCompiler = QtWidgets.QWidget()
        self.tabCompiler.setObjectName("tabCompiler")
        self.gridLayout_6 = QtWidgets.QGridLayout(self.tabCompiler)
        self.gridLayout_6.setObjectName("gridLayout_6")
        self.textEditCompilerOutput = QtWidgets.QTextEdit(self.tabCompiler)
        self.textEditCompilerOutput.setReadOnly(True)
        self.textEditCompilerOutput.setObjectName("textEditCompilerOutput")
        self.gridLayout_6.addWidget(self.textEditCompilerOutput, 0, 0, 1, 1)
        icon1 = QtGui.QIcon()
        icon1.addPixmap(QtGui.QPixmap(":/ide-icons/rc/silex-32x32.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.tabWidgetLogs.addTab(self.tabCompiler, icon1, "")
        self.tabCompiler1 = QtWidgets.QWidget()
        self.tabCompiler1.setObjectName("tabCompiler1")
        self.gridLayout_4 = QtWidgets.QGridLayout(self.tabCompiler1)
        self.gridLayout_4.setContentsMargins(6, 6, 6, 6)
        self.gridLayout_4.setObjectName("gridLayout_4")
        self.errorsTable = ErrorsTable(self.tabCompiler1)
        self.errorsTable.setMinimumSize(QtCore.QSize(0, 0))
        self.errorsTable.setObjectName("errorsTable")
        self.errorsTable.setColumnCount(5)
        self.errorsTable.setRowCount(0)
        self.gridLayout_4.addWidget(self.errorsTable, 0, 0, 1, 1)
        icon = QtGui.QIcon.fromTheme("emblem-important")
        self.tabWidgetLogs.addTab(self.tabCompiler1, icon, "")
        self.tabProgramOutput = QtWidgets.QWidget()
        self.tabProgramOutput.setObjectName("tabProgramOutput")
        self.gridLayout_5 = QtWidgets.QGridLayout(self.tabProgramOutput)
        self.gridLayout_5.setContentsMargins(6, 6, 6, 6)
        self.gridLayout_5.setSpacing(6)
        self.gridLayout_5.setObjectName("gridLayout_5")
        self.consoleOutput = MyOutputWindow(self.tabProgramOutput)
        self.consoleOutput.setObjectName("consoleOutput")
        self.gridLayout_5.addWidget(self.consoleOutput, 0, 0, 1, 1)
        icon = QtGui.QIcon.fromTheme("media-playback-start")
        self.tabWidgetLogs.addTab(self.tabProgramOutput, icon, "")
        self.gridLayout_3.addWidget(self.tabWidgetLogs, 1, 0, 1, 1)
        self.dockWidgetLogs.setWidget(self.dockWidgetContents)
        MainWindow.addDockWidget(QtCore.Qt.DockWidgetArea(8), self.dockWidgetLogs)
        self.menuBar = QtWidgets.QMenuBar(MainWindow)
        self.menuBar.setGeometry(QtCore.QRect(0, 0, 1366, 21))
        self.menuBar.setObjectName("menuBar")
        self.menuFile = QtWidgets.QMenu(self.menuBar)
        self.menuFile.setObjectName("menuFile")
        self.menuEdit = QtWidgets.QMenu(self.menuBar)
        self.menuEdit.setObjectName("menuEdit")
        self.mnuActiveEditor = QtWidgets.QMenu(self.menuEdit)
        icon = QtGui.QIcon.fromTheme("accessories-text-editor")
        self.mnuActiveEditor.setIcon(icon)
        self.mnuActiveEditor.setObjectName("mnuActiveEditor")
        self.menuView = QtWidgets.QMenu(self.menuBar)
        self.menuView.setObjectName("menuView")
        self.menuWindows = QtWidgets.QMenu(self.menuView)
        icon = QtGui.QIcon.fromTheme("window")
        self.menuWindows.setIcon(icon)
        self.menuWindows.setObjectName("menuWindows")
        self.menuCobol = QtWidgets.QMenu(self.menuBar)
        self.menuCobol.setObjectName("menuCobol")
        self.menuProgramType = QtWidgets.QMenu(self.menuCobol)
        self.menuProgramType.setObjectName("menuProgramType")
        self.menu = QtWidgets.QMenu(self.menuBar)
        self.menu.setObjectName("menu")
        MainWindow.setMenuBar(self.menuBar)
        self.dockWidgetNavPanel = QtWidgets.QDockWidget(MainWindow)
        self.dockWidgetNavPanel.setMinimumSize(QtCore.QSize(102, 168))
        self.dockWidgetNavPanel.setFeatures(QtWidgets.QDockWidget.AllDockWidgetFeatures)
        self.dockWidgetNavPanel.setObjectName("dockWidgetNavPanel")
        self.dockWidgetContents_2 = QtWidgets.QWidget()
        self.dockWidgetContents_2.setObjectName("dockWidgetContents_2")
        self.verticalLayout_6 = QtWidgets.QVBoxLayout(self.dockWidgetContents_2)
        self.verticalLayout_6.setContentsMargins(3, 3, 3, 3)
        self.verticalLayout_6.setSpacing(3)
        self.verticalLayout_6.setObjectName("verticalLayout_6")
        self.horizontalLayout_4 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_4.setContentsMargins(-1, 0, -1, -1)
        self.horizontalLayout_4.setSpacing(0)
        self.horizontalLayout_4.setObjectName("horizontalLayout_4")
        spacerItem10 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_4.addItem(spacerItem10)
        self.btNavLock = QtWidgets.QToolButton(self.dockWidgetContents_2)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.btNavLock.sizePolicy().hasHeightForWidth())
        self.btNavLock.setSizePolicy(sizePolicy)
        self.btNavLock.setText("")
        icon = QtGui.QIcon.fromTheme("system-lock-screen")
        self.btNavLock.setIcon(icon)
        self.btNavLock.setIconSize(QtCore.QSize(16, 16))
        self.btNavLock.setCheckable(True)
        self.btNavLock.setChecked(False)
        self.btNavLock.setObjectName("btNavLock")
        self.horizontalLayout_4.addWidget(self.btNavLock)
        self.verticalLayout_6.addLayout(self.horizontalLayout_4)
        self.twNavigation = OutlineTreeWidget(self.dockWidgetContents_2)
        self.twNavigation.setObjectName("twNavigation")
        self.twNavigation.headerItem().setText(0, "1")
        self.twNavigation.header().setVisible(False)
        self.verticalLayout_6.addWidget(self.twNavigation)
        self.dockWidgetNavPanel.setWidget(self.dockWidgetContents_2)
        MainWindow.addDockWidget(QtCore.Qt.DockWidgetArea(2), self.dockWidgetNavPanel)
        self.dockWidgetOffsets = QtWidgets.QDockWidget(MainWindow)
        self.dockWidgetOffsets.setMinimumSize(QtCore.QSize(310, 114))
        self.dockWidgetOffsets.setObjectName("dockWidgetOffsets")
        self.dockWidgetContents_3 = QtWidgets.QWidget()
        self.dockWidgetContents_3.setObjectName("dockWidgetContents_3")
        self.gridLayout_8 = QtWidgets.QGridLayout(self.dockWidgetContents_3)
        self.gridLayout_8.setContentsMargins(3, 3, 3, 3)
        self.gridLayout_8.setSpacing(3)
        self.gridLayout_8.setObjectName("gridLayout_8")
        self.tableWidgetOffsets = PicOffsetsTable(self.dockWidgetContents_3)
        self.tableWidgetOffsets.setMinimumSize(QtCore.QSize(300, 0))
        self.tableWidgetOffsets.setDragDropOverwriteMode(False)
        self.tableWidgetOffsets.setShowGrid(True)
        self.tableWidgetOffsets.setObjectName("tableWidgetOffsets")
        self.tableWidgetOffsets.setColumnCount(4)
        self.tableWidgetOffsets.setRowCount(0)
        item = QtWidgets.QTableWidgetItem()
        self.tableWidgetOffsets.setHorizontalHeaderItem(0, item)
        item = QtWidgets.QTableWidgetItem()
        self.tableWidgetOffsets.setHorizontalHeaderItem(1, item)
        item = QtWidgets.QTableWidgetItem()
        self.tableWidgetOffsets.setHorizontalHeaderItem(2, item)
        item = QtWidgets.QTableWidgetItem()
        self.tableWidgetOffsets.setHorizontalHeaderItem(3, item)
        self.tableWidgetOffsets.horizontalHeader().setDefaultSectionSize(50)
        self.tableWidgetOffsets.horizontalHeader().setSortIndicatorShown(True)
        self.tableWidgetOffsets.horizontalHeader().setStretchLastSection(True)
        self.tableWidgetOffsets.verticalHeader().setVisible(False)
        self.gridLayout_8.addWidget(self.tableWidgetOffsets, 0, 0, 1, 1)
        self.dockWidgetOffsets.setWidget(self.dockWidgetContents_3)
        MainWindow.addDockWidget(QtCore.Qt.DockWidgetArea(2), self.dockWidgetOffsets)
        self.dockWidgetFileSystem = QtWidgets.QDockWidget(MainWindow)
        self.dockWidgetFileSystem.setMinimumSize(QtCore.QSize(96, 151))
        self.dockWidgetFileSystem.setObjectName("dockWidgetFileSystem")
        self.dockWidgetContents_4 = QtWidgets.QWidget()
        self.dockWidgetContents_4.setObjectName("dockWidgetContents_4")
        self.verticalLayout = QtWidgets.QVBoxLayout(self.dockWidgetContents_4)
        self.verticalLayout.setContentsMargins(3, 3, 3, 3)
        self.verticalLayout.setSpacing(3)
        self.verticalLayout.setObjectName("verticalLayout")
        self.horizontalLayout_2 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_2.setContentsMargins(-1, 0, -1, -1)
        self.horizontalLayout_2.setSpacing(6)
        self.horizontalLayout_2.setObjectName("horizontalLayout_2")
        spacerItem11 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout_2.addItem(spacerItem11)
        self.bt_fs_up = QtWidgets.QToolButton(self.dockWidgetContents_4)
        icon = QtGui.QIcon.fromTheme("go-up")
        self.bt_fs_up.setIcon(icon)
        self.bt_fs_up.setObjectName("bt_fs_up")
        self.horizontalLayout_2.addWidget(self.bt_fs_up)
        self.btFSLock = QtWidgets.QToolButton(self.dockWidgetContents_4)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.btFSLock.sizePolicy().hasHeightForWidth())
        self.btFSLock.setSizePolicy(sizePolicy)
        self.btFSLock.setText("")
        icon = QtGui.QIcon.fromTheme("system-lock-screen")
        self.btFSLock.setIcon(icon)
        self.btFSLock.setIconSize(QtCore.QSize(16, 16))
        self.btFSLock.setCheckable(True)
        self.btFSLock.setChecked(False)
        self.btFSLock.setObjectName("btFSLock")
        self.horizontalLayout_2.addWidget(self.btFSLock)
        self.verticalLayout.addLayout(self.horizontalLayout_2)
        self.tvFileSystem = FileSystemTreeView(self.dockWidgetContents_4)
        self.tvFileSystem.setObjectName("tvFileSystem")
        self.verticalLayout.addWidget(self.tvFileSystem)
        self.dockWidgetFileSystem.setWidget(self.dockWidgetContents_4)
        MainWindow.addDockWidget(QtCore.Qt.DockWidgetArea(1), self.dockWidgetFileSystem)
        self.actionQuit = QtWidgets.QAction(MainWindow)
        self.actionQuit.setIconVisibleInMenu(True)
        self.actionQuit.setObjectName("actionQuit")
        self.actionRun = QtWidgets.QAction(MainWindow)
        self.actionRun.setIconVisibleInMenu(True)
        self.actionRun.setObjectName("actionRun")
        self.actionAbout = QtWidgets.QAction(MainWindow)
        self.actionAbout.setIconVisibleInMenu(True)
        self.actionAbout.setObjectName("actionAbout")
        self.actionSave = QtWidgets.QAction(MainWindow)
        self.actionSave.setIconVisibleInMenu(True)
        self.actionSave.setObjectName("actionSave")
        self.actionSaveAs = QtWidgets.QAction(MainWindow)
        self.actionSaveAs.setIconVisibleInMenu(True)
        self.actionSaveAs.setObjectName("actionSaveAs")
        self.actionFullscreen = QtWidgets.QAction(MainWindow)
        self.actionFullscreen.setCheckable(True)
        self.actionFullscreen.setIconVisibleInMenu(True)
        self.actionFullscreen.setObjectName("actionFullscreen")
        self.actionNew = QtWidgets.QAction(MainWindow)
        self.actionNew.setIconVisibleInMenu(True)
        self.actionNew.setObjectName("actionNew")
        self.actionOpen = QtWidgets.QAction(MainWindow)
        self.actionOpen.setIconVisibleInMenu(True)
        self.actionOpen.setObjectName("actionOpen")
        self.actionClear = QtWidgets.QAction(MainWindow)
        self.actionClear.setIconVisibleInMenu(True)
        self.actionClear.setObjectName("actionClear")
        self.actionPreferences = QtWidgets.QAction(MainWindow)
        self.actionPreferences.setIconVisibleInMenu(True)
        self.actionPreferences.setObjectName("actionPreferences")
        self.actionHelp = QtWidgets.QAction(MainWindow)
        self.actionHelp.setIconVisibleInMenu(True)
        self.actionHelp.setObjectName("actionHelp")
        self.actionProgram = QtWidgets.QAction(MainWindow)
        self.actionProgram.setCheckable(True)
        self.actionProgram.setChecked(True)
        self.actionProgram.setObjectName("actionProgram")
        self.actionSubprogram = QtWidgets.QAction(MainWindow)
        self.actionSubprogram.setCheckable(True)
        self.actionSubprogram.setObjectName("actionSubprogram")
        self.actionCompile = QtWidgets.QAction(MainWindow)
        self.actionCompile.setIconVisibleInMenu(True)
        self.actionCompile.setObjectName("actionCompile")
        self.actionCancel = QtWidgets.QAction(MainWindow)
        self.actionCancel.setObjectName("actionCancel")
        self.actionReport_a_bug = QtWidgets.QAction(MainWindow)
        icon = QtGui.QIcon.fromTheme("tools-report-bug")
        self.actionReport_a_bug.setIcon(icon)
        self.actionReport_a_bug.setObjectName("actionReport_a_bug")
        self.actionRestore_factory_defaults = QtWidgets.QAction(MainWindow)
        self.actionRestore_factory_defaults.setObjectName("actionRestore_factory_defaults")
        self.actionExport_preferences = QtWidgets.QAction(MainWindow)
        icon = QtGui.QIcon.fromTheme("document-export")
        self.actionExport_preferences.setIcon(icon)
        self.actionExport_preferences.setObjectName("actionExport_preferences")
        self.actionImport_preferences = QtWidgets.QAction(MainWindow)
        icon = QtGui.QIcon.fromTheme("document-import")
        self.actionImport_preferences.setIcon(icon)
        self.actionImport_preferences.setObjectName("actionImport_preferences")
        self.actionClean = QtWidgets.QAction(MainWindow)
        self.actionClean.setObjectName("actionClean")
        self.actionRebuild = QtWidgets.QAction(MainWindow)
        self.actionRebuild.setObjectName("actionRebuild")
        self.actionEnableLinter = QtWidgets.QAction(MainWindow)
        self.actionEnableLinter.setCheckable(True)
        self.actionEnableLinter.setChecked(True)
        icon = QtGui.QIcon.fromTheme("dialog-error")
        self.actionEnableLinter.setIcon(icon)
        self.actionEnableLinter.setObjectName("actionEnableLinter")
        self.dockWidgetNavPanel.raise_()
        self.toolBarFile.addAction(self.actionNew)
        self.toolBarFile.addAction(self.actionOpen)
        self.toolBarFile.addSeparator()
        self.toolBarFile.addAction(self.actionSave)
        self.toolBarFile.addAction(self.actionSaveAs)
        self.toolBarCOBOL.addAction(self.actionClean)
        self.toolBarCOBOL.addAction(self.actionRebuild)
        self.toolBarCOBOL.addAction(self.actionRun)
        self.menuFile.addAction(self.actionNew)
        self.menuFile.addAction(self.actionOpen)
        self.menuFile.addSeparator()
        self.menuFile.addAction(self.actionSave)
        self.menuFile.addAction(self.actionSaveAs)
        self.menuFile.addSeparator()
        self.menuFile.addAction(self.actionImport_preferences)
        self.menuFile.addAction(self.actionExport_preferences)
        self.menuFile.addSeparator()
        self.menuFile.addAction(self.actionQuit)
        self.mnuActiveEditor.addSeparator()
        self.menuEdit.addAction(self.mnuActiveEditor.menuAction())
        self.menuEdit.addSeparator()
        self.menuEdit.addAction(self.actionPreferences)
        self.menuView.addAction(self.menuWindows.menuAction())
        self.menuView.addSeparator()
        self.menuView.addAction(self.actionFullscreen)
        self.menuProgramType.addAction(self.actionProgram)
        self.menuProgramType.addAction(self.actionSubprogram)
        self.menuCobol.addAction(self.menuProgramType.menuAction())
        self.menuCobol.addSeparator()
        self.menuCobol.addAction(self.actionCompile)
        self.menuCobol.addAction(self.actionClean)
        self.menuCobol.addAction(self.actionRebuild)
        self.menuCobol.addAction(self.actionRun)
        self.menuCobol.addSeparator()
        self.menuCobol.addAction(self.actionCancel)
        self.menu.addAction(self.actionHelp)
        self.menu.addAction(self.actionAbout)
        self.menu.addSeparator()
        self.menu.addAction(self.actionReport_a_bug)
        self.menu.addSeparator()
        self.menu.addAction(self.actionRestore_factory_defaults)
        self.menuBar.addAction(self.menuFile.menuAction())
        self.menuBar.addAction(self.menuEdit.menuAction())
        self.menuBar.addAction(self.menuView.menuAction())
        self.menuBar.addAction(self.menuCobol.menuAction())
        self.menuBar.addAction(self.menu.menuAction())

        self.retranslateUi(MainWindow)
        self.stackedWidget.setCurrentIndex(1)
        self.tabWidgetLogs.setCurrentIndex(2)
        QtCore.QMetaObject.connectSlotsByName(MainWindow)
Example #13
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)