本文整理汇总了Python中pyqtgraph.GraphicsLayoutWidget.setFrameShape方法的典型用法代码示例。如果您正苦于以下问题:Python GraphicsLayoutWidget.setFrameShape方法的具体用法?Python GraphicsLayoutWidget.setFrameShape怎么用?Python GraphicsLayoutWidget.setFrameShape使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类pyqtgraph.GraphicsLayoutWidget
的用法示例。
在下文中一共展示了GraphicsLayoutWidget.setFrameShape方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: Ui_MainWindow
# 需要导入模块: from pyqtgraph import GraphicsLayoutWidget [as 别名]
# 或者: from pyqtgraph.GraphicsLayoutWidget import setFrameShape [as 别名]
#.........这里部分代码省略.........
"}\n"
"\n"
"QSlider::handle {\n"
" border: 1px solid #757575;\n"
" background: #424242;\n"
"}\n"
"\n"
"QSlider::handle:horizontal {\n"
" width: 15px;\n"
" margin: -4px 0px -4px 0px;\n"
"}\n"
"\n"
"QSlider::handle:vertical {\n"
" height: 15px;\n"
" margin: 0px -4px 0px -4px;\n"
"}\n"
"\n"
"QSlider::add-page:vertical, QSlider::sub-page:horizontal {\n"
" background: #3F51B5;\n"
"}\n"
"\n"
"QSlider::sub-page:vertical, QSlider::add-page:horizontal {\n"
" background: #424242;\n"
"}\n"
"\n"
"QLabel {\n"
" border: none;\n"
"}\n"
"\n"
"QProgressBar {\n"
" text-align: center;\n"
"}\n"
"\n"
"QProgressBar::chunk {\n"
" width: 1px;\n"
" background-color: #3F51B5;\n"
"}\n"
"\n"
"QMenu::separator {\n"
" background: #424242;\n"
"}\n"
"\n"
"QStatusBar {\n"
" border: 1px;\n"
" color: #3F51B5;\n"
"}"))
MainWindow.setTabShape(QtGui.QTabWidget.Rounded)
self.centralwidget = QtGui.QWidget(MainWindow)
self.centralwidget.setObjectName(_fromUtf8("centralwidget"))
self.gridLayout = QtGui.QGridLayout(self.centralwidget)
self.gridLayout.setObjectName(_fromUtf8("gridLayout"))
self.Layout_controls2 = QtGui.QGridLayout()
self.Layout_controls2.setObjectName(_fromUtf8("Layout_controls2"))
spacerItem = QtGui.QSpacerItem(40, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
self.Layout_controls2.addItem(spacerItem, 0, 1, 1, 1)
self.chBox_export = QtGui.QCheckBox(self.centralwidget)
self.chBox_export.setObjectName(_fromUtf8("chBox_export"))
self.Layout_controls2.addWidget(self.chBox_export, 0, 0, 1, 1)
self.gridLayout.addLayout(self.Layout_controls2, 9, 1, 1, 1)
self.Layout_controls = QtGui.QGridLayout()
self.Layout_controls.setObjectName(_fromUtf8("Layout_controls"))
self.cBox_Speed = QtGui.QComboBox(self.centralwidget)
self.cBox_Speed.setObjectName(_fromUtf8("cBox_Speed"))
self.Layout_controls.addWidget(self.cBox_Speed, 0, 1, 1, 1)
self.cBox_Port = QtGui.QComboBox(self.centralwidget)
self.cBox_Port.setObjectName(_fromUtf8("cBox_Port"))
self.Layout_controls.addWidget(self.cBox_Port, 0, 0, 1, 1)
self.pButton_Start = QtGui.QPushButton(self.centralwidget)
self.pButton_Start.setMinimumSize(QtCore.QSize(0, 0))
self.pButton_Start.setObjectName(_fromUtf8("pButton_Start"))
self.Layout_controls.addWidget(self.pButton_Start, 1, 0, 1, 1)
self.pButton_Stop = QtGui.QPushButton(self.centralwidget)
self.pButton_Stop.setObjectName(_fromUtf8("pButton_Stop"))
self.Layout_controls.addWidget(self.pButton_Stop, 1, 1, 1, 1)
self.gridLayout.addLayout(self.Layout_controls, 7, 0, 1, 2)
self.Layout_graphs = QtGui.QGridLayout()
self.Layout_graphs.setObjectName(_fromUtf8("Layout_graphs"))
self.plt = GraphicsLayoutWidget(self.centralwidget)
self.plt.setAutoFillBackground(False)
self.plt.setStyleSheet(_fromUtf8("border: 0px;"))
self.plt.setFrameShape(QtGui.QFrame.StyledPanel)
self.plt.setFrameShadow(QtGui.QFrame.Plain)
self.plt.setLineWidth(0)
self.plt.setObjectName(_fromUtf8("plt"))
self.Layout_graphs.addWidget(self.plt, 0, 0, 1, 1)
self.gridLayout.addLayout(self.Layout_graphs, 2, 1, 1, 1)
MainWindow.setCentralWidget(self.centralwidget)
self.statusbar = QtGui.QStatusBar(MainWindow)
self.statusbar.setSizeGripEnabled(False)
self.statusbar.setObjectName(_fromUtf8("statusbar"))
MainWindow.setStatusBar(self.statusbar)
self.retranslateUi(MainWindow)
QtCore.QMetaObject.connectSlotsByName(MainWindow)
def retranslateUi(self, MainWindow):
MainWindow.setWindowTitle(_translate("MainWindow", "RTGraph", None))
self.chBox_export.setText(_translate("MainWindow", "Export to CSV", None))
self.pButton_Start.setText(_translate("MainWindow", "Start", None))
self.pButton_Stop.setText(_translate("MainWindow", "Stop", None))
示例2: Ui_MainWindow
# 需要导入模块: from pyqtgraph import GraphicsLayoutWidget [as 别名]
# 或者: from pyqtgraph.GraphicsLayoutWidget import setFrameShape [as 别名]
class Ui_MainWindow(object):
def setupUi(self, MainWindow):
MainWindow.setObjectName("MainWindow")
MainWindow.resize(1118, 728)
MainWindow.setMinimumSize(QtCore.QSize(256, 256))
MainWindow.setMaximumSize(QtCore.QSize(1118, 16777215))
self.centralwidget = QtWidgets.QWidget(MainWindow)
self.centralwidget.setObjectName("centralwidget")
self.histogram_groupBox_2 = QtWidgets.QGroupBox(self.centralwidget)
self.histogram_groupBox_2.setGeometry(QtCore.QRect(440, 520, 671, 171))
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.histogram_groupBox_2.sizePolicy().hasHeightForWidth())
self.histogram_groupBox_2.setSizePolicy(sizePolicy)
self.histogram_groupBox_2.setMinimumSize(QtCore.QSize(100, 100))
self.histogram_groupBox_2.setMaximumSize(QtCore.QSize(700, 283))
self.histogram_groupBox_2.setObjectName("histogram_groupBox_2")
self.logOutput = QtWidgets.QTextEdit(self.histogram_groupBox_2)
self.logOutput.setGeometry(QtCore.QRect(10, 30, 651, 131))
font = QtGui.QFont()
font.setFamily("Courier")
self.logOutput.setFont(font)
self.logOutput.setObjectName("logOutput")
self.imageData_groupBox = QtWidgets.QGroupBox(self.centralwidget)
self.imageData_groupBox.setGeometry(QtCore.QRect(10, 0, 1100, 312))
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.MinimumExpanding, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.imageData_groupBox.sizePolicy().hasHeightForWidth())
self.imageData_groupBox.setSizePolicy(sizePolicy)
self.imageData_groupBox.setMinimumSize(QtCore.QSize(1100, 100))
self.imageData_groupBox.setMaximumSize(QtCore.QSize(1100, 312))
self.imageData_groupBox.setObjectName("imageData_groupBox")
self.label = QtWidgets.QLabel(self.imageData_groupBox)
self.label.setGeometry(QtCore.QRect(10, 520, 521, 16))
self.label.setWordWrap(True)
self.label.setObjectName("label")
self.layoutWidget = QtWidgets.QWidget(self.imageData_groupBox)
self.layoutWidget.setGeometry(QtCore.QRect(10, 20, 1091, 291))
self.layoutWidget.setObjectName("layoutWidget")
self.largeimage_horizontalLayout = QtWidgets.QHBoxLayout(self.layoutWidget)
self.largeimage_horizontalLayout.setSizeConstraint(QtWidgets.QLayout.SetMinAndMaxSize)
self.largeimage_horizontalLayout.setContentsMargins(0, 0, 0, 0)
self.largeimage_horizontalLayout.setObjectName("largeimage_horizontalLayout")
self.main_graphicsView = GraphicsLayoutWidget(self.layoutWidget)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.MinimumExpanding, QtWidgets.QSizePolicy.MinimumExpanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.main_graphicsView.sizePolicy().hasHeightForWidth())
self.main_graphicsView.setSizePolicy(sizePolicy)
self.main_graphicsView.setMinimumSize(QtCore.QSize(778, 256))
self.main_graphicsView.setMaximumSize(QtCore.QSize(778, 256))
self.main_graphicsView.setSizeIncrement(QtCore.QSize(1, 1))
self.main_graphicsView.setFrameShape(QtWidgets.QFrame.NoFrame)
self.main_graphicsView.setAlignment(QtCore.Qt.AlignCenter)
self.main_graphicsView.setObjectName("main_graphicsView")
self.largeimage_horizontalLayout.addWidget(self.main_graphicsView)
self.graphicsView_colorbar = GraphicsView(self.layoutWidget)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.MinimumExpanding, QtWidgets.QSizePolicy.MinimumExpanding)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.graphicsView_colorbar.sizePolicy().hasHeightForWidth())
self.graphicsView_colorbar.setSizePolicy(sizePolicy)
self.graphicsView_colorbar.setMinimumSize(QtCore.QSize(30, 128))
self.graphicsView_colorbar.setMaximumSize(QtCore.QSize(25, 256))
self.graphicsView_colorbar.setSizeIncrement(QtCore.QSize(1, 1))
self.graphicsView_colorbar.setObjectName("graphicsView_colorbar")
self.largeimage_horizontalLayout.addWidget(self.graphicsView_colorbar)
self.verticalLayout_3 = QtWidgets.QVBoxLayout()
self.verticalLayout_3.setSizeConstraint(QtWidgets.QLayout.SetMaximumSize)
self.verticalLayout_3.setContentsMargins(-1, 5, -1, 5)
self.verticalLayout_3.setSpacing(0)
self.verticalLayout_3.setObjectName("verticalLayout_3")
self.dispmax_doubleSpinBox = QtWidgets.QDoubleSpinBox(self.layoutWidget)
self.dispmax_doubleSpinBox.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.dispmax_doubleSpinBox.setDecimals(3)
self.dispmax_doubleSpinBox.setObjectName("dispmax_doubleSpinBox")
self.verticalLayout_3.addWidget(self.dispmax_doubleSpinBox)
spacerItem = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
self.verticalLayout_3.addItem(spacerItem)
self.resetDispLimits_Button = QtWidgets.QPushButton(self.layoutWidget)
self.resetDispLimits_Button.setObjectName("resetDispLimits_Button")
self.verticalLayout_3.addWidget(self.resetDispLimits_Button)
self.resetDispSmart_Button = QtWidgets.QPushButton(self.layoutWidget)
self.resetDispSmart_Button.setObjectName("resetDispSmart_Button")
self.verticalLayout_3.addWidget(self.resetDispSmart_Button)
self.saveDisp_Button = QtWidgets.QPushButton(self.layoutWidget)
self.saveDisp_Button.setObjectName("saveDisp_Button")
self.verticalLayout_3.addWidget(self.saveDisp_Button)
self.setMask_Button = QtWidgets.QPushButton(self.layoutWidget)
self.setMask_Button.setObjectName("setMask_Button")
self.verticalLayout_3.addWidget(self.setMask_Button)
spacerItem1 = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
self.verticalLayout_3.addItem(spacerItem1)
self.dispmin_doubleSpinBox = QtWidgets.QDoubleSpinBox(self.layoutWidget)
self.dispmin_doubleSpinBox.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.dispmin_doubleSpinBox.setDecimals(3)
self.dispmin_doubleSpinBox.setObjectName("dispmin_doubleSpinBox")
self.verticalLayout_3.addWidget(self.dispmin_doubleSpinBox)
#.........这里部分代码省略.........