-
Notifications
You must be signed in to change notification settings - Fork 0
/
paginaprincipal.py
61 lines (51 loc) · 1.8 KB
/
paginaprincipal.py
1
2
3
4
5
6
7
8
9
10
11
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
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import sys
from PyQt5.QtCore import pyqtSlot
from PyQt5.QtWidgets import QApplication, QDialog
from PyQt5.uic import loadUi
from main import *
from sistemasEcuaciones import sistemasEcuaciones
from interpolacion import Interpolacion
from Diferenciacion import diferenciacion
class paginaprincipal(QDialog):
def __init__(self):
super(paginaprincipal,self).__init__()
loadUi('UI/principal.ui',self)
self.setWindowTitle('Página principal')
self.continuar.clicked.connect(self.on_pushButton_clicked)
def unaVariableShow(self):
self.dialogue = main()
self.dialogue.show()
def interpolacionShow(self):
self.dialogue = Interpolacion()
self.dialogue.show()
def sistemasShow(self):
self.dialogue = sistemasEcuaciones()
self.dialogue.show()
@pyqtSlot()
def on_pushButton_clicked(self):
if(self.sender().text() == "Continuar"):
if(self.unavariable.isChecked()):
print("unavar")
self.unaVariableShow()
elif(self.sistemas.isChecked()):
self.sistemasShow()
print("sistemas")
elif (self.interpolacion.isChecked()):
print("interpol")
self.interpolacionShow()
elif (self.diferenciacion.isChecked()):
self.dialogue = diferenciacion()
self.dialogue.show()
print("diferenciacion e integracion")
app = QApplication(sys.argv)
widget = paginaprincipal()
widget.show()
sys._excepthook = sys.excepthook
def exception_hook(exctype, value, traceback):
print(exctype, value, traceback)
sys.__excepthook__(exctype, value, traceback)
sys.exit(1)
sys.excepthook = exception_hook
sys.exit(app.exec_())