當前位置: 首頁>>代碼示例>>Python>>正文


Python GraphicsLayoutWidget.setAutoFillBackground方法代碼示例

本文整理匯總了Python中pyqtgraph.GraphicsLayoutWidget.setAutoFillBackground方法的典型用法代碼示例。如果您正苦於以下問題:Python GraphicsLayoutWidget.setAutoFillBackground方法的具體用法?Python GraphicsLayoutWidget.setAutoFillBackground怎麽用?Python GraphicsLayoutWidget.setAutoFillBackground使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在pyqtgraph.GraphicsLayoutWidget的用法示例。


在下文中一共展示了GraphicsLayoutWidget.setAutoFillBackground方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: Ui_MainWindow

# 需要導入模塊: from pyqtgraph import GraphicsLayoutWidget [as 別名]
# 或者: from pyqtgraph.GraphicsLayoutWidget import setAutoFillBackground [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))
開發者ID:sgds23,項目名稱:RTGraph,代碼行數:104,代碼來源:gui.py


注:本文中的pyqtgraph.GraphicsLayoutWidget.setAutoFillBackground方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。