##// END OF EJS Templates
GUI: Every icon were resized
Miguel Valdez -
r667:e6e33e90d008
parent child
Show More
1 NO CONTENT: new file 100644, binary diff hidden
NO CONTENT: new file 100644, binary diff hidden
1 NO CONTENT: new file 100644, binary diff hidden
NO CONTENT: new file 100644, binary diff hidden
1 NO CONTENT: new file 100644, binary diff hidden
NO CONTENT: new file 100644, binary diff hidden
1 NO CONTENT: new file 100644, binary diff hidden
NO CONTENT: new file 100644, binary diff hidden
1 NO CONTENT: new file 100644, binary diff hidden
NO CONTENT: new file 100644, binary diff hidden
1 NO CONTENT: new file 100644, binary diff hidden
NO CONTENT: new file 100644, binary diff hidden
1 NO CONTENT: new file 100644, binary diff hidden
NO CONTENT: new file 100644, binary diff hidden
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
1 NO CONTENT: file renamed from schainpy/gui/figures/startServer.png to schainpy/gui/figures/start.png
NO CONTENT: file renamed from schainpy/gui/figures/startServer.png to schainpy/gui/figures/start.png
1 NO CONTENT: file renamed from schainpy/gui/figures/stopServer.png to schainpy/gui/figures/stop.png
NO CONTENT: file renamed from schainpy/gui/figures/stopServer.png to schainpy/gui/figures/stop.png
@@ -140,7 +140,7 class BasicWindow(QMainWindow, Ui_BasicWindow):
140 self.__operationObjDict = {}
140 self.__operationObjDict = {}
141
141
142 self.__puLocalFolder2FTP = {}
142 self.__puLocalFolder2FTP = {}
143 self.__enable = False
143 self.threadStarted = False
144
144
145 # self.create_comm()
145 # self.create_comm()
146 self.create_updating_timer()
146 self.create_updating_timer()
@@ -792,12 +792,14 class BasicWindow(QMainWindow, Ui_BasicWindow):
792 return 0
792 return 0
793
793
794 valueList = value.split(',')
794 valueList = value.split(',')
795 format = 'float'
795
796 if self.volOpComHeights.currentIndex() == 0:
796 if self.volOpComHeights.currentIndex() == 0:
797 format = 'float'
797 name_operation = 'selectHeights'
798 name_operation = 'selectHeights'
798 name_parameter1 = 'minHei'
799 name_parameter1 = 'minHei'
799 name_parameter2 = 'maxHei'
800 name_parameter2 = 'maxHei'
800 else:
801 else:
802 format = 'int'
801 name_operation = 'selectHeightsByIndex'
803 name_operation = 'selectHeightsByIndex'
802 name_parameter1 = 'minIndex'
804 name_parameter1 = 'minIndex'
803 name_parameter2 = 'maxIndex'
805 name_parameter2 = 'maxIndex'
@@ -929,7 +931,7 class BasicWindow(QMainWindow, Ui_BasicWindow):
929 return 0
931 return 0
930
932
931 name_parameter = 'n'
933 name_parameter = 'n'
932 format = 'float'
934 format = 'int'
933
935
934 opObj = puObj.addOperation(name=name_operation, optype=optype)
936 opObj = puObj.addOperation(name=name_operation, optype=optype)
935
937
@@ -1303,7 +1305,7 class BasicWindow(QMainWindow, Ui_BasicWindow):
1303 format = 'float'
1305 format = 'float'
1304 else:
1306 else:
1305 name_parameter = 'n'
1307 name_parameter = 'n'
1306 format = 'float'
1308 format = 'int'
1307
1309
1308 value = str(self.specOpIncoherent.text())
1310 value = str(self.specOpIncoherent.text())
1309
1311
@@ -2744,10 +2746,8 class BasicWindow(QMainWindow, Ui_BasicWindow):
2744 self.volOpHeights.clear()
2746 self.volOpHeights.clear()
2745 self.volOpCebHeights.setCheckState(0)
2747 self.volOpCebHeights.setCheckState(0)
2746 else:
2748 else:
2747 value1 = int(opObj.getParameterValue(parameterName='minHei'))
2749 value1 = str(opObj.getParameterValue(parameterName='minHei'))
2748 value1 = str(value1)
2750 value2 = str(opObj.getParameterValue(parameterName='maxHei'))
2749 value2 = int(opObj.getParameterValue(parameterName='maxHei'))
2750 value2 = str(value2)
2751 value = value1 + "," + value2
2751 value = value1 + "," + value2
2752 self.volOpHeights.setText(value)
2752 self.volOpHeights.setText(value)
2753 self.volOpHeights.setEnabled(True)
2753 self.volOpHeights.setEnabled(True)
@@ -4236,10 +4236,7 class BasicWindow(QMainWindow, Ui_BasicWindow):
4236
4236
4237 def updateProcUnitView(self, id):
4237 def updateProcUnitView(self, id):
4238
4238
4239 procUnitConfObj = projectObjView.getProcUnitObj(id)
4239 pass
4240 procUnitConfObj.removeOperations()
4241
4242 return procUnitConfObj
4243
4240
4244 def addPUWindow(self):
4241 def addPUWindow(self):
4245
4242
@@ -4709,21 +4706,12 class BasicWindow(QMainWindow, Ui_BasicWindow):
4709 def on_comm_updating_timer(self):
4706 def on_comm_updating_timer(self):
4710 # Verifica si algun proceso ha sido inicializado y sigue ejecutandose
4707 # Verifica si algun proceso ha sido inicializado y sigue ejecutandose
4711 # Si el proceso se ha parado actualizar el GUI (stopProject)
4708 # Si el proceso se ha parado actualizar el GUI (stopProject)
4712 if not self.__enable:
4709 if not self.threadStarted:
4713 return
4710 return
4714
4711
4715 if self.controllerThread.isFinished():
4712 if self.controllerThread.isFinished():
4716 self.stopProject()
4713 self.stopProject()
4717
4714
4718 # def jobStartedFromThread(self, success):
4719 #
4720 # self.console.clear()
4721 # self.console.append("Job started")
4722 #
4723 # def jobFinishedFromThread(self, success):
4724 #
4725 # self.stopProject()
4726
4727 def playProject(self, ext=".xml", save=1):
4715 def playProject(self, ext=".xml", save=1):
4728
4716
4729 projectObj = self.getSelectedProjectObj()
4717 projectObj = self.getSelectedProjectObj()
@@ -4758,14 +4746,15 class BasicWindow(QMainWindow, Ui_BasicWindow):
4758 self.console.clear()
4746 self.console.clear()
4759 self.controllerThread.start()
4747 self.controllerThread.start()
4760 sleep(0.5)
4748 sleep(0.5)
4761 self.__enable = True
4749 self.threadStarted = True
4762
4750
4763 def stopProject(self):
4751 self.changeStartIcon(started=True)
4764
4752
4765 self.__enable = False
4753 def stopProject(self):
4766
4754
4767 # self.commCtrlPThread.cmd_q.put(ProcessCommand(ProcessCommand.STOP, True))
4755 # self.commCtrlPThread.cmd_q.put(ProcessCommand(ProcessCommand.STOP, True))
4768 self.controllerThread.stop()
4756 self.controllerThread.stop()
4757 self.threadStarted = False
4769
4758
4770 while self.controllerThread.isRunning():
4759 while self.controllerThread.isRunning():
4771 sleep(0.5)
4760 sleep(0.5)
@@ -4779,11 +4768,12 class BasicWindow(QMainWindow, Ui_BasicWindow):
4779 self.actionStopToolbar.setEnabled(False)
4768 self.actionStopToolbar.setEnabled(False)
4780
4769
4781 self.restorePauseIcon()
4770 self.restorePauseIcon()
4771 self.restoreStartIcon()
4782
4772
4783 def pauseProject(self):
4773 def pauseProject(self):
4784
4774
4785 # self.commCtrlPThread.cmd_q.put(ProcessCommand(ProcessCommand.PAUSE, data=True))
4775 # self.commCtrlPThread.cmd_q.put(ProcessCommand(ProcessCommand.PAUSE, data=True))
4786 self.controllerThread.pause()
4776 paused = self.controllerThread.pause()
4787
4777
4788 self.actionStart.setEnabled(False)
4778 self.actionStart.setEnabled(False)
4789 self.actionPause.setEnabled(True)
4779 self.actionPause.setEnabled(True)
@@ -4792,6 +4782,8 class BasicWindow(QMainWindow, Ui_BasicWindow):
4792 self.actionStarToolbar.setEnabled(False)
4782 self.actionStarToolbar.setEnabled(False)
4793 self.actionPauseToolbar.setEnabled(True)
4783 self.actionPauseToolbar.setEnabled(True)
4794 self.actionStopToolbar.setEnabled(True)
4784 self.actionStopToolbar.setEnabled(True)
4785
4786 self.changePauseIcon(paused)
4795
4787
4796 def saveProject(self, filename=None):
4788 def saveProject(self, filename=None):
4797
4789
@@ -5356,7 +5348,7 class BasicWindow(QMainWindow, Ui_BasicWindow):
5356 def setGUIStatus(self):
5348 def setGUIStatus(self):
5357
5349
5358 self.setWindowTitle("ROJ-Signal Chain")
5350 self.setWindowTitle("ROJ-Signal Chain")
5359 self.setWindowIcon(QtGui.QIcon( os.path.join(FIGURES_PATH,"adn.jpg") ))
5351 self.setWindowIcon(QtGui.QIcon( os.path.join(FIGURES_PATH,"logo.png") ))
5360
5352
5361 self.tabWidgetProject.setEnabled(False)
5353 self.tabWidgetProject.setEnabled(False)
5362 self.tabVoltage.setEnabled(False)
5354 self.tabVoltage.setEnabled(False)
@@ -35,28 +35,44 class Ui_EnvWindow(object):
35
35
36 def restorePauseIcon(self):
36 def restorePauseIcon(self):
37
37
38 iconPause = QtGui.QIcon()
38 icon_name = "pause.png"
39 iconPause.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"pause.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
39 iconPause = QtGui.QIcon()
40 self.actionPauseToolbar.setIcon(iconPause)
40 iconPause.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH, icon_name) )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
41
41 self.actionPauseToolbar.setIcon(iconPause)
42 self.paused = False
42
43
43 def restoreStartIcon(self):
44 def changePauseIcon(self):
44
45
45 icon_name = "start.png"
46 if self.paused == False:
46 iconStart = QtGui.QIcon()
47 iconPauseRed = QtGui.QIcon()
47 iconStart.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH, icon_name) )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
48 iconPauseRed.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"pausered.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
48 self.actionStarToolbar.setIcon(iconStart)
49 self.actionPauseToolbar.setIcon(iconPauseRed)
49
50 self.paused = True
50 def changePauseIcon(self, paused=False):
51 return 0
51
52
52 if paused == True:
53 if self.paused:
53 icon_name = "pausered.png"
54 iconPause = QtGui.QIcon()
54 else:
55 iconPause.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"pause.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
55 icon_name = "pause.png"
56 self.actionPauseToolbar.setIcon(iconPause)
56
57 self.paused = False
57 iconPause = QtGui.QIcon()
58 return 0
58 iconPause.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH, icon_name) )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
59
59 self.actionPauseToolbar.setIcon(iconPause)
60
61 return
62
63 def changeStartIcon(self, started=False):
64
65 if started == True:
66 icon_name = "startred.png"
67 else:
68 icon_name = "start.png"
69
70 iconStart = QtGui.QIcon()
71 iconStart.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH, icon_name) )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
72 self.actionStarToolbar.setIcon(iconStart)
73
74 return
75
60 def setupUi(self, MainWindow):
76 def setupUi(self, MainWindow):
61
77
62 self.paused=False
78 self.paused=False
@@ -123,19 +139,22 class Ui_EnvWindow(object):
123 MainWindow.setMenuBar(self.menuBar)
139 MainWindow.setMenuBar(self.menuBar)
124
140
125 iconOpen = QtGui.QIcon()
141 iconOpen = QtGui.QIcon()
126 iconOpen.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"open.gif") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
142 iconOpen.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"open.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
127 iconCreate = QtGui.QIcon()
143 iconCreate = QtGui.QIcon()
128 iconCreate.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"project.gif") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
144 iconCreate.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"new.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
129 iconSave = QtGui.QIcon()
145 iconSave = QtGui.QIcon()
130 iconSave.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"saveicon.jpeg") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
146 iconSave.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"save.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
131 iconStart = QtGui.QIcon()
147 iconStart = QtGui.QIcon()
132 iconStart.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"startServer.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
148 iconStart.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"start.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
133 iconStop = QtGui.QIcon()
149 iconStop = QtGui.QIcon()
134 iconStop.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"stopServer.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
150 iconStop.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"stop.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
135 iconPause = QtGui.QIcon()
151 iconPause = QtGui.QIcon()
136 iconPause.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"pause.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
152 iconPause.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"pause.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
137 iconAddPU = QtGui.QIcon()
153 iconAddPU = QtGui.QIcon()
138 iconAddPU.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"add_PU.gif") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
154 iconAddPU.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"branch.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
155 iconClose = QtGui.QIcon()
156 iconClose.addPixmap(QtGui.QPixmap(_fromUtf8( os.path.join(FIGURES_PATH,"close.png") )), QtGui.QIcon.Normal, QtGui.QIcon.Off)
157
139
158
140 self.actionOpen = QtGui.QAction(MainWindow)
159 self.actionOpen = QtGui.QAction(MainWindow)
141 self.actionOpen.setIcon(iconOpen)
160 self.actionOpen.setIcon(iconOpen)
@@ -147,6 +166,7 class Ui_EnvWindow(object):
147 self.actionSave.setIcon(iconSave)
166 self.actionSave.setIcon(iconSave)
148 self.actionSave.setObjectName(_fromUtf8("actionSave"))
167 self.actionSave.setObjectName(_fromUtf8("actionSave"))
149 self.actionClose = QtGui.QAction(MainWindow)
168 self.actionClose = QtGui.QAction(MainWindow)
169 self.actionClose.setIcon(iconClose)
150 self.actionClose.setObjectName(_fromUtf8("actionClose"))
170 self.actionClose.setObjectName(_fromUtf8("actionClose"))
151 self.actionStart = QtGui.QAction(MainWindow)
171 self.actionStart = QtGui.QAction(MainWindow)
152 self.actionStart.setIcon(iconStart)
172 self.actionStart.setIcon(iconStart)
@@ -199,8 +219,8 class Ui_EnvWindow(object):
199 self.toolBar.addAction(self.actionStopToolbar)
219 self.toolBar.addAction(self.actionStopToolbar)
200 self.toolBar.addSeparator()
220 self.toolBar.addSeparator()
201
221
202 self.actionPause.triggered.connect(self.changePauseIcon)
222 # self.actionPause.triggered.connect(self.changePauseIcon)
203 self.actionPauseToolbar.triggered.connect(self.changePauseIcon)
223 # self.actionPauseToolbar.triggered.connect(self.changePauseIcon)
204
224
205 self.menuProject.addAction(self.actionOpen)
225 self.menuProject.addAction(self.actionOpen)
206 self.menuProject.addAction(self.actionCreate)
226 self.menuProject.addAction(self.actionCreate)
@@ -265,12 +285,14 class Ui_EnvWindow(object):
265 event.ignore()
285 event.ignore()
266
286
267 def aboutEvent(self):
287 def aboutEvent(self):
288 title = "Signal Chain Processing Software v%s" %__version__
289 message = """
290 Developed by Jicamarca Radio Observatory
291 Any comment to miguel.urco@jro.igp.gob.pe
292 """
268
293
269 reply = QtGui.QMessageBox.information(self,
294 QtGui.QMessageBox.about(self, title, message)
270 'About',
295
271 "Signal Chain Processing Software v%s" %__version__,
272 "Developed by Jicamarca Radio Observatory\nComments to miguel.urco@jro.igp.gob.pe")
273
274
296
275 class Ui_BasicWindow(Ui_EnvWindow, Ui_ProjectTab, Ui_VoltageTab, Ui_SpectraTab, Ui_SpectraHeisTab, Ui_CorrelationTab):
297 class Ui_BasicWindow(Ui_EnvWindow, Ui_ProjectTab, Ui_VoltageTab, Ui_SpectraTab, Ui_SpectraHeisTab, Ui_CorrelationTab):
276
298
1 NO CONTENT: file was removed, binary diff hidden
NO CONTENT: file was removed, binary diff hidden
1 NO CONTENT: file was removed, binary diff hidden
NO CONTENT: file was removed, binary diff hidden
1 NO CONTENT: file was removed, binary diff hidden
NO CONTENT: file was removed, binary diff hidden
1 NO CONTENT: file was removed, binary diff hidden
NO CONTENT: file was removed, binary diff hidden
1 NO CONTENT: file was removed, binary diff hidden
NO CONTENT: file was removed, binary diff hidden
1 NO CONTENT: file was removed, binary diff hidden
NO CONTENT: file was removed, binary diff hidden
1 NO CONTENT: file was removed, binary diff hidden
NO CONTENT: file was removed, binary diff hidden
1 NO CONTENT: file was removed, binary diff hidden
NO CONTENT: file was removed, binary diff hidden
1 NO CONTENT: file was removed, binary diff hidden
NO CONTENT: file was removed, binary diff hidden
General Comments 0
You need to be logged in to leave comments. Login now