You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
119 lines
6.7 KiB
Python
119 lines
6.7 KiB
Python
6 years ago
|
# -*- coding: utf-8 -*-
|
||
|
|
||
|
# Form implementation generated from reading ui file 'filtre_gui.ui'
|
||
|
#
|
||
|
# Created by: PyQt5 UI code generator 5.12
|
||
|
#
|
||
|
# WARNING! All changes made in this file will be lost!
|
||
|
|
||
|
from PyQt5 import QtCore, QtGui, QtWidgets
|
||
|
|
||
|
|
||
|
class Ui_MainWindow(object):
|
||
|
def setupUi(self, MainWindow):
|
||
|
MainWindow.setObjectName("MainWindow")
|
||
|
MainWindow.resize(333, 361)
|
||
|
self.centralwidget = QtWidgets.QWidget(MainWindow)
|
||
|
self.centralwidget.setObjectName("centralwidget")
|
||
|
self.resultatlk_textedit = QtWidgets.QTextEdit(self.centralwidget)
|
||
|
self.resultatlk_textedit.setGeometry(QtCore.QRect(150, 179, 160, 51))
|
||
|
self.resultatlk_textedit.setObjectName("resultatlk_textedit")
|
||
|
self.resultatck_textedit = QtWidgets.QTextEdit(self.centralwidget)
|
||
|
self.resultatck_textedit.setGeometry(QtCore.QRect(150, 240, 160, 51))
|
||
|
self.resultatck_textedit.setObjectName("resultatck_textedit")
|
||
|
self.resultatrn_lineedit = QtWidgets.QLineEdit(self.centralwidget)
|
||
|
self.resultatrn_lineedit.setGeometry(QtCore.QRect(150, 300, 160, 20))
|
||
|
self.resultatrn_lineedit.setObjectName("resultatrn_lineedit")
|
||
|
self.resultatrn_label = QtWidgets.QLabel(self.centralwidget)
|
||
|
self.resultatrn_label.setGeometry(QtCore.QRect(22, 300, 97, 16))
|
||
|
self.resultatrn_label.setObjectName("resultatrn_label")
|
||
|
self.resultatck_label = QtWidgets.QLabel(self.centralwidget)
|
||
|
self.resultatck_label.setGeometry(QtCore.QRect(22, 240, 105, 16))
|
||
|
self.resultatck_label.setObjectName("resultatck_label")
|
||
|
self.resultatlk_label = QtWidgets.QLabel(self.centralwidget)
|
||
|
self.resultatlk_label.setGeometry(QtCore.QRect(22, 179, 118, 16))
|
||
|
self.resultatlk_label.setObjectName("resultatlk_label")
|
||
|
self.ordre_label = QtWidgets.QLabel(self.centralwidget)
|
||
|
self.ordre_label.setGeometry(QtCore.QRect(22, 124, 28, 16))
|
||
|
self.ordre_label.setObjectName("ordre_label")
|
||
|
self.impEntree_label = QtWidgets.QLabel(self.centralwidget)
|
||
|
self.impEntree_label.setGeometry(QtCore.QRect(22, 98, 115, 16))
|
||
|
self.impEntree_label.setObjectName("impEntree_label")
|
||
|
self.impEntree_lineedit = QtWidgets.QLineEdit(self.centralwidget)
|
||
|
self.impEntree_lineedit.setGeometry(QtCore.QRect(170, 98, 140, 20))
|
||
|
self.impEntree_lineedit.setObjectName("impEntree_lineedit")
|
||
|
self.titre_label = QtWidgets.QLabel(self.centralwidget)
|
||
|
self.titre_label.setGeometry(QtCore.QRect(40, 20, 257, 18))
|
||
|
font = QtGui.QFont()
|
||
|
font.setPointSize(11)
|
||
|
font.setBold(True)
|
||
|
font.setWeight(75)
|
||
|
font.setKerning(True)
|
||
|
self.titre_label.setFont(font)
|
||
|
self.titre_label.setObjectName("titre_label")
|
||
|
self.freqCp_label = QtWidgets.QLabel(self.centralwidget)
|
||
|
self.freqCp_label.setGeometry(QtCore.QRect(22, 46, 131, 16))
|
||
|
self.freqCp_label.setObjectName("freqCp_label")
|
||
|
self.ordre_lineedit = QtWidgets.QLineEdit(self.centralwidget)
|
||
|
self.ordre_lineedit.setGeometry(QtCore.QRect(170, 124, 140, 20))
|
||
|
self.ordre_lineedit.setObjectName("ordre_lineedit")
|
||
|
self.freqCp_lineedit = QtWidgets.QLineEdit(self.centralwidget)
|
||
|
self.freqCp_lineedit.setGeometry(QtCore.QRect(170, 46, 140, 20))
|
||
|
self.freqCp_lineedit.setObjectName("freqCp_lineedit")
|
||
|
self.effacer_pushbutton = QtWidgets.QPushButton(self.centralwidget)
|
||
|
self.effacer_pushbutton.setGeometry(QtCore.QRect(22, 150, 140, 23))
|
||
|
self.effacer_pushbutton.setObjectName("effacer_pushbutton")
|
||
|
self.amplitude_lineedit = QtWidgets.QLineEdit(self.centralwidget)
|
||
|
self.amplitude_lineedit.setGeometry(QtCore.QRect(170, 72, 140, 20))
|
||
|
self.amplitude_lineedit.setObjectName("amplitude_lineedit")
|
||
|
self.calculer_pushbutton = QtWidgets.QPushButton(self.centralwidget)
|
||
|
self.calculer_pushbutton.setGeometry(QtCore.QRect(170, 150, 140, 23))
|
||
|
self.calculer_pushbutton.setObjectName("calculer_pushbutton")
|
||
|
self.amplitude_label = QtWidgets.QLabel(self.centralwidget)
|
||
|
self.amplitude_label.setGeometry(QtCore.QRect(22, 72, 64, 16))
|
||
|
self.amplitude_label.setObjectName("amplitude_label")
|
||
|
MainWindow.setCentralWidget(self.centralwidget)
|
||
|
self.statusbar = QtWidgets.QStatusBar(MainWindow)
|
||
|
self.statusbar.setObjectName("statusbar")
|
||
|
MainWindow.setStatusBar(self.statusbar)
|
||
|
|
||
|
self.retranslateUi(MainWindow)
|
||
|
self.effacer_pushbutton.clicked.connect(self.ordre_lineedit.clear)
|
||
|
self.effacer_pushbutton.clicked.connect(self.freqCp_lineedit.clear)
|
||
|
self.effacer_pushbutton.clicked.connect(self.amplitude_lineedit.clear)
|
||
|
self.effacer_pushbutton.clicked.connect(self.impEntree_lineedit.clear)
|
||
|
self.effacer_pushbutton.clicked.connect(self.resultatrn_lineedit.clear)
|
||
|
QtCore.QMetaObject.connectSlotsByName(MainWindow)
|
||
|
|
||
|
def retranslateUi(self, MainWindow):
|
||
|
_translate = QtCore.QCoreApplication.translate
|
||
|
MainWindow.setWindowTitle(_translate("MainWindow", "Filtre de Chebyshev"))
|
||
|
self.resultatrn_label.setText(_translate("MainWindow", "Charge adaptée (Ω)"))
|
||
|
self.resultatck_label.setText(_translate("MainWindow", "Capacité du circuit (F)"))
|
||
|
self.resultatlk_label.setText(_translate("MainWindow", "Inductance du circuit (H)"))
|
||
|
self.ordre_label.setText(_translate("MainWindow", "Ordre"))
|
||
|
self.impEntree_label.setText(_translate("MainWindow", "Impédance d\'entrée (Ω)"))
|
||
|
self.impEntree_lineedit.setToolTip(_translate("MainWindow", "impEntree"))
|
||
|
self.titre_label.setText(_translate("MainWindow", "Calculateur de filtre de Chebyshev"))
|
||
|
self.freqCp_label.setText(_translate("MainWindow", "Fréquence de coupure (Hz)"))
|
||
|
self.ordre_lineedit.setToolTip(_translate("MainWindow", "ordre"))
|
||
|
self.freqCp_lineedit.setToolTip(_translate("MainWindow", "freqCp"))
|
||
|
self.effacer_pushbutton.setStatusTip(_translate("MainWindow", "Tout effacer"))
|
||
|
self.effacer_pushbutton.setText(_translate("MainWindow", "Effacer"))
|
||
|
self.amplitude_lineedit.setToolTip(_translate("MainWindow", "amplitude"))
|
||
|
self.calculer_pushbutton.setStatusTip(_translate("MainWindow", "Calculer le résultat"))
|
||
|
self.calculer_pushbutton.setText(_translate("MainWindow", "Calculer"))
|
||
|
self.amplitude_label.setText(_translate("MainWindow", "Amplitude (V)"))
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
if __name__ == "__main__":
|
||
|
import sys
|
||
|
app = QtWidgets.QApplication(sys.argv)
|
||
|
MainWindow = QtWidgets.QMainWindow()
|
||
|
ui = Ui_MainWindow()
|
||
|
ui.setupUi(MainWindow)
|
||
|
MainWindow.show()
|
||
|
sys.exit(app.exec_())
|