GenericoW.py 16.7 KB
Newer Older
1 2 3 4
# -*- coding: utf-8 -*-

# Form implementation generated from reading ui file 'resources/UI/Generico.ui'
#
5
# Created by: PyQt5 UI code generator 5.14.0
6 7 8
#
# WARNING! All changes made in this file will be lost!

9

10 11
from PyQt5 import QtCore, QtGui, QtWidgets

12

13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86
class Ui_Generico(object):
    def setupUi(self, Generico):
        Generico.setObjectName("Generico")
        Generico.resize(1366, 823)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(Generico.sizePolicy().hasHeightForWidth())
        Generico.setSizePolicy(sizePolicy)
        Generico.setMinimumSize(QtCore.QSize(0, 0))
        Generico.setStyleSheet("background-color:rgb(250, 250, 250);\n"
"\n"
"\n"
"")
        self.centralWidget = QtWidgets.QWidget(Generico)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.centralWidget.sizePolicy().hasHeightForWidth())
        self.centralWidget.setSizePolicy(sizePolicy)
        self.centralWidget.setAutoFillBackground(False)
        self.centralWidget.setStyleSheet("QGroupBox::title {\n"
"    top: 4px;\n"
"    left: 4px;\n"
"}\n"
"\n"
"QGroupBox {\n"
"    border-radius: 4px;\n"
"    background-color: rgb(240, 240, 240);\n"
"    font-weight: bold;\n"
"}")
        self.centralWidget.setObjectName("centralWidget")
        self.gridLayout_6 = QtWidgets.QGridLayout(self.centralWidget)
        self.gridLayout_6.setContentsMargins(11, 11, 11, 11)
        self.gridLayout_6.setSpacing(6)
        self.gridLayout_6.setObjectName("gridLayout_6")
        self.widget = QtWidgets.QWidget(self.centralWidget)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.widget.sizePolicy().hasHeightForWidth())
        self.widget.setSizePolicy(sizePolicy)
        self.widget.setStyleSheet("")
        self.widget.setObjectName("widget")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.widget)
        self.gridLayout_2.setContentsMargins(11, 11, 11, 11)
        self.gridLayout_2.setSpacing(6)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.mainGraph = GraphicsLayoutWidget(self.widget)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.mainGraph.sizePolicy().hasHeightForWidth())
        self.mainGraph.setSizePolicy(sizePolicy)
        self.mainGraph.setStyleSheet("border: 2px solid rgb(10, 10, 10);\n"
"")
        self.mainGraph.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
        self.mainGraph.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
        self.mainGraph.setObjectName("mainGraph")
        self.gridLayout_2.addWidget(self.mainGraph, 0, 0, 3, 5)
        self.absValGBox = QtWidgets.QGroupBox(self.widget)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.absValGBox.sizePolicy().hasHeightForWidth())
        self.absValGBox.setSizePolicy(sizePolicy)
        font = QtGui.QFont()
        font.setBold(True)
        font.setWeight(75)
        self.absValGBox.setFont(font)
        self.absValGBox.setStyleSheet("border: 2px solid rgb(26, 149, 172);\n"
"")
        self.absValGBox.setObjectName("absValGBox")
        self.verticalLayout = QtWidgets.QVBoxLayout(self.absValGBox)
87
        self.verticalLayout.setContentsMargins(11, 25, 11, 11)
88 89 90 91 92 93 94 95
        self.verticalLayout.setSpacing(6)
        self.verticalLayout.setObjectName("verticalLayout")
        self.calibratorGBox = QtWidgets.QGroupBox(self.absValGBox)
        self.calibratorGBox.setStyleSheet("")
        self.calibratorGBox.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing)
        self.calibratorGBox.setFlat(True)
        self.calibratorGBox.setObjectName("calibratorGBox")
        self.horizontalLayout = QtWidgets.QHBoxLayout(self.calibratorGBox)
96
        self.horizontalLayout.setContentsMargins(11, 21, 11, 11)
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113
        self.horizontalLayout.setSpacing(6)
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.calibratorLabel = QtWidgets.QLabel(self.calibratorGBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.MinimumExpanding, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.calibratorLabel.sizePolicy().hasHeightForWidth())
        self.calibratorLabel.setSizePolicy(sizePolicy)
        self.calibratorLabel.setMinimumSize(QtCore.QSize(150, 0))
        self.calibratorLabel.setStyleSheet("")
        self.calibratorLabel.setObjectName("calibratorLabel")
        self.horizontalLayout.addWidget(self.calibratorLabel, 0, QtCore.Qt.AlignRight)
        self.verticalLayout.addWidget(self.calibratorGBox)
        self.forceGBox = QtWidgets.QGroupBox(self.absValGBox)
        self.forceGBox.setStyleSheet("")
        self.forceGBox.setObjectName("forceGBox")
        self.horizontalLayout_2 = QtWidgets.QHBoxLayout(self.forceGBox)
114
        self.horizontalLayout_2.setContentsMargins(11, 21, 11, 11)
115 116 117 118 119 120 121 122 123 124 125 126 127
        self.horizontalLayout_2.setSpacing(6)
        self.horizontalLayout_2.setObjectName("horizontalLayout_2")
        self.forceLabel = QtWidgets.QLabel(self.forceGBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.MinimumExpanding, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.forceLabel.sizePolicy().hasHeightForWidth())
        self.forceLabel.setSizePolicy(sizePolicy)
        self.forceLabel.setMinimumSize(QtCore.QSize(150, 0))
        self.forceLabel.setStyleSheet("")
        self.forceLabel.setObjectName("forceLabel")
        self.horizontalLayout_2.addWidget(self.forceLabel, 0, QtCore.Qt.AlignRight)
        self.verticalLayout.addWidget(self.forceGBox)
128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234
        self.gridLayout_2.addWidget(self.absValGBox, 3, 0, 1, 1)
        self.samplingBox = QtWidgets.QGroupBox(self.widget)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.samplingBox.sizePolicy().hasHeightForWidth())
        self.samplingBox.setSizePolicy(sizePolicy)
        self.samplingBox.setStyleSheet("border: 2px solid rgb(255, 75, 0);\n"
"")
        self.samplingBox.setTitle("")
        self.samplingBox.setObjectName("samplingBox")
        self.verticalLayout_3 = QtWidgets.QVBoxLayout(self.samplingBox)
        self.verticalLayout_3.setContentsMargins(11, 11, 11, 11)
        self.verticalLayout_3.setSpacing(6)
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.samplingCBox = QtWidgets.QComboBox(self.samplingBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.samplingCBox.sizePolicy().hasHeightForWidth())
        self.samplingCBox.setSizePolicy(sizePolicy)
        self.samplingCBox.setStyleSheet("")
        self.samplingCBox.setObjectName("samplingCBox")
        self.samplingCBox.addItem("")
        self.samplingCBox.addItem("")
        self.samplingCBox.addItem("")
        self.samplingCBox.addItem("")
        self.samplingCBox.addItem("")
        self.samplingCBox.addItem("")
        self.samplingCBox.addItem("")
        self.samplingCBox.addItem("")
        self.samplingCBox.addItem("")
        self.verticalLayout_3.addWidget(self.samplingCBox)
        self.pushButton = QtWidgets.QPushButton(self.samplingBox)
        self.pushButton.setObjectName("pushButton")
        self.verticalLayout_3.addWidget(self.pushButton)
        self.scaleGBox = QtWidgets.QGroupBox(self.samplingBox)
        self.scaleGBox.setObjectName("scaleGBox")
        self.gridLayoutWidget = QtWidgets.QWidget(self.scaleGBox)
        self.gridLayoutWidget.setGeometry(QtCore.QRect(10, 30, 381, 91))
        self.gridLayoutWidget.setObjectName("gridLayoutWidget")
        self.grid = QtWidgets.QGridLayout(self.gridLayoutWidget)
        self.grid.setContentsMargins(11, 11, 11, 11)
        self.grid.setSpacing(6)
        self.grid.setObjectName("grid")
        self.min_pressao = QtWidgets.QSpinBox(self.gridLayoutWidget)
        self.min_pressao.setPrefix("")
        self.min_pressao.setMaximum(400)
        self.min_pressao.setObjectName("min_pressao")
        self.grid.addWidget(self.min_pressao, 1, 0, 1, 1)
        self.min_amostra = QtWidgets.QSpinBox(self.gridLayoutWidget)
        self.min_amostra.setPrefix("")
        self.min_amostra.setMaximum(255)
        self.min_amostra.setObjectName("min_amostra")
        self.grid.addWidget(self.min_amostra, 0, 0, 1, 1)
        self.max_amostra = QtWidgets.QSpinBox(self.gridLayoutWidget)
        self.max_amostra.setMaximum(256)
        self.max_amostra.setProperty("value", 256)
        self.max_amostra.setObjectName("max_amostra")
        self.grid.addWidget(self.max_amostra, 0, 1, 1, 1)
        self.max_pressao = QtWidgets.QSpinBox(self.gridLayoutWidget)
        self.max_pressao.setPrefix("")
        self.max_pressao.setMaximum(400)
        self.max_pressao.setProperty("value", 100)
        self.max_pressao.setObjectName("max_pressao")
        self.grid.addWidget(self.max_pressao, 1, 1, 1, 1)
        self.verticalLayout_3.addWidget(self.scaleGBox)
        self.gridLayout_2.addWidget(self.samplingBox, 3, 1, 1, 2)
        self.scrollArea = QtWidgets.QScrollArea(self.widget)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.scrollArea.sizePolicy().hasHeightForWidth())
        self.scrollArea.setSizePolicy(sizePolicy)
        self.scrollArea.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOn)
        self.scrollArea.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
        self.scrollArea.setWidgetResizable(False)
        self.scrollArea.setObjectName("scrollArea")
        self.scrollAreaWidgetContents = QtWidgets.QWidget()
        self.scrollAreaWidgetContents.setGeometry(QtCore.QRect(0, 0, 930, 200))
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.scrollAreaWidgetContents.sizePolicy().hasHeightForWidth())
        self.scrollAreaWidgetContents.setSizePolicy(sizePolicy)
        self.scrollAreaWidgetContents.setObjectName("scrollAreaWidgetContents")
        self.gridLayout_7 = QtWidgets.QGridLayout(self.scrollAreaWidgetContents)
        self.gridLayout_7.setContentsMargins(11, 11, 11, 11)
        self.gridLayout_7.setSpacing(6)
        self.gridLayout_7.setObjectName("gridLayout_7")
        self.consoleView = QtWidgets.QLabel(self.scrollAreaWidgetContents)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.consoleView.sizePolicy().hasHeightForWidth())
        self.consoleView.setSizePolicy(sizePolicy)
        self.consoleView.setCursor(QtGui.QCursor(QtCore.Qt.IBeamCursor))
        self.consoleView.setStyleSheet("padding: 2px;\n"
"border: 2px solid rgb(5, 5, 5);\n"
"font: 10pt \"Liberation Mono\";")
        self.consoleView.setText("")
        self.consoleView.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
        self.consoleView.setWordWrap(True)
        self.consoleView.setObjectName("consoleView")
        self.gridLayout_7.addWidget(self.consoleView, 0, 1, 1, 1)
        self.scrollArea.setWidget(self.scrollAreaWidgetContents)
        self.gridLayout_2.addWidget(self.scrollArea, 3, 3, 1, 2)
235 236 237 238 239 240 241 242 243 244
        self.gridLayout_2.setColumnStretch(0, 1)
        self.gridLayout_2.setColumnStretch(1, 1)
        self.gridLayout_2.setColumnStretch(2, 1)
        self.gridLayout_2.setColumnStretch(3, 4)
        self.gridLayout_2.setRowStretch(0, 3)
        self.gridLayout_2.setRowStretch(1, 1)
        self.gridLayout_2.setRowStretch(2, 2)
        self.gridLayout_6.addWidget(self.widget, 0, 0, 1, 1)
        Generico.setCentralWidget(self.centralWidget)
        self.menuBar = QtWidgets.QMenuBar(Generico)
245
        self.menuBar.setGeometry(QtCore.QRect(0, 0, 1366, 28))
246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276
        self.menuBar.setObjectName("menuBar")
        Generico.setMenuBar(self.menuBar)
        self.menuStatusBar = QtWidgets.QStatusBar(Generico)
        self.menuStatusBar.setObjectName("menuStatusBar")
        Generico.setStatusBar(self.menuStatusBar)
        self.alternaCalibraP = QtWidgets.QAction(Generico)
        self.alternaCalibraP.setObjectName("alternaCalibraP")
        self.alternaCalibraT = QtWidgets.QAction(Generico)
        self.alternaCalibraT.setObjectName("alternaCalibraT")
        self.alternaProc = QtWidgets.QAction(Generico)
        self.alternaProc.setObjectName("alternaProc")
        self.openButton = QtWidgets.QAction(Generico)
        self.openButton.setIconVisibleInMenu(True)
        self.openButton.setObjectName("openButton")
        self.actionSalvar = QtWidgets.QAction(Generico)
        self.actionSalvar.setObjectName("actionSalvar")
        self.actionSalvar_Como = QtWidgets.QAction(Generico)
        self.actionSalvar_Como.setObjectName("actionSalvar_Como")
        self.saveButton = QtWidgets.QAction(Generico)
        self.saveButton.setObjectName("saveButton")
        self.saveAsButton = QtWidgets.QAction(Generico)
        self.saveAsButton.setObjectName("saveAsButton")
        self.selectPortaUSB = QtWidgets.QAction(Generico)
        self.selectPortaUSB.setObjectName("selectPortaUSB")

        self.retranslateUi(Generico)
        QtCore.QMetaObject.connectSlotsByName(Generico)

    def retranslateUi(self, Generico):
        _translate = QtCore.QCoreApplication.translate
        Generico.setWindowTitle(_translate("Generico", "SADAMAP - Análise de Dados: Etapa 1 - Calibração de Pressão"))
277 278 279 280 281
        self.absValGBox.setTitle(_translate("Generico", "Valores Absolutos"))
        self.calibratorGBox.setTitle(_translate("Generico", "Amostra"))
        self.calibratorLabel.setText(_translate("Generico", "0 mV"))
        self.forceGBox.setTitle(_translate("Generico", "Pressão"))
        self.forceLabel.setText(_translate("Generico", "0 Tonf"))
282 283 284 285 286 287 288 289 290
        self.samplingCBox.setItemText(0, _translate("Generico", "100 mseg"))
        self.samplingCBox.setItemText(1, _translate("Generico", "200 mseg"))
        self.samplingCBox.setItemText(2, _translate("Generico", "500 mseg"))
        self.samplingCBox.setItemText(3, _translate("Generico", "1 seg"))
        self.samplingCBox.setItemText(4, _translate("Generico", "1.5 seg"))
        self.samplingCBox.setItemText(5, _translate("Generico", "2 seg"))
        self.samplingCBox.setItemText(6, _translate("Generico", "2.5 seg"))
        self.samplingCBox.setItemText(7, _translate("Generico", "5 seg"))
        self.samplingCBox.setItemText(8, _translate("Generico", "10 seg"))
291 292 293 294 295 296
        self.pushButton.setText(_translate("Generico", "PAUSA"))
        self.scaleGBox.setTitle(_translate("Generico", "Escala"))
        self.min_pressao.setSuffix(_translate("Generico", " bar"))
        self.min_amostra.setSuffix(_translate("Generico", " mV"))
        self.max_amostra.setSuffix(_translate("Generico", " mV"))
        self.max_pressao.setSuffix(_translate("Generico", " bar"))
297 298 299 300 301 302 303 304 305 306
        self.alternaCalibraP.setText(_translate("Generico", "Calibração P"))
        self.alternaCalibraT.setText(_translate("Generico", "Calibração T"))
        self.alternaProc.setText(_translate("Generico", "Processamento"))
        self.openButton.setText(_translate("Generico", "Abrir"))
        self.actionSalvar.setText(_translate("Generico", "Salvar"))
        self.actionSalvar_Como.setText(_translate("Generico", "Salvar Como"))
        self.saveButton.setText(_translate("Generico", "Salvar"))
        self.saveAsButton.setText(_translate("Generico", "Salvar Como"))
        self.selectPortaUSB.setText(_translate("Generico", "Selecionar porta USB"))
from pyqtgraph import GraphicsLayoutWidget