-
Notifications
You must be signed in to change notification settings - Fork 2
/
ventana_principal_ui.py
244 lines (236 loc) · 14.3 KB
/
ventana_principal_ui.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
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
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
235
236
237
238
239
240
241
242
243
244
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'ventana_principal.ui'
#
# Created by: PyQt5 UI code generator 5.9.2
#
# 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(500, 445)
MainWindow.setMinimumSize(QtCore.QSize(500, 445))
MainWindow.setMaximumSize(QtCore.QSize(500, 445))
icon = QtGui.QIcon()
icon.addPixmap(QtGui.QPixmap("icono.ico"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
MainWindow.setWindowIcon(icon)
self.centralwidget = QtWidgets.QWidget(MainWindow)
self.centralwidget.setObjectName("centralwidget")
self.lbl_ganancia_sesion = QtWidgets.QLabel(self.centralwidget)
self.lbl_ganancia_sesion.setGeometry(QtCore.QRect(290, 395, 181, 20))
self.lbl_ganancia_sesion.setObjectName("lbl_ganancia_sesion")
self.pbtn_iniciar_escaneo = QtWidgets.QPushButton(self.centralwidget)
self.pbtn_iniciar_escaneo.setGeometry(QtCore.QRect(325, 230, 101, 30))
self.pbtn_iniciar_escaneo.setObjectName("pbtn_iniciar_escaneo")
self.pbtn_detener_escaneo = QtWidgets.QPushButton(self.centralwidget)
self.pbtn_detener_escaneo.setGeometry(QtCore.QRect(325, 230, 101, 30))
self.pbtn_detener_escaneo.setObjectName("pbtn_detener_escaneo")
self.lbl_N_monedas = QtWidgets.QLabel(self.centralwidget)
self.lbl_N_monedas.setGeometry(QtCore.QRect(280, 100, 181, 20))
self.lbl_N_monedas.setObjectName("lbl_N_monedas")
self.lbl_disponible = QtWidgets.QLabel(self.centralwidget)
self.lbl_disponible.setGeometry(QtCore.QRect(20, 20, 211, 20))
self.lbl_disponible.setObjectName("lbl_disponible")
self.pbar = QtWidgets.QProgressBar(self.centralwidget)
self.pbar.setGeometry(QtCore.QRect(280, 200, 211, 20))
self.pbar.setProperty("value", 0)
self.pbar.setObjectName("pbar")
self.lbl_vela = QtWidgets.QLabel(self.centralwidget)
self.lbl_vela.setGeometry(QtCore.QRect(280, 10, 101, 20))
self.lbl_vela.setObjectName("lbl_vela")
self.lbl_npt = QtWidgets.QLabel(self.centralwidget)
self.lbl_npt.setGeometry(QtCore.QRect(280, 40, 151, 20))
self.lbl_npt.setObjectName("lbl_npt")
self.lbl_nprsi = QtWidgets.QLabel(self.centralwidget)
self.lbl_nprsi.setGeometry(QtCore.QRect(280, 70, 171, 20))
self.lbl_nprsi.setObjectName("lbl_nprsi")
self.pbtn_historial = QtWidgets.QPushButton(self.centralwidget)
self.pbtn_historial.setGeometry(QtCore.QRect(390, 280, 71, 30))
self.pbtn_historial.setObjectName("pbtn_historial")
self.pbtn_rankings = QtWidgets.QPushButton(self.centralwidget)
self.pbtn_rankings.setGeometry(QtCore.QRect(300, 280, 71, 30))
self.pbtn_rankings.setObjectName("pbtn_rankings")
self.lbl_prompt = QtWidgets.QLabel(self.centralwidget)
self.lbl_prompt.setGeometry(QtCore.QRect(280, 330, 201, 51))
self.lbl_prompt.setText("")
self.lbl_prompt.setObjectName("lbl_prompt")
self.gpbx_posicion = QtWidgets.QGroupBox(self.centralwidget)
self.gpbx_posicion.setGeometry(QtCore.QRect(10, 110, 251, 321))
self.gpbx_posicion.setObjectName("gpbx_posicion")
self.lbl_apalancamiento = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_apalancamiento.setGeometry(QtCore.QRect(10, 55, 81, 20))
self.lbl_apalancamiento.setObjectName("lbl_apalancamiento")
self.lbl_inversion = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_inversion.setGeometry(QtCore.QRect(10, 120, 51, 20))
self.lbl_inversion.setObjectName("lbl_inversion")
self.lbl_precio = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_precio.setGeometry(QtCore.QRect(10, 150, 31, 20))
self.lbl_precio.setObjectName("lbl_precio")
self.lbl_retroceso = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_retroceso.setGeometry(QtCore.QRect(10, 190, 121, 20))
self.lbl_retroceso.setObjectName("lbl_retroceso")
self.lbl_activacion = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_activacion.setGeometry(QtCore.QRect(10, 220, 51, 20))
self.lbl_activacion.setObjectName("lbl_activacion")
self.lbl_stop_loss = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_stop_loss.setGeometry(QtCore.QRect(10, 250, 51, 20))
self.lbl_stop_loss.setObjectName("lbl_stop_loss")
self.spnbx_inversion = QtWidgets.QDoubleSpinBox(self.gpbx_posicion)
self.spnbx_inversion.setGeometry(QtCore.QRect(65, 120, 51, 20))
self.spnbx_inversion.setDecimals(1)
self.spnbx_inversion.setMaximum(100.0)
self.spnbx_inversion.setSingleStep(0.1)
self.spnbx_inversion.setProperty("value", 100.0)
self.spnbx_inversion.setObjectName("spnbx_inversion")
self.linedit_precio = QtWidgets.QLineEdit(self.gpbx_posicion)
self.linedit_precio.setGeometry(QtCore.QRect(50, 150, 91, 20))
self.linedit_precio.setObjectName("linedit_precio")
self.lbl_und_precio = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_und_precio.setGeometry(QtCore.QRect(150, 150, 31, 20))
self.lbl_und_precio.setObjectName("lbl_und_precio")
self.lbl_und_inversion = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_und_inversion.setGeometry(QtCore.QRect(120, 120, 21, 20))
self.lbl_und_inversion.setObjectName("lbl_und_inversion")
self.spnbx_retroceso = QtWidgets.QDoubleSpinBox(self.gpbx_posicion)
self.spnbx_retroceso.setGeometry(QtCore.QRect(130, 190, 51, 20))
self.spnbx_retroceso.setDecimals(1)
self.spnbx_retroceso.setMinimum(0.1)
self.spnbx_retroceso.setMaximum(100.0)
self.spnbx_retroceso.setSingleStep(0.1)
self.spnbx_retroceso.setProperty("value", 20.0)
self.spnbx_retroceso.setObjectName("spnbx_retroceso")
self.lbl_und_restroceso = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_und_restroceso.setGeometry(QtCore.QRect(185, 190, 21, 20))
self.lbl_und_restroceso.setObjectName("lbl_und_restroceso")
self.spnbx_activacion = QtWidgets.QDoubleSpinBox(self.gpbx_posicion)
self.spnbx_activacion.setGeometry(QtCore.QRect(65, 220, 51, 20))
self.spnbx_activacion.setDecimals(2)
self.spnbx_activacion.setMinimum(0.01)
self.spnbx_activacion.setMaximum(100.0)
self.spnbx_activacion.setSingleStep(0.01)
self.spnbx_activacion.setProperty("value", 0.35)
self.spnbx_activacion.setObjectName("spnbx_activacion")
self.lbl_und_activacion = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_und_activacion.setGeometry(QtCore.QRect(120, 220, 21, 20))
self.lbl_und_activacion.setObjectName("lbl_und_activacion")
self.spnbx_stop_loss = QtWidgets.QDoubleSpinBox(self.gpbx_posicion)
self.spnbx_stop_loss.setGeometry(QtCore.QRect(65, 250, 51, 20))
self.spnbx_stop_loss.setDecimals(2)
self.spnbx_stop_loss.setMinimum(0.01)
self.spnbx_stop_loss.setMaximum(100.0)
self.spnbx_stop_loss.setSingleStep(0.01)
self.spnbx_stop_loss.setProperty("value", 0.1)
self.spnbx_stop_loss.setObjectName("spnbx_stop_loss")
self.lbl_und_stop_loss = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_und_stop_loss.setGeometry(QtCore.QRect(120, 250, 21, 20))
self.lbl_und_stop_loss.setObjectName("lbl_und_stop_loss")
self.pbtn_entrar_posicion = QtWidgets.QPushButton(self.gpbx_posicion)
self.pbtn_entrar_posicion.setGeometry(QtCore.QRect(160, 220, 75, 23))
self.pbtn_entrar_posicion.setObjectName("pbtn_entrar_posicion")
self.lbl_inversion_en_quote = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_inversion_en_quote.setGeometry(QtCore.QRect(140, 120, 101, 20))
self.lbl_inversion_en_quote.setObjectName("lbl_inversion_en_quote")
self.lbl_movimiento_favor = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_movimiento_favor.setGeometry(QtCore.QRect(50, 290, 141, 20))
self.lbl_movimiento_favor.setObjectName("lbl_movimiento_favor")
self.lbl_direccion = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_direccion.setGeometry(QtCore.QRect(10, 20, 51, 20))
self.lbl_direccion.setObjectName("lbl_direccion")
self.cbx_direccion = QtWidgets.QComboBox(self.gpbx_posicion)
self.cbx_direccion.setGeometry(QtCore.QRect(65, 20, 51, 20))
self.cbx_direccion.setObjectName("cbx_direccion")
self.cbx_direccion.addItem("")
self.cbx_direccion.addItem("")
self.hsldr_apalancamiento = QtWidgets.QSlider(self.gpbx_posicion)
self.hsldr_apalancamiento.setGeometry(QtCore.QRect(10, 85, 171, 20))
self.hsldr_apalancamiento.setMinimum(1)
self.hsldr_apalancamiento.setMaximum(7)
self.hsldr_apalancamiento.setPageStep(1)
self.hsldr_apalancamiento.setProperty("value", 1)
self.hsldr_apalancamiento.setSliderPosition(1)
self.hsldr_apalancamiento.setOrientation(QtCore.Qt.Horizontal)
self.hsldr_apalancamiento.setTickPosition(QtWidgets.QSlider.NoTicks)
self.hsldr_apalancamiento.setTickInterval(1)
self.hsldr_apalancamiento.setObjectName("hsldr_apalancamiento")
self.lbl_apalancamiento_2 = QtWidgets.QLabel(self.gpbx_posicion)
self.lbl_apalancamiento_2.setGeometry(QtCore.QRect(190, 80, 51, 20))
self.lbl_apalancamiento_2.setObjectName("lbl_apalancamiento_2")
self.pbtn_salir_posicion = QtWidgets.QPushButton(self.gpbx_posicion)
self.pbtn_salir_posicion.setGeometry(QtCore.QRect(160, 250, 75, 23))
self.pbtn_salir_posicion.setObjectName("pbtn_salir_posicion")
self.pbtn_seleccionar_par = QtWidgets.QPushButton(self.centralwidget)
self.pbtn_seleccionar_par.setGeometry(QtCore.QRect(160, 70, 81, 23))
self.pbtn_seleccionar_par.setObjectName("pbtn_seleccionar_par")
self.linedit_par = QtWidgets.QLineEdit(self.centralwidget)
self.linedit_par.setGeometry(QtCore.QRect(42, 70, 111, 23))
self.linedit_par.setObjectName("linedit_par")
self.pbtn_cambiar_par = QtWidgets.QPushButton(self.centralwidget)
self.pbtn_cambiar_par.setGeometry(QtCore.QRect(170, 70, 61, 23))
self.pbtn_cambiar_par.setObjectName("pbtn_cambiar_par")
self.lbl_par = QtWidgets.QLabel(self.centralwidget)
self.lbl_par.setGeometry(QtCore.QRect(20, 70, 21, 23))
self.lbl_par.setObjectName("lbl_par")
self.gpbx_posicion.raise_()
self.lbl_prompt.raise_()
self.pbtn_detener_escaneo.raise_()
self.pbar.raise_()
self.lbl_ganancia_sesion.raise_()
self.pbtn_iniciar_escaneo.raise_()
self.lbl_N_monedas.raise_()
self.lbl_disponible.raise_()
self.lbl_vela.raise_()
self.lbl_npt.raise_()
self.lbl_nprsi.raise_()
self.pbtn_historial.raise_()
self.pbtn_rankings.raise_()
self.pbtn_seleccionar_par.raise_()
self.linedit_par.raise_()
self.pbtn_cambiar_par.raise_()
self.lbl_par.raise_()
MainWindow.setCentralWidget(self.centralwidget)
self.retranslateUi(MainWindow)
QtCore.QMetaObject.connectSlotsByName(MainWindow)
def retranslateUi(self, MainWindow):
_translate = QtCore.QCoreApplication.translate
MainWindow.setWindowTitle(_translate("MainWindow", "Hidalgo Trading Tool"))
self.lbl_ganancia_sesion.setText(_translate("MainWindow", "Ganancia en esta sesión: 0 %"))
self.pbtn_iniciar_escaneo.setText(_translate("MainWindow", "Iniciar escaneo"))
self.pbtn_detener_escaneo.setText(_translate("MainWindow", "Detener escaneo"))
self.lbl_N_monedas.setText(_translate("MainWindow", "Número de monedas:"))
self.lbl_disponible.setText(_translate("MainWindow", "Disponible:"))
self.lbl_vela.setText(_translate("MainWindow", "Vela:"))
self.lbl_npt.setText(_translate("MainWindow", "Periodos tendencia:"))
self.lbl_nprsi.setText(_translate("MainWindow", "Periodos RSI:"))
self.pbtn_historial.setText(_translate("MainWindow", "Historial"))
self.pbtn_rankings.setText(_translate("MainWindow", "Rankings"))
self.gpbx_posicion.setTitle(_translate("MainWindow", "Posición"))
self.lbl_apalancamiento.setText(_translate("MainWindow", "Apalancamiento:"))
self.lbl_inversion.setText(_translate("MainWindow", "Inversión:"))
self.lbl_precio.setText(_translate("MainWindow", "Precio:"))
self.lbl_retroceso.setText(_translate("MainWindow", "Retroceso proporcional:"))
self.lbl_activacion.setText(_translate("MainWindow", "Activación:"))
self.lbl_stop_loss.setText(_translate("MainWindow", "Stop Loss:"))
self.lbl_und_precio.setText(_translate("MainWindow", "USDT"))
self.lbl_und_inversion.setText(_translate("MainWindow", "%"))
self.lbl_und_restroceso.setText(_translate("MainWindow", "%"))
self.lbl_und_activacion.setText(_translate("MainWindow", "%"))
self.lbl_und_stop_loss.setText(_translate("MainWindow", "%"))
self.pbtn_entrar_posicion.setText(_translate("MainWindow", "Entrar"))
self.lbl_inversion_en_quote.setText(_translate("MainWindow", "= ??? USDT"))
self.lbl_movimiento_favor.setText(_translate("MainWindow", "Movimiento a favor: 0 %"))
self.lbl_direccion.setText(_translate("MainWindow", "Dirección:"))
self.cbx_direccion.setItemText(0, _translate("MainWindow", "Long"))
self.cbx_direccion.setItemText(1, _translate("MainWindow", "Short"))
self.lbl_apalancamiento_2.setText(_translate("MainWindow", "x1"))
self.pbtn_salir_posicion.setText(_translate("MainWindow", "Salir"))
self.pbtn_seleccionar_par.setText(_translate("MainWindow", "Seleccionar"))
self.pbtn_cambiar_par.setText(_translate("MainWindow", "Cambiar"))
self.lbl_par.setText(_translate("MainWindow", "Par:"))
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_())