2015-01-17 10:45:32 +00:00
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
|
2021-06-27 00:51:34 +00:00
|
|
|
# Form implementation generated from reading ui file 'examples/exampleLoaderTemplate.ui'
|
2015-01-17 10:45:32 +00:00
|
|
|
#
|
2021-06-27 00:51:34 +00:00
|
|
|
# Created by: PyQt5 UI code generator 5.15.4
|
2015-01-17 10:45:32 +00:00
|
|
|
#
|
2021-06-27 00:51:34 +00:00
|
|
|
# WARNING: Any manual changes made to this file will be lost when pyuic5 is
|
|
|
|
# run again. Do not edit this file unless you know what you are doing.
|
2020-10-19 18:51:12 +00:00
|
|
|
|
2015-01-17 10:45:32 +00:00
|
|
|
|
|
|
|
from PyQt5 import QtCore, QtGui, QtWidgets
|
|
|
|
|
2020-10-19 18:51:12 +00:00
|
|
|
|
2015-01-17 10:45:32 +00:00
|
|
|
class Ui_Form(object):
|
|
|
|
def setupUi(self, Form):
|
2015-02-28 14:38:38 +00:00
|
|
|
Form.setObjectName("Form")
|
2015-02-28 15:32:34 +00:00
|
|
|
Form.resize(846, 552)
|
|
|
|
self.gridLayout_2 = QtWidgets.QGridLayout(Form)
|
|
|
|
self.gridLayout_2.setObjectName("gridLayout_2")
|
2015-02-28 14:38:38 +00:00
|
|
|
self.splitter = QtWidgets.QSplitter(Form)
|
2015-01-17 10:45:32 +00:00
|
|
|
self.splitter.setOrientation(QtCore.Qt.Horizontal)
|
2015-02-28 14:38:38 +00:00
|
|
|
self.splitter.setObjectName("splitter")
|
2021-06-27 00:51:34 +00:00
|
|
|
self.layoutWidget = QtWidgets.QWidget(self.splitter)
|
|
|
|
self.layoutWidget.setObjectName("layoutWidget")
|
|
|
|
self.gridLayout = QtWidgets.QGridLayout(self.layoutWidget)
|
2015-02-28 15:32:34 +00:00
|
|
|
self.gridLayout.setContentsMargins(0, 0, 0, 0)
|
|
|
|
self.gridLayout.setObjectName("gridLayout")
|
2021-06-27 00:51:34 +00:00
|
|
|
self.qtLibCombo = QtWidgets.QComboBox(self.layoutWidget)
|
2015-02-28 15:32:34 +00:00
|
|
|
self.qtLibCombo.setObjectName("qtLibCombo")
|
|
|
|
self.qtLibCombo.addItem("")
|
|
|
|
self.qtLibCombo.addItem("")
|
|
|
|
self.qtLibCombo.addItem("")
|
|
|
|
self.qtLibCombo.addItem("")
|
2018-02-17 04:42:34 +00:00
|
|
|
self.qtLibCombo.addItem("")
|
2021-06-27 00:51:34 +00:00
|
|
|
self.gridLayout.addWidget(self.qtLibCombo, 4, 1, 1, 1)
|
|
|
|
self.loadBtn = QtWidgets.QPushButton(self.layoutWidget)
|
2015-02-28 14:38:38 +00:00
|
|
|
self.loadBtn.setObjectName("loadBtn")
|
2021-06-27 00:51:34 +00:00
|
|
|
self.gridLayout.addWidget(self.loadBtn, 6, 1, 1, 1)
|
|
|
|
self.exampleTree = QtWidgets.QTreeWidget(self.layoutWidget)
|
|
|
|
self.exampleTree.setObjectName("exampleTree")
|
|
|
|
self.exampleTree.headerItem().setText(0, "1")
|
|
|
|
self.exampleTree.header().setVisible(False)
|
|
|
|
self.gridLayout.addWidget(self.exampleTree, 3, 0, 1, 2)
|
|
|
|
self.label = QtWidgets.QLabel(self.layoutWidget)
|
|
|
|
self.label.setObjectName("label")
|
|
|
|
self.gridLayout.addWidget(self.label, 4, 0, 1, 1)
|
|
|
|
self.exampleFilter = QtWidgets.QLineEdit(self.layoutWidget)
|
|
|
|
self.exampleFilter.setObjectName("exampleFilter")
|
|
|
|
self.gridLayout.addWidget(self.exampleFilter, 0, 0, 1, 2)
|
|
|
|
self.searchFiles = QtWidgets.QComboBox(self.layoutWidget)
|
|
|
|
self.searchFiles.setObjectName("searchFiles")
|
|
|
|
self.searchFiles.addItem("")
|
|
|
|
self.searchFiles.addItem("")
|
|
|
|
self.gridLayout.addWidget(self.searchFiles, 1, 0, 1, 2)
|
|
|
|
self.layoutWidget1 = QtWidgets.QWidget(self.splitter)
|
|
|
|
self.layoutWidget1.setObjectName("layoutWidget1")
|
|
|
|
self.verticalLayout = QtWidgets.QVBoxLayout(self.layoutWidget1)
|
2015-02-28 15:32:34 +00:00
|
|
|
self.verticalLayout.setContentsMargins(0, 0, 0, 0)
|
|
|
|
self.verticalLayout.setObjectName("verticalLayout")
|
2021-06-27 00:51:34 +00:00
|
|
|
self.loadedFileLabel = QtWidgets.QLabel(self.layoutWidget1)
|
2015-01-17 10:45:32 +00:00
|
|
|
font = QtGui.QFont()
|
|
|
|
font.setBold(True)
|
|
|
|
self.loadedFileLabel.setFont(font)
|
2015-02-28 14:38:38 +00:00
|
|
|
self.loadedFileLabel.setText("")
|
2015-01-17 10:45:32 +00:00
|
|
|
self.loadedFileLabel.setAlignment(QtCore.Qt.AlignCenter)
|
2015-02-28 14:38:38 +00:00
|
|
|
self.loadedFileLabel.setObjectName("loadedFileLabel")
|
2015-02-28 15:32:34 +00:00
|
|
|
self.verticalLayout.addWidget(self.loadedFileLabel)
|
2021-06-27 00:51:34 +00:00
|
|
|
self.codeView = QtWidgets.QPlainTextEdit(self.layoutWidget1)
|
2015-01-17 10:45:32 +00:00
|
|
|
font = QtGui.QFont()
|
2020-10-19 18:51:12 +00:00
|
|
|
font.setFamily("Courier New")
|
2015-01-17 10:45:32 +00:00
|
|
|
self.codeView.setFont(font)
|
2015-02-28 14:38:38 +00:00
|
|
|
self.codeView.setObjectName("codeView")
|
2015-02-28 15:32:34 +00:00
|
|
|
self.verticalLayout.addWidget(self.codeView)
|
2021-06-27 00:51:34 +00:00
|
|
|
self.gridLayout_2.addWidget(self.splitter, 1, 0, 1, 1)
|
2015-01-17 10:45:32 +00:00
|
|
|
|
|
|
|
self.retranslateUi(Form)
|
|
|
|
QtCore.QMetaObject.connectSlotsByName(Form)
|
|
|
|
|
|
|
|
def retranslateUi(self, Form):
|
2015-02-28 14:38:38 +00:00
|
|
|
_translate = QtCore.QCoreApplication.translate
|
Patch/window handling (#468)
* Do not wrap PlotView/ImageView
There is no need to wrap PlotView/ImageView into QMainWindow, since
only purpose of the QMainWindow is some default menu toolbar & menu
handling, that is not used by PyQtGraph anyway.
Moreover, every parent-less Qt widget can become window, so this
change just use PlotView/ImageView as windows, removing extra
complexity, eg. method forwarding, self.win property.
Another benefit of this change, it that these windows get initial
dimensions and titles as they were designed in .ui file.
* Properly cleanup on ImageView.close()
We should not close explicitly child widgets or clear scene, otherwise
Qt will deallocate children views, and cause "wrapped C/C++ object of
type ImageItem has been deleted" error next time we call close()
and/or some other methods.
All children, including self.ui.roiPlot, self.ui.graphicsView will be
closed together with its parent, so there is no need to close them
explicitly.
So the purpose of close it to reclaim the memory, but not to make the existing ImageView object dysfunctional.
* Remove references to plot & image windows after close
PyQtGraph images and plots module list variables are currently holding
references to all plots and image windows returned directly from main
module. This does not seem to be documented however, and causes the Qt
windows to be not released from memory, even if user releases all own
references.
This change removes the references from images/plots list once window
is closed, so when there is no other reference, window and all related
memory is reclaimed.
* Change all UI forms title from Form to PyQtGraph
Co-authored-by: Ogi Moore <ognyan.moore@gmail.com>
2020-06-01 18:23:18 +00:00
|
|
|
Form.setWindowTitle(_translate("Form", "PyQtGraph"))
|
2015-02-28 15:32:34 +00:00
|
|
|
self.qtLibCombo.setItemText(0, _translate("Form", "default"))
|
2021-01-23 02:39:54 +00:00
|
|
|
self.qtLibCombo.setItemText(1, _translate("Form", "PyQt5"))
|
|
|
|
self.qtLibCombo.setItemText(2, _translate("Form", "PySide2"))
|
|
|
|
self.qtLibCombo.setItemText(3, _translate("Form", "PySide6"))
|
|
|
|
self.qtLibCombo.setItemText(4, _translate("Form", "PyQt6"))
|
2015-02-28 14:38:38 +00:00
|
|
|
self.loadBtn.setText(_translate("Form", "Run Example"))
|
2021-06-27 00:51:34 +00:00
|
|
|
self.label.setText(_translate("Form", "Qt Library:"))
|
|
|
|
self.exampleFilter.setPlaceholderText(_translate("Form", "Type to filter..."))
|
|
|
|
self.searchFiles.setItemText(0, _translate("Form", "Title Search"))
|
|
|
|
self.searchFiles.setItemText(1, _translate("Form", "Content Search"))
|