This diff has been collapsed as it changes many lines, (739 lines changed) Show them Hide them | |||||
@@ -0,0 +1,739 | |||||
|
1 | ''' | |||
|
2 | Created on September , 2012 | |||
|
3 | @author: | |||
|
4 | ''' | |||
|
5 | from xml.etree.ElementTree import Element, SubElement, ElementTree | |||
|
6 | from xml.etree import ElementTree as ET | |||
|
7 | from xml.dom import minidom | |||
|
8 | ||||
|
9 | #import sys | |||
|
10 | #import datetime | |||
|
11 | #from model.jrodataIO import * | |||
|
12 | #from model.jroprocessing import * | |||
|
13 | #from model.jroplot import * | |||
|
14 | ||||
|
15 | def prettify(elem): | |||
|
16 | """Return a pretty-printed XML string for the Element. | |||
|
17 | """ | |||
|
18 | rough_string = ET.tostring(elem, 'utf-8') | |||
|
19 | reparsed = minidom.parseString(rough_string) | |||
|
20 | return reparsed.toprettyxml(indent=" ") | |||
|
21 | ||||
|
22 | class ParameterConf(): | |||
|
23 | ||||
|
24 | id = None | |||
|
25 | name = None | |||
|
26 | value = None | |||
|
27 | format = None | |||
|
28 | ||||
|
29 | ELEMENTNAME = 'Parameter' | |||
|
30 | ||||
|
31 | def __init__(self): | |||
|
32 | ||||
|
33 | self.format = 'str' | |||
|
34 | ||||
|
35 | def getElementName(self): | |||
|
36 | ||||
|
37 | return self.ELEMENTNAME | |||
|
38 | ||||
|
39 | def getValue(self): | |||
|
40 | ||||
|
41 | value = self.value | |||
|
42 | ||||
|
43 | if self.format == 'list': | |||
|
44 | strList = value.split(',') | |||
|
45 | return strList | |||
|
46 | ||||
|
47 | if self.format == 'intlist': | |||
|
48 | strList = value.split(',') | |||
|
49 | intList = [int(x) for x in strList] | |||
|
50 | return intList | |||
|
51 | ||||
|
52 | if self.format == 'floatlist': | |||
|
53 | strList = value.split(',') | |||
|
54 | floatList = [float(x) for x in strList] | |||
|
55 | return floatList | |||
|
56 | ||||
|
57 | if self.format == 'date': | |||
|
58 | strList = value.split('/') | |||
|
59 | intList = [int(x) for x in strList] | |||
|
60 | date = datetime.date(intList[0], intList[1], intList[2]) | |||
|
61 | return date | |||
|
62 | ||||
|
63 | if self.format == 'time': | |||
|
64 | strList = value.split(':') | |||
|
65 | intList = [int(x) for x in strList] | |||
|
66 | time = datetime.time(intList[0], intList[1], intList[2]) | |||
|
67 | return time | |||
|
68 | ||||
|
69 | if self.format == 'bool': | |||
|
70 | value = int(value) | |||
|
71 | ||||
|
72 | if self.format == 'pairslist': | |||
|
73 | """ | |||
|
74 | Example: | |||
|
75 | value = (0,1),(1,2) | |||
|
76 | """ | |||
|
77 | ||||
|
78 | value = value.replace('(', '') | |||
|
79 | value = value.replace(')', '') | |||
|
80 | ||||
|
81 | strList = value.split(',') | |||
|
82 | intList = [int(item) for item in strList] | |||
|
83 | pairList = [] | |||
|
84 | for i in range(len(intList)/2): | |||
|
85 | pairList.append((intList[i*2], intList[i*2 + 1])) | |||
|
86 | ||||
|
87 | return pairList | |||
|
88 | ||||
|
89 | func = eval(self.format) | |||
|
90 | ||||
|
91 | return func(value) | |||
|
92 | ||||
|
93 | def setup(self, id, name, value, format='str'): | |||
|
94 | ||||
|
95 | self.id = id | |||
|
96 | self.name = name | |||
|
97 | self.value = str(value) | |||
|
98 | self.format = format | |||
|
99 | ||||
|
100 | def makeXml(self, opElement): | |||
|
101 | ||||
|
102 | parmElement = SubElement(opElement, self.ELEMENTNAME) | |||
|
103 | parmElement.set('id', str(self.id)) | |||
|
104 | parmElement.set('name', self.name) | |||
|
105 | parmElement.set('value', self.value) | |||
|
106 | parmElement.set('format', self.format) | |||
|
107 | ||||
|
108 | def readXml(self, parmElement): | |||
|
109 | ||||
|
110 | self.id = parmElement.get('id') | |||
|
111 | self.name = parmElement.get('name') | |||
|
112 | self.value = parmElement.get('value') | |||
|
113 | self.format = parmElement.get('format') | |||
|
114 | ||||
|
115 | def printattr(self): | |||
|
116 | ||||
|
117 | print "Parameter[%s]: name = %s, value = %s, format = %s" %(self.id, self.name, self.value, self.format) | |||
|
118 | ||||
|
119 | class OperationConf(): | |||
|
120 | ||||
|
121 | id = None | |||
|
122 | name = None | |||
|
123 | priority = None | |||
|
124 | type = None | |||
|
125 | ||||
|
126 | parmConfObjList = [] | |||
|
127 | ||||
|
128 | ELEMENTNAME = 'Operation' | |||
|
129 | ||||
|
130 | def __init__(self): | |||
|
131 | ||||
|
132 | id = 0 | |||
|
133 | name = None | |||
|
134 | priority = None | |||
|
135 | type = 'self' | |||
|
136 | ||||
|
137 | ||||
|
138 | def __getNewId(self): | |||
|
139 | ||||
|
140 | return int(self.id)*10 + len(self.parmConfObjList) + 1 | |||
|
141 | ||||
|
142 | def getElementName(self): | |||
|
143 | ||||
|
144 | return self.ELEMENTNAME | |||
|
145 | ||||
|
146 | def getParameterObjList(self): | |||
|
147 | ||||
|
148 | return self.parmConfObjList | |||
|
149 | ||||
|
150 | def setup(self, id, name, priority, type): | |||
|
151 | ||||
|
152 | self.id = id | |||
|
153 | self.name = name | |||
|
154 | self.type = type | |||
|
155 | self.priority = priority | |||
|
156 | ||||
|
157 | self.parmConfObjList = [] | |||
|
158 | ||||
|
159 | def addParameter(self, name, value, format='str'): | |||
|
160 | ||||
|
161 | id = self.__getNewId() | |||
|
162 | ||||
|
163 | parmConfObj = ParameterConf() | |||
|
164 | parmConfObj.setup(id, name, value, format) | |||
|
165 | ||||
|
166 | self.parmConfObjList.append(parmConfObj) | |||
|
167 | ||||
|
168 | return parmConfObj | |||
|
169 | ||||
|
170 | def makeXml(self, upElement): | |||
|
171 | ||||
|
172 | opElement = SubElement(upElement, self.ELEMENTNAME) | |||
|
173 | opElement.set('id', str(self.id)) | |||
|
174 | opElement.set('name', self.name) | |||
|
175 | opElement.set('type', self.type) | |||
|
176 | opElement.set('priority', str(self.priority)) | |||
|
177 | ||||
|
178 | for parmConfObj in self.parmConfObjList: | |||
|
179 | parmConfObj.makeXml(opElement) | |||
|
180 | ||||
|
181 | def readXml(self, opElement): | |||
|
182 | ||||
|
183 | self.id = opElement.get('id') | |||
|
184 | self.name = opElement.get('name') | |||
|
185 | self.type = opElement.get('type') | |||
|
186 | self.priority = opElement.get('priority') | |||
|
187 | ||||
|
188 | self.parmConfObjList = [] | |||
|
189 | ||||
|
190 | parmElementList = opElement.getiterator(ParameterConf().getElementName()) | |||
|
191 | ||||
|
192 | for parmElement in parmElementList: | |||
|
193 | parmConfObj = ParameterConf() | |||
|
194 | parmConfObj.readXml(parmElement) | |||
|
195 | self.parmConfObjList.append(parmConfObj) | |||
|
196 | ||||
|
197 | def printattr(self): | |||
|
198 | ||||
|
199 | print "%s[%s]: name = %s, type = %s, priority = %s" %(self.ELEMENTNAME, | |||
|
200 | self.id, | |||
|
201 | self.name, | |||
|
202 | self.type, | |||
|
203 | self.priority) | |||
|
204 | ||||
|
205 | for parmConfObj in self.parmConfObjList: | |||
|
206 | parmConfObj.printattr() | |||
|
207 | ||||
|
208 | def createObject(self): | |||
|
209 | ||||
|
210 | if self.type == 'self': | |||
|
211 | raise ValueError, "This operation type cannot be created" | |||
|
212 | ||||
|
213 | if self.type == 'other': | |||
|
214 | className = eval(self.name) | |||
|
215 | opObj = className() | |||
|
216 | ||||
|
217 | return opObj | |||
|
218 | ||||
|
219 | class ProcUnitConf(): | |||
|
220 | ||||
|
221 | id = None | |||
|
222 | name = None | |||
|
223 | datatype = None | |||
|
224 | inputId = None | |||
|
225 | arbol=None | |||
|
226 | ||||
|
227 | opConfObjList = [] | |||
|
228 | ||||
|
229 | procUnitObj = None | |||
|
230 | opObjList = [] | |||
|
231 | ||||
|
232 | ELEMENTNAME = 'ProcUnit' | |||
|
233 | ||||
|
234 | def __init__(self): | |||
|
235 | ||||
|
236 | self.id = None | |||
|
237 | self.datatype = None | |||
|
238 | self.name = None | |||
|
239 | self.inputId = None | |||
|
240 | self.arbol=None | |||
|
241 | ||||
|
242 | self.opConfObjList = [] | |||
|
243 | ||||
|
244 | self.procUnitObj = None | |||
|
245 | self.opObjDict = {} | |||
|
246 | ||||
|
247 | def __getPriority(self): | |||
|
248 | ||||
|
249 | return len(self.opConfObjList)+1 | |||
|
250 | ||||
|
251 | def __getNewId(self): | |||
|
252 | ||||
|
253 | return int(self.id)*10 + len(self.opConfObjList) + 1 | |||
|
254 | ||||
|
255 | def getElementName(self): | |||
|
256 | ||||
|
257 | return self.ELEMENTNAME | |||
|
258 | ||||
|
259 | def getId(self): | |||
|
260 | ||||
|
261 | return str(self.id) | |||
|
262 | ||||
|
263 | def getInputId(self): | |||
|
264 | ||||
|
265 | return str(self.inputId) | |||
|
266 | ||||
|
267 | def getOperationObjList(self): | |||
|
268 | ||||
|
269 | return self.opConfObjList | |||
|
270 | ||||
|
271 | def getProcUnitObj(self): | |||
|
272 | ||||
|
273 | return self.procUnitObj | |||
|
274 | ||||
|
275 | def setup(self, id, name, datatype, inputId): | |||
|
276 | ||||
|
277 | self.id = id | |||
|
278 | self.name = name | |||
|
279 | self.datatype = datatype | |||
|
280 | self.inputId = inputId | |||
|
281 | ||||
|
282 | self.opConfObjList = [] | |||
|
283 | ||||
|
284 | self.addOperation(name='init', optype='self') | |||
|
285 | ||||
|
286 | def addParameter(self, **kwargs): | |||
|
287 | ||||
|
288 | opObj = self.opConfObjList[0] | |||
|
289 | ||||
|
290 | opObj.addParameter(**kwargs) | |||
|
291 | ||||
|
292 | return opObj | |||
|
293 | ||||
|
294 | def addOperation(self, name, optype='self'): | |||
|
295 | ||||
|
296 | id = self.__getNewId() | |||
|
297 | priority = self.__getPriority() | |||
|
298 | ||||
|
299 | opConfObj = OperationConf() | |||
|
300 | opConfObj.setup(id, name=name, priority=priority, type=optype) | |||
|
301 | ||||
|
302 | self.opConfObjList.append(opConfObj) | |||
|
303 | ||||
|
304 | return opConfObj | |||
|
305 | ||||
|
306 | def makeXml(self, procUnitElement): | |||
|
307 | ||||
|
308 | upElement = SubElement(procUnitElement, self.ELEMENTNAME) | |||
|
309 | upElement.set('id', str(self.id)) | |||
|
310 | upElement.set('name', self.name) | |||
|
311 | upElement.set('datatype', self.datatype) | |||
|
312 | upElement.set('inputId', str(self.inputId)) | |||
|
313 | ||||
|
314 | for opConfObj in self.opConfObjList: | |||
|
315 | opConfObj.makeXml(upElement) | |||
|
316 | ||||
|
317 | def readXml(self, upElement): | |||
|
318 | ||||
|
319 | self.id = upElement.get('id') | |||
|
320 | self.name = upElement.get('name') | |||
|
321 | self.datatype = upElement.get('datatype') | |||
|
322 | self.inputId = upElement.get('inputId') | |||
|
323 | ||||
|
324 | self.opConfObjList = [] | |||
|
325 | ||||
|
326 | opElementList = upElement.getiterator(OperationConf().getElementName()) | |||
|
327 | ||||
|
328 | for opElement in opElementList: | |||
|
329 | opConfObj = OperationConf() | |||
|
330 | opConfObj.readXml(opElement) | |||
|
331 | self.opConfObjList.append(opConfObj) | |||
|
332 | ||||
|
333 | def printattr(self): | |||
|
334 | ||||
|
335 | print "%s[%s]: name = %s, datatype = %s, inputId = %s" %(self.ELEMENTNAME, | |||
|
336 | self.id, | |||
|
337 | self.name, | |||
|
338 | self.datatype, | |||
|
339 | self.inputId) | |||
|
340 | ||||
|
341 | for opConfObj in self.opConfObjList: | |||
|
342 | opConfObj.printattr() | |||
|
343 | ||||
|
344 | def createObjects(self): | |||
|
345 | ||||
|
346 | className = eval(self.name) | |||
|
347 | procUnitObj = className() | |||
|
348 | ||||
|
349 | for opConfObj in self.opConfObjList: | |||
|
350 | ||||
|
351 | if opConfObj.type == 'self': | |||
|
352 | continue | |||
|
353 | ||||
|
354 | opObj = opConfObj.createObject() | |||
|
355 | ||||
|
356 | self.opObjDict[opConfObj.id] = opObj | |||
|
357 | procUnitObj.addOperation(opObj, opConfObj.id) | |||
|
358 | ||||
|
359 | self.procUnitObj = procUnitObj | |||
|
360 | ||||
|
361 | return procUnitObj | |||
|
362 | ||||
|
363 | def run(self): | |||
|
364 | ||||
|
365 | finalSts = False | |||
|
366 | ||||
|
367 | for opConfObj in self.opConfObjList: | |||
|
368 | ||||
|
369 | kwargs = {} | |||
|
370 | for parmConfObj in opConfObj.getParameterObjList(): | |||
|
371 | kwargs[parmConfObj.name] = parmConfObj.getValue() | |||
|
372 | ||||
|
373 | #print "\tRunning the '%s' operation with %s" %(opConfObj.name, opConfObj.id) | |||
|
374 | sts = self.procUnitObj.call(opConfObj, **kwargs) | |||
|
375 | finalSts = finalSts or sts | |||
|
376 | ||||
|
377 | return finalSts | |||
|
378 | ||||
|
379 | class ReadUnitConf(ProcUnitConf): | |||
|
380 | ||||
|
381 | path = None | |||
|
382 | startDate = None | |||
|
383 | endDate = None | |||
|
384 | startTime = None | |||
|
385 | endTime = None | |||
|
386 | ||||
|
387 | ELEMENTNAME = 'ReadUnit' | |||
|
388 | ||||
|
389 | def __init__(self): | |||
|
390 | ||||
|
391 | self.id = None | |||
|
392 | self.datatype = None | |||
|
393 | self.name = None | |||
|
394 | self.inputId = 0 | |||
|
395 | ||||
|
396 | self.opConfObjList = [] | |||
|
397 | self.opObjList = [] | |||
|
398 | ||||
|
399 | def getElementName(self): | |||
|
400 | ||||
|
401 | return self.ELEMENTNAME | |||
|
402 | ||||
|
403 | def setup(self, id, name, datatype, path, startDate, endDate, startTime, endTime, **kwargs): | |||
|
404 | ||||
|
405 | self.id = id | |||
|
406 | self.name = name | |||
|
407 | self.datatype = datatype | |||
|
408 | ||||
|
409 | self.path = path | |||
|
410 | self.startDate = startDate | |||
|
411 | self.endDate = endDate | |||
|
412 | self.startTime = startTime | |||
|
413 | self.endTime = endTime | |||
|
414 | ||||
|
415 | self.addRunOperation(**kwargs) | |||
|
416 | ||||
|
417 | def addRunOperation(self, **kwargs): | |||
|
418 | ||||
|
419 | opObj = self.addOperation(name = 'run', optype = 'self') | |||
|
420 | ||||
|
421 | opObj.addParameter(name='path' , value=self.path, format='str') | |||
|
422 | opObj.addParameter(name='startDate' , value=self.startDate, format='date') | |||
|
423 | opObj.addParameter(name='endDate' , value=self.endDate, format='date') | |||
|
424 | opObj.addParameter(name='startTime' , value=self.startTime, format='time') | |||
|
425 | opObj.addParameter(name='endTime' , value=self.endTime, format='time') | |||
|
426 | ||||
|
427 | for key, value in kwargs.items(): | |||
|
428 | opObj.addParameter(name=key, value=value, format=type(value).__name__) | |||
|
429 | ||||
|
430 | return opObj | |||
|
431 | ||||
|
432 | ||||
|
433 | class Project(): | |||
|
434 | ||||
|
435 | id = None | |||
|
436 | name = None | |||
|
437 | description = None | |||
|
438 | arbol=None | |||
|
439 | # readUnitConfObjList = None | |||
|
440 | procUnitConfObjDict = None | |||
|
441 | ||||
|
442 | ELEMENTNAME = 'Project' | |||
|
443 | ||||
|
444 | def __init__(self): | |||
|
445 | ||||
|
446 | self.id = None | |||
|
447 | self.name = None | |||
|
448 | self.description = None | |||
|
449 | self.arbol=None | |||
|
450 | # self.readUnitConfObjList = [] | |||
|
451 | self.procUnitConfObjDict = {} | |||
|
452 | ||||
|
453 | def __getNewId(self): | |||
|
454 | ||||
|
455 | id = int(self.id)*10 + len(self.procUnitConfObjDict) + 1 | |||
|
456 | ||||
|
457 | return str(id) | |||
|
458 | ||||
|
459 | def getElementName(self): | |||
|
460 | ||||
|
461 | return self.ELEMENTNAME | |||
|
462 | ||||
|
463 | def setup(self, id, name, description): | |||
|
464 | ||||
|
465 | self.id = id | |||
|
466 | self.name = name | |||
|
467 | self.description = description | |||
|
468 | ||||
|
469 | def addReadUnit(self, datatype, path, startDate='', endDate='', startTime='', endTime='', **kwargs): | |||
|
470 | ||||
|
471 | id = self.__getNewId() | |||
|
472 | name = '%sReader' %(datatype) | |||
|
473 | ||||
|
474 | readUnitConfObj = ReadUnitConf() | |||
|
475 | readUnitConfObj.setup(id, name, datatype, path, startDate, endDate, startTime, endTime, **kwargs) | |||
|
476 | ||||
|
477 | self.procUnitConfObjDict[readUnitConfObj.getId()] = readUnitConfObj | |||
|
478 | ||||
|
479 | return readUnitConfObj | |||
|
480 | ||||
|
481 | def addProcUnit(self, datatype, inputId): | |||
|
482 | ||||
|
483 | id = self.__getNewId() | |||
|
484 | name = '%sProc' %(datatype) | |||
|
485 | ||||
|
486 | procUnitConfObj = ProcUnitConf() | |||
|
487 | procUnitConfObj.setup(id, name, datatype, inputId) | |||
|
488 | ||||
|
489 | self.procUnitConfObjDict[procUnitConfObj.getId()] = procUnitConfObj | |||
|
490 | ||||
|
491 | return procUnitConfObj | |||
|
492 | ||||
|
493 | def makeXml(self): | |||
|
494 | ||||
|
495 | projectElement = Element('Project') | |||
|
496 | projectElement.set('id', str(self.id)) | |||
|
497 | projectElement.set('name', self.name) | |||
|
498 | projectElement.set('description', self.description) | |||
|
499 | ||||
|
500 | # for readUnitConfObj in self.readUnitConfObjList: | |||
|
501 | # readUnitConfObj.makeXml(projectElement) | |||
|
502 | ||||
|
503 | for procUnitConfObj in self.procUnitConfObjDict.values(): | |||
|
504 | procUnitConfObj.makeXml(projectElement) | |||
|
505 | ||||
|
506 | self.projectElement = projectElement | |||
|
507 | ||||
|
508 | def writeXml(self, filename): | |||
|
509 | ||||
|
510 | self.makeXml() | |||
|
511 | ||||
|
512 | print prettify(self.projectElement) | |||
|
513 | ||||
|
514 | ElementTree(self.projectElement).write(filename, method='xml') | |||
|
515 | ||||
|
516 | def readXml(self, filename): | |||
|
517 | ||||
|
518 | #tree = ET.parse(filename) | |||
|
519 | self.projectElement = None | |||
|
520 | # self.readUnitConfObjList = [] | |||
|
521 | self.procUnitConfObjDict = {} | |||
|
522 | ||||
|
523 | self.projectElement = ElementTree().parse(filename) | |||
|
524 | ||||
|
525 | self.project = self.projectElement.tag | |||
|
526 | ||||
|
527 | self.id = self.projectElement.get('id') | |||
|
528 | self.name = self.projectElement.get('name') | |||
|
529 | self.description = self.projectElement.get('description') | |||
|
530 | ||||
|
531 | readUnitElementList = self.projectElement.getiterator(ReadUnitConf().getElementName()) | |||
|
532 | ||||
|
533 | for readUnitElement in readUnitElementList: | |||
|
534 | readUnitConfObj = ReadUnitConf() | |||
|
535 | readUnitConfObj.readXml(readUnitElement) | |||
|
536 | ||||
|
537 | self.procUnitConfObjDict[readUnitConfObj.getId()] = readUnitConfObj | |||
|
538 | ||||
|
539 | procUnitElementList = self.projectElement.getiterator(ProcUnitConf().getElementName()) | |||
|
540 | ||||
|
541 | for procUnitElement in procUnitElementList: | |||
|
542 | procUnitConfObj = ProcUnitConf() | |||
|
543 | procUnitConfObj.readXml(procUnitElement) | |||
|
544 | ||||
|
545 | self.procUnitConfObjDict[procUnitConfObj.getId()] = procUnitConfObj | |||
|
546 | ||||
|
547 | def printattr(self): | |||
|
548 | ||||
|
549 | print "Project[%s]: name = %s, description = %s" %(self.id, | |||
|
550 | self.name, | |||
|
551 | self.description) | |||
|
552 | ||||
|
553 | # for readUnitConfObj in self.readUnitConfObjList: | |||
|
554 | # readUnitConfObj.printattr() | |||
|
555 | ||||
|
556 | for procUnitConfObj in self.procUnitConfObjDict.values(): | |||
|
557 | procUnitConfObj.printattr() | |||
|
558 | ||||
|
559 | def createObjects(self): | |||
|
560 | ||||
|
561 | # for readUnitConfObj in self.readUnitConfObjList: | |||
|
562 | # readUnitConfObj.createObjects() | |||
|
563 | ||||
|
564 | for procUnitConfObj in self.procUnitConfObjDict.values(): | |||
|
565 | procUnitConfObj.createObjects() | |||
|
566 | ||||
|
567 | def __connect(self, objIN, obj): | |||
|
568 | ||||
|
569 | obj.setInput(objIN.getOutput()) | |||
|
570 | ||||
|
571 | def connectObjects(self): | |||
|
572 | ||||
|
573 | for puConfObj in self.procUnitConfObjDict.values(): | |||
|
574 | ||||
|
575 | inputId = puConfObj.getInputId() | |||
|
576 | ||||
|
577 | if int(inputId) == 0: | |||
|
578 | continue | |||
|
579 | ||||
|
580 | puConfINObj = self.procUnitConfObjDict[inputId] | |||
|
581 | ||||
|
582 | puObj = puConfObj.getProcUnitObj() | |||
|
583 | puINObj = puConfINObj.getProcUnitObj() | |||
|
584 | ||||
|
585 | self.__connect(puINObj, puObj) | |||
|
586 | ||||
|
587 | def run(self): | |||
|
588 | ||||
|
589 | # for readUnitConfObj in self.readUnitConfObjList: | |||
|
590 | # readUnitConfObj.run() | |||
|
591 | ||||
|
592 | while(True): | |||
|
593 | ||||
|
594 | finalSts = False | |||
|
595 | ||||
|
596 | for procUnitConfObj in self.procUnitConfObjDict.values(): | |||
|
597 | #print "Running the '%s' process with %s" %(procUnitConfObj.name, procUnitConfObj.id) | |||
|
598 | sts = procUnitConfObj.run() | |||
|
599 | finalSts = finalSts or sts | |||
|
600 | ||||
|
601 | #If every process unit finished so end process | |||
|
602 | if not(finalSts): | |||
|
603 | print "Every process units have finished" | |||
|
604 | break | |||
|
605 | ||||
|
606 | if __name__ == '__main__': | |||
|
607 | ||||
|
608 | desc = "Segundo Test" | |||
|
609 | filename = "schain.xml" | |||
|
610 | ||||
|
611 | controllerObj = Project() | |||
|
612 | ||||
|
613 | controllerObj.setup(id = '191', name='test01', description=desc) | |||
|
614 | ||||
|
615 | readUnitConfObj = controllerObj.addReadUnit(datatype='Voltage', | |||
|
616 | path='data/rawdata/', | |||
|
617 | startDate='2011/01/01', | |||
|
618 | endDate='2012/12/31', | |||
|
619 | startTime='00:00:00', | |||
|
620 | endTime='23:59:59', | |||
|
621 | online=1, | |||
|
622 | walk=1) | |||
|
623 | ||||
|
624 | # opObj00 = readUnitConfObj.addOperation(name='printInfo') | |||
|
625 | ||||
|
626 | procUnitConfObj0 = controllerObj.addProcUnit(datatype='Voltage', inputId=readUnitConfObj.getId()) | |||
|
627 | ||||
|
628 | opObj10 = procUnitConfObj0.addOperation(name='selectChannels') | |||
|
629 | opObj10.addParameter(name='channelList', value='3,4,5', format='intlist') | |||
|
630 | ||||
|
631 | opObj10 = procUnitConfObj0.addOperation(name='selectHeights') | |||
|
632 | opObj10.addParameter(name='minHei', value='90', format='float') | |||
|
633 | opObj10.addParameter(name='maxHei', value='180', format='float') | |||
|
634 | ||||
|
635 | opObj12 = procUnitConfObj0.addOperation(name='CohInt', optype='other') | |||
|
636 | opObj12.addParameter(name='n', value='10', format='int') | |||
|
637 | ||||
|
638 | procUnitConfObj1 = controllerObj.addProcUnit(datatype='Spectra', inputId=procUnitConfObj0.getId()) | |||
|
639 | procUnitConfObj1.addParameter(name='nFFTPoints', value='32', format='int') | |||
|
640 | # procUnitConfObj1.addParameter(name='pairList', value='(0,1),(0,2),(1,2)', format='') | |||
|
641 | ||||
|
642 | ||||
|
643 | opObj11 = procUnitConfObj1.addOperation(name='SpectraPlot', optype='other') | |||
|
644 | opObj11.addParameter(name='idfigure', value='1', format='int') | |||
|
645 | opObj11.addParameter(name='wintitle', value='SpectraPlot0', format='str') | |||
|
646 | opObj11.addParameter(name='zmin', value='40', format='int') | |||
|
647 | opObj11.addParameter(name='zmax', value='90', format='int') | |||
|
648 | opObj11.addParameter(name='showprofile', value='1', format='int') | |||
|
649 | ||||
|
650 | # opObj11 = procUnitConfObj1.addOperation(name='CrossSpectraPlot', optype='other') | |||
|
651 | # opObj11.addParameter(name='idfigure', value='2', format='int') | |||
|
652 | # opObj11.addParameter(name='wintitle', value='CrossSpectraPlot', format='str') | |||
|
653 | # opObj11.addParameter(name='zmin', value='40', format='int') | |||
|
654 | # opObj11.addParameter(name='zmax', value='90', format='int') | |||
|
655 | ||||
|
656 | ||||
|
657 | # procUnitConfObj2 = controllerObj.addProcUnit(datatype='Voltage', inputId=procUnitConfObj0.getId()) | |||
|
658 | # | |||
|
659 | # opObj12 = procUnitConfObj2.addOperation(name='CohInt', optype='other') | |||
|
660 | # opObj12.addParameter(name='n', value='2', format='int') | |||
|
661 | # opObj12.addParameter(name='overlapping', value='1', format='int') | |||
|
662 | # | |||
|
663 | # procUnitConfObj3 = controllerObj.addProcUnit(datatype='Spectra', inputId=procUnitConfObj2.getId()) | |||
|
664 | # procUnitConfObj3.addParameter(name='nFFTPoints', value='32', format='int') | |||
|
665 | # | |||
|
666 | # opObj11 = procUnitConfObj3.addOperation(name='SpectraPlot', optype='other') | |||
|
667 | # opObj11.addParameter(name='idfigure', value='2', format='int') | |||
|
668 | # opObj11.addParameter(name='wintitle', value='SpectraPlot1', format='str') | |||
|
669 | # opObj11.addParameter(name='zmin', value='40', format='int') | |||
|
670 | # opObj11.addParameter(name='zmax', value='90', format='int') | |||
|
671 | # opObj11.addParameter(name='showprofile', value='1', format='int') | |||
|
672 | ||||
|
673 | # opObj11 = procUnitConfObj1.addOperation(name='RTIPlot', optype='other') | |||
|
674 | # opObj11.addParameter(name='idfigure', value='10', format='int') | |||
|
675 | # opObj11.addParameter(name='wintitle', value='RTI', format='str') | |||
|
676 | ## opObj11.addParameter(name='xmin', value='21', format='float') | |||
|
677 | ## opObj11.addParameter(name='xmax', value='22', format='float') | |||
|
678 | # opObj11.addParameter(name='zmin', value='40', format='int') | |||
|
679 | # opObj11.addParameter(name='zmax', value='90', format='int') | |||
|
680 | # opObj11.addParameter(name='showprofile', value='1', format='int') | |||
|
681 | # opObj11.addParameter(name='timerange', value=str(60), format='int') | |||
|
682 | ||||
|
683 | # opObj10 = procUnitConfObj1.addOperation(name='selectChannels') | |||
|
684 | # opObj10.addParameter(name='channelList', value='0,2,4,6', format='intlist') | |||
|
685 | # | |||
|
686 | # opObj12 = procUnitConfObj1.addOperation(name='IncohInt', optype='other') | |||
|
687 | # opObj12.addParameter(name='n', value='2', format='int') | |||
|
688 | # | |||
|
689 | # opObj11 = procUnitConfObj1.addOperation(name='SpectraPlot', optype='other') | |||
|
690 | # opObj11.addParameter(name='idfigure', value='2', format='int') | |||
|
691 | # opObj11.addParameter(name='wintitle', value='SpectraPlot10', format='str') | |||
|
692 | # opObj11.addParameter(name='zmin', value='70', format='int') | |||
|
693 | # opObj11.addParameter(name='zmax', value='90', format='int') | |||
|
694 | # | |||
|
695 | # opObj10 = procUnitConfObj1.addOperation(name='selectChannels') | |||
|
696 | # opObj10.addParameter(name='channelList', value='2,6', format='intlist') | |||
|
697 | # | |||
|
698 | # opObj12 = procUnitConfObj1.addOperation(name='IncohInt', optype='other') | |||
|
699 | # opObj12.addParameter(name='n', value='2', format='int') | |||
|
700 | # | |||
|
701 | # opObj11 = procUnitConfObj1.addOperation(name='SpectraPlot', optype='other') | |||
|
702 | # opObj11.addParameter(name='idfigure', value='3', format='int') | |||
|
703 | # opObj11.addParameter(name='wintitle', value='SpectraPlot10', format='str') | |||
|
704 | # opObj11.addParameter(name='zmin', value='70', format='int') | |||
|
705 | # opObj11.addParameter(name='zmax', value='90', format='int') | |||
|
706 | ||||
|
707 | ||||
|
708 | # opObj12 = procUnitConfObj1.addOperation(name='decoder') | |||
|
709 | # opObj12.addParameter(name='ncode', value='2', format='int') | |||
|
710 | # opObj12.addParameter(name='nbauds', value='8', format='int') | |||
|
711 | # opObj12.addParameter(name='code0', value='001110011', format='int') | |||
|
712 | # opObj12.addParameter(name='code1', value='001110011', format='int') | |||
|
713 | ||||
|
714 | ||||
|
715 | ||||
|
716 | # procUnitConfObj2 = controllerObj.addProcUnit(datatype='Spectra', inputId=procUnitConfObj1.getId()) | |||
|
717 | # | |||
|
718 | # opObj21 = procUnitConfObj2.addOperation(name='IncohInt', optype='other') | |||
|
719 | # opObj21.addParameter(name='n', value='2', format='int') | |||
|
720 | # | |||
|
721 | # opObj11 = procUnitConfObj2.addOperation(name='SpectraPlot', optype='other') | |||
|
722 | # opObj11.addParameter(name='idfigure', value='4', format='int') | |||
|
723 | # opObj11.addParameter(name='wintitle', value='SpectraPlot OBJ 2', format='str') | |||
|
724 | # opObj11.addParameter(name='zmin', value='70', format='int') | |||
|
725 | # opObj11.addParameter(name='zmax', value='90', format='int') | |||
|
726 | ||||
|
727 | print "Escribiendo el archivo XML" | |||
|
728 | ||||
|
729 | controllerObj.writeXml(filename) | |||
|
730 | ||||
|
731 | print "Leyendo el archivo XML" | |||
|
732 | controllerObj.readXml(filename) | |||
|
733 | #controllerObj.printattr() | |||
|
734 | ||||
|
735 | controllerObj.createObjects() | |||
|
736 | controllerObj.connectObjects() | |||
|
737 | controllerObj.run() | |||
|
738 | ||||
|
739 | No newline at end of file |
@@ -0,0 +1,58 | |||||
|
1 | # -*- coding: utf-8 -*- | |||
|
2 | ||||
|
3 | """ | |||
|
4 | Module implementing MainWindow. | |||
|
5 | """ | |||
|
6 | ||||
|
7 | from PyQt4.QtGui import QMainWindow | |||
|
8 | from PyQt4.QtCore import pyqtSignature | |||
|
9 | ||||
|
10 | from viewer.ui_unitprocess import Ui_UnitProcess | |||
|
11 | ||||
|
12 | class UnitProcess(QMainWindow, Ui_UnitProcess): | |||
|
13 | """ | |||
|
14 | Class documentation goes here. | |||
|
15 | """ | |||
|
16 | ||||
|
17 | def __init__(self, parent = None): | |||
|
18 | """ | |||
|
19 | Constructor | |||
|
20 | """ | |||
|
21 | QMainWindow.__init__(self, parent) | |||
|
22 | self.setupUi(self) | |||
|
23 | ||||
|
24 | ||||
|
25 | @pyqtSignature("QString") | |||
|
26 | def on_comboInputBox_activated(self, p0): | |||
|
27 | """ | |||
|
28 | Slot documentation goes here. | |||
|
29 | """ | |||
|
30 | # TODO: not implemented yet | |||
|
31 | raise NotImplementedError | |||
|
32 | ||||
|
33 | @pyqtSignature("QString") | |||
|
34 | def on_comboTypeBox_activated(self, p0): | |||
|
35 | """ | |||
|
36 | Slot documentation goes here. | |||
|
37 | """ | |||
|
38 | # TODO: not implemented yet | |||
|
39 | raise NotImplementedError | |||
|
40 | ||||
|
41 | ||||
|
42 | @pyqtSignature("") | |||
|
43 | def on_unitPokbut_clicked(self): | |||
|
44 | """ | |||
|
45 | Slot documentation goes here. | |||
|
46 | """ | |||
|
47 | # TODO: not implemented yet | |||
|
48 | #raise NotImplementedError | |||
|
49 | print "this is suspiscious" | |||
|
50 | print "njdasjdajj" | |||
|
51 | ||||
|
52 | @pyqtSignature("") | |||
|
53 | def on_unitPcancelbut_clicked(self): | |||
|
54 | """ | |||
|
55 | Slot documentation goes here. | |||
|
56 | """ | |||
|
57 | # TODO: not implemented yet | |||
|
58 | raise NotImplementedError |
@@ -0,0 +1,102 | |||||
|
1 | # -*- coding: utf-8 -*- | |||
|
2 | ||||
|
3 | # Form implementation generated from reading ui file 'C:\Users\alex\ericworkspace\UIDOS\unitProcess.ui' | |||
|
4 | # | |||
|
5 | # Created: Thu Dec 06 10:52:30 2012 | |||
|
6 | # by: PyQt4 UI code generator 4.9.4 | |||
|
7 | # | |||
|
8 | # WARNING! All changes made in this file will be lost! | |||
|
9 | ||||
|
10 | from PyQt4 import QtCore, QtGui | |||
|
11 | ||||
|
12 | try: | |||
|
13 | _fromUtf8 = QtCore.QString.fromUtf8 | |||
|
14 | except AttributeError: | |||
|
15 | _fromUtf8 = lambda s: s | |||
|
16 | ||||
|
17 | class Ui_UnitProcess(object): | |||
|
18 | def setupUi(self, MainWindow): | |||
|
19 | MainWindow.setObjectName(_fromUtf8("MainWindow")) | |||
|
20 | MainWindow.resize(207, 181) | |||
|
21 | self.centralWidget = QtGui.QWidget(MainWindow) | |||
|
22 | self.centralWidget.setObjectName(_fromUtf8("centralWidget")) | |||
|
23 | self.comboInputBox = QtGui.QComboBox(self.centralWidget) | |||
|
24 | self.comboInputBox.setGeometry(QtCore.QRect(80, 50, 111, 22)) | |||
|
25 | self.comboInputBox.setObjectName(_fromUtf8("comboInputBox")) | |||
|
26 | self.comboTypeBox = QtGui.QComboBox(self.centralWidget) | |||
|
27 | self.comboTypeBox.setGeometry(QtCore.QRect(80, 90, 111, 22)) | |||
|
28 | self.comboTypeBox.setObjectName(_fromUtf8("comboTypeBox")) | |||
|
29 | self.comboTypeBox.addItem(_fromUtf8("")) | |||
|
30 | self.comboTypeBox.addItem(_fromUtf8("")) | |||
|
31 | self.comboTypeBox.addItem(_fromUtf8("")) | |||
|
32 | self.nameUP = QtGui.QLabel(self.centralWidget) | |||
|
33 | self.nameUP.setGeometry(QtCore.QRect(50, 20, 111, 21)) | |||
|
34 | font = QtGui.QFont() | |||
|
35 | font.setPointSize(10) | |||
|
36 | font.setBold(False) | |||
|
37 | font.setWeight(50) | |||
|
38 | self.nameUP.setFont(font) | |||
|
39 | self.nameUP.setObjectName(_fromUtf8("nameUP")) | |||
|
40 | self.inputLabel = QtGui.QLabel(self.centralWidget) | |||
|
41 | self.inputLabel.setGeometry(QtCore.QRect(20, 50, 51, 31)) | |||
|
42 | font = QtGui.QFont() | |||
|
43 | font.setPointSize(10) | |||
|
44 | font.setBold(False) | |||
|
45 | font.setWeight(50) | |||
|
46 | self.inputLabel.setFont(font) | |||
|
47 | self.inputLabel.setObjectName(_fromUtf8("inputLabel")) | |||
|
48 | self.typeLabel = QtGui.QLabel(self.centralWidget) | |||
|
49 | self.typeLabel.setGeometry(QtCore.QRect(20, 90, 51, 21)) | |||
|
50 | font = QtGui.QFont() | |||
|
51 | font.setPointSize(10) | |||
|
52 | font.setBold(False) | |||
|
53 | font.setWeight(50) | |||
|
54 | self.typeLabel.setFont(font) | |||
|
55 | self.typeLabel.setObjectName(_fromUtf8("typeLabel")) | |||
|
56 | self.unitPokbut = QtGui.QPushButton(self.centralWidget) | |||
|
57 | self.unitPokbut.setGeometry(QtCore.QRect(80, 130, 51, 23)) | |||
|
58 | font = QtGui.QFont() | |||
|
59 | font.setBold(False) | |||
|
60 | font.setWeight(50) | |||
|
61 | self.unitPokbut.setFont(font) | |||
|
62 | self.unitPokbut.setObjectName(_fromUtf8("unitPokbut")) | |||
|
63 | self.unitPcancelbut = QtGui.QPushButton(self.centralWidget) | |||
|
64 | self.unitPcancelbut.setGeometry(QtCore.QRect(140, 130, 51, 23)) | |||
|
65 | font = QtGui.QFont() | |||
|
66 | font.setBold(False) | |||
|
67 | font.setWeight(50) | |||
|
68 | self.unitPcancelbut.setFont(font) | |||
|
69 | self.unitPcancelbut.setObjectName(_fromUtf8("unitPcancelbut")) | |||
|
70 | self.unitPsavebut = QtGui.QPushButton(self.centralWidget) | |||
|
71 | self.unitPsavebut.setGeometry(QtCore.QRect(20, 130, 51, 23)) | |||
|
72 | font = QtGui.QFont() | |||
|
73 | font.setBold(False) | |||
|
74 | font.setWeight(50) | |||
|
75 | self.unitPsavebut.setFont(font) | |||
|
76 | self.unitPsavebut.setObjectName(_fromUtf8("unitPsavebut")) | |||
|
77 | MainWindow.setCentralWidget(self.centralWidget) | |||
|
78 | ||||
|
79 | self.retranslateUi(MainWindow) | |||
|
80 | QtCore.QMetaObject.connectSlotsByName(MainWindow) | |||
|
81 | ||||
|
82 | def retranslateUi(self, MainWindow): | |||
|
83 | MainWindow.setWindowTitle(QtGui.QApplication.translate("MainWindow", "MainWindow", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
84 | self.comboTypeBox.setItemText(0, QtGui.QApplication.translate("MainWindow", "Voltage", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
85 | self.comboTypeBox.setItemText(1, QtGui.QApplication.translate("MainWindow", "Spectra", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
86 | self.comboTypeBox.setItemText(2, QtGui.QApplication.translate("MainWindow", "Correlation", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
87 | self.nameUP.setText(QtGui.QApplication.translate("MainWindow", "PROCESSING UNIT", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
88 | self.inputLabel.setText(QtGui.QApplication.translate("MainWindow", "Input:", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
89 | self.typeLabel.setText(QtGui.QApplication.translate("MainWindow", "Type:", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
90 | self.unitPokbut.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
91 | self.unitPcancelbut.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
92 | self.unitPsavebut.setText(QtGui.QApplication.translate("MainWindow", "Save", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
93 | ||||
|
94 | ||||
|
95 | if __name__ == "__main__": | |||
|
96 | import sys | |||
|
97 | app = QtGui.QApplication(sys.argv) | |||
|
98 | MainWindow = QtGui.QMainWindow() | |||
|
99 | ui = Ui_UnitProcess() | |||
|
100 | ui.setupUi(MainWindow) | |||
|
101 | MainWindow.show() | |||
|
102 | sys.exit(app.exec_()) |
@@ -1,7 +1,7 | |||||
1 | #!/usr/bin/python |
|
1 | #!/usr/bin/python | |
2 | # -*- coding: utf-8 -*- |
|
2 | # -*- coding: utf-8 -*- | |
3 |
|
3 | |||
4 | #from PyQt4 import QtCore, QtGui |
|
4 | #from PyQt4 import QtCore, QtGuis | |
5 | from PyQt4.QtGui import QApplication |
|
5 | from PyQt4.QtGui import QApplication | |
6 | #from PyQt4.QtCore import pyqtSignature |
|
6 | #from PyQt4.QtCore import pyqtSignature | |
7 | #from Controller.workspace import Workspace |
|
7 | #from Controller.workspace import Workspace | |
@@ -9,12 +9,13 from PyQt4.QtGui import QApplication | |||||
9 | #from Controller.initwindow import InitWindow |
|
9 | #from Controller.initwindow import InitWindow | |
10 | #from Controller.window import window |
|
10 | #from Controller.window import window | |
11 | from viewcontroller.mainwindow import MainWindow |
|
11 | from viewcontroller.mainwindow import MainWindow | |
12 | #import time |
|
12 | #from viewcontroller.mainwindow2 import UnitProcess | |
13 |
|
13 | |||
14 | def main(): |
|
14 | def main(): | |
15 | import sys |
|
15 | import sys | |
16 | app = QApplication(sys.argv) |
|
16 | app = QApplication(sys.argv) | |
17 | #wnd=InitWindow() |
|
17 | #wnd=InitWindow() | |
|
18 | # wnd=UnitProcess() | |||
18 | wnd=MainWindow() |
|
19 | wnd=MainWindow() | |
19 | #wnd=Workspace() |
|
20 | #wnd=Workspace() | |
20 | wnd.show() |
|
21 | wnd.show() |
This diff has been collapsed as it changes many lines, (1251 lines changed) Show them Hide them | |||||
@@ -1,28 +1,22 | |||||
1 | # -*- coding: utf-8 -*- |
|
1 | # -*- coding: utf-8 -*- | |
2 | """ |
|
2 | """ | |
3 | Module implementing MainWindow. |
|
3 | Module implementing MainWindow. | |
4 | #+ ######################INTERFAZ DE USUARIO V1.1################## |
|
4 | #+++++++++++++++++++++INTERFAZ DE USUARIO V1.1++++++++++++++++++++++++# | |
5 | """ |
|
5 | """ | |
6 | from PyQt4.QtGui import QMainWindow |
|
6 | from PyQt4.QtGui import QMainWindow | |
7 | from PyQt4.QtCore import pyqtSignature |
|
7 | from PyQt4.QtCore import pyqtSignature | |
8 | from PyQt4.QtCore import pyqtSignal |
|
8 | from PyQt4.QtCore import pyqtSignal | |
9 |
|
||||
10 | from PyQt4 import QtCore |
|
9 | from PyQt4 import QtCore | |
11 | from PyQt4 import QtGui |
|
10 | from PyQt4 import QtGui | |
12 |
|
||||
13 | from timeconversions import Doy2Date |
|
11 | from timeconversions import Doy2Date | |
14 |
|
12 | from modelProperties import treeModel | ||
15 | from modelProperties import person_class |
|
13 | from viewer.ui_unitprocess import Ui_UnitProcess | |
16 | from modelProperties import TreeItem |
|
|||
17 |
|
||||
18 |
|
||||
19 | from viewer.ui_window import Ui_window |
|
14 | from viewer.ui_window import Ui_window | |
20 | from viewer.ui_mainwindow import Ui_MainWindow |
|
15 | from viewer.ui_mainwindow import Ui_MainWindow | |
21 | from viewer.ui_workspace import Ui_Workspace |
|
16 | from viewer.ui_workspace import Ui_Workspace | |
22 | from viewer.ui_initwindow import Ui_InitWindow |
|
17 | from viewer.ui_initwindow import Ui_InitWindow | |
23 |
|
18 | |||
24 |
from controller |
|
19 | from controller import Project,ReadUnitConf,ProcUnitConf,OperationConf,ParameterConf | |
25 |
|
||||
26 | import os |
|
20 | import os | |
27 |
|
21 | |||
28 | HORIZONTAL_HEADERS = ("ITEM :"," DATOS : " ) |
|
22 | HORIZONTAL_HEADERS = ("ITEM :"," DATOS : " ) | |
@@ -30,397 +24,189 HORIZONTAL_HEADERS = ("ITEM :"," DATOS : " ) | |||||
30 | HORIZONTAL = ("RAMA :",) |
|
24 | HORIZONTAL = ("RAMA :",) | |
31 |
|
25 | |||
32 | class MainWindow(QMainWindow, Ui_MainWindow): |
|
26 | class MainWindow(QMainWindow, Ui_MainWindow): | |
|
27 | nop=None | |||
33 | """ |
|
28 | """ | |
34 | Class documentation goes here. |
|
29 | Class documentation goes here. | |
35 | #*##################VENTANA CUERPO DEL PROGRAMA#################### |
|
30 | #*##################VENTANA CUERPO DEL PROGRAMA#################### | |
36 | """ |
|
31 | """ | |
37 | closed=pyqtSignal() |
|
|||
38 | def __init__(self, parent = None): |
|
32 | def __init__(self, parent = None): | |
39 | """ |
|
33 | """ | |
40 | Constructor |
|
34 | Constructor | |
41 | 1-CARGA DE ARCHIVOS DE CONFIGURACION SI EXISTIERA.SI EXISTE EL ARCHIVO PROYECT.xml |
|
35 | """ | |
42 | 2- ESTABLECE CIERTOS PARAMETROS PARA PRUEBAS |
|
36 | print "Inicio de Programa Interfaz Gráfica" | |
43 | 3- CARGA LAS VARIABLES DE LA CLASE CON LOS PARAMETROS SELECCIONADOS |
|
|||
44 | 4-VALIDACION DE LA RUTA DE LOS DATOS Y DEL PROYECTO |
|
|||
45 | 5-CARGA LOS DOYS ENCONTRADOS PARA SELECCIONAR EL RANGO |
|
|||
46 | 6-CARGA UN PROYECTO |
|
|||
47 | """ |
|
|||
48 |
|
||||
49 | print "Inicio de Programa" |
|
|||
50 | QMainWindow.__init__(self, parent) |
|
37 | QMainWindow.__init__(self, parent) | |
51 |
|
||||
52 | self.setupUi(self) |
|
38 | self.setupUi(self) | |
53 |
|
39 | |||
54 | QtGui.QToolTip.setFont(QtGui.QFont('SansSerif', 10)) |
|
40 | self.online=0 | |
55 | self.addoBtn.setToolTip('Add_Unit_Process') |
|
41 | self.datatype=0 | |
56 | self.addbBtn.setToolTip('Add_Branch') |
|
42 | self.variableList=[] | |
57 | self.addpBtn.setToolTip('Add_New_Project') |
|
|||
58 | self.ventanaproject=0 |
|
|||
59 |
|
||||
60 | self.var=0 |
|
|||
61 | self.variableList=[] # Lista de DOYs |
|
|||
62 | self.iniciodisplay=0 |
|
|||
63 | self.year=0 |
|
|||
64 | self.OpMode=0 |
|
|||
65 | self.starTem=0 |
|
|||
66 | self.endTem=0 |
|
|||
67 | #*###################1######################## |
|
|||
68 | if os.path.isfile("Proyect.xml"): |
|
|||
69 | self.getParam() |
|
|||
70 | self.textedit.append("Parameters were loaded from configuration file") |
|
|||
71 | #*###################2######################## |
|
|||
72 | else: |
|
|||
73 | self.setParam() |
|
|||
74 | #*###################3######################### |
|
|||
75 | self.setVariables() |
|
|||
76 | #*###################4######################### |
|
|||
77 | self.statusDpath = self.existDir(self.dataPath) |
|
|||
78 | #self.statusRpath = self.dir_exists(self.var_Rpath, self) |
|
|||
79 | #*###################5 ######################## |
|
|||
80 | self.loadYears() |
|
|||
81 | self.loadDays() |
|
|||
82 | #================================ |
|
|||
83 |
|
43 | |||
84 | self.model = QtGui.QStandardItemModel() |
|
44 | self.proObjList=[] | |
85 | self.treeView.setModel(self.model) |
|
|||
86 | self.treeView.clicked.connect(self.treefunction1) |
|
|||
87 | #==========Project==========# |
|
|||
88 | self.projectObjList= [] |
|
|||
89 | self.ProjectObj=0 |
|
|||
90 | self.Pro=0 |
|
|||
91 | self.proObjList=[] |
|
|||
92 | self.valuep=1 |
|
|||
93 | self.namep=0 |
|
|||
94 | self.idp=0 |
|
45 | self.idp=0 | |
95 |
self. |
|
46 | self.namep=0 | |
96 | self.countBperPObjList= [] |
|
47 | self.description=0 | |
97 | #===========Branch==========# |
|
48 | self.namepTree=0 | |
98 |
self. |
|
49 | self.valuep=0 | |
99 | self.BranchObj=0 |
|
50 | ||
100 |
self. |
|
51 | self.upObjList= [] | |
101 |
self. |
|
52 | self.upn=0 | |
102 |
self. |
|
53 | self.upName=0 | |
103 |
self. |
|
54 | self.upType=0 | |
104 | self.countVperBObjList= [] |
|
55 | self.uporProObjRecover=0 | |
105 | #===========Voltage==========# |
|
|||
106 | self.voltageObjList=[] |
|
|||
107 | self.VoltageObj=0 |
|
|||
108 | self.Vol=0 |
|
|||
109 | self.volObjList=[] |
|
|||
110 | self.idv=0 |
|
|||
111 | self.namev=0 |
|
|||
112 | #===========Spectra==========# |
|
|||
113 | self.spectraObjList=[] |
|
|||
114 | self.SpectraObj=0 |
|
|||
115 | self.Spec=0 |
|
|||
116 | self.specObjList=[] |
|
|||
117 | self.ids=0 |
|
|||
118 | self.names=0 |
|
|||
119 | #===========Correlation==========# |
|
|||
120 | self.correlationObjList=[] |
|
|||
121 | self.CorrelationObj=0 |
|
|||
122 | self.Cor=0 |
|
|||
123 | self.corObjList=[] |
|
|||
124 | self.idc=0 |
|
|||
125 | self.namec=0 |
|
|||
126 | self.datatype=0 |
|
|||
127 |
|
56 | |||
128 | #================= |
|
|||
129 | #self.window=Window() |
|
|||
130 | self.Workspace=Workspace() |
|
|||
131 | #self.DataType=0 |
|
|||
132 |
|
57 | |||
|
58 | self.readUnitConfObjList=[] | |||
133 |
|
59 | |||
134 | #*################### |
|
|||
135 |
|
||||
136 | def treefunction1(self, index): |
|
|||
137 | a= index.model().itemFromIndex(index).text() |
|
|||
138 | print a |
|
|||
139 | b=a[8:10] |
|
|||
140 | self.valuep=b |
|
|||
141 | c=a[0:7] |
|
|||
142 | self.namep=c |
|
|||
143 |
|
||||
144 | # def ventanaconfigura(self): |
|
|||
145 | # ''' |
|
|||
146 | # METODO QUE SE ENCARGA DE LLAMAR A LA CLASE |
|
|||
147 | # VENTANA CONFIGURACION DE PROYECTO |
|
|||
148 | # ''' |
|
|||
149 | # self.Luna =Workspace(self) |
|
|||
150 | # self.Luna.closed.connect(self.show) |
|
|||
151 | # self.Luna.show() |
|
|||
152 | # self.hide() |
|
|||
153 |
|
||||
154 | # def closeEvent(self, event): |
|
|||
155 | # self.closed.emit() |
|
|||
156 | # event.accept() |
|
|||
157 |
|
||||
158 | #+######################BARRA DE MENU################### |
|
|||
159 |
|
||||
160 | # *####################MENU FILE ######################### |
|
|||
161 |
|
||||
162 | @pyqtSignature("") |
|
|||
163 | def on_actionabrirObj_triggered(self): |
|
|||
164 | """ |
|
|||
165 | Ubicado en la Barra de Menu, OPCION FILE, CARGA UN ARCHIVO DE CONFIGURACION ANTERIOR |
|
|||
166 | """ |
|
|||
167 | # TODO: not implemented yet |
|
|||
168 | #raise NotImplementedError |
|
|||
169 |
|
60 | |||
170 |
|
61 | self.operObjList=[] | ||
171 | @pyqtSignature("") |
|
|||
172 | def on_actioncrearObj_triggered(self): |
|
|||
173 | """ |
|
|||
174 | CREACION DE UN NUEVO EXPERIMENTO |
|
|||
175 | """ |
|
|||
176 | self.on_addpBtn_clicked() |
|
|||
177 |
|
62 | |||
178 | @pyqtSignature("") |
|
63 | self.configProject=None | |
179 | def on_actionguardarObj_triggered(self): |
|
64 | self.configUP=None | |
180 | """ |
|
|||
181 | GUARDAR EL ARCHIVO DE CONFIGURACION XML |
|
|||
182 | """ |
|
|||
183 | # TODO: not implemented yet |
|
|||
184 | #raise NotImplementedError |
|
|||
185 | self.SaveConfig() |
|
|||
186 |
|
65 | |||
187 | @pyqtSignature("") |
|
66 | self.controllerObj=None | |
188 | def on_actionCerrarObj_triggered(self): |
|
67 | self.readUnitConfObj=None | |
189 | """ |
|
68 | self.procUnitConfObj0=None | |
190 | CERRAR LA APLICACION GUI |
|
69 | self.opObj10=None | |
191 | """ |
|
70 | self.opObj12=None | |
192 | self.close() |
|
71 | ||
|
72 | ||||
|
73 | self.setParam() | |||
193 |
|
74 | |||
194 | #*######################### MENU RUN ################## |
|
75 | ||
|
76 | def getNumberofProject(self): | |||
|
77 | # for i in self.proObjList: | |||
|
78 | # print i | |||
|
79 | return self.proObjList | |||
|
80 | # for i in self.proObjList: | |||
|
81 | # print i | |||
|
82 | ||||
|
83 | def setParam(self): | |||
|
84 | self.dataPathTxt.setText('C:\\Users\\alex\\Documents\\ROJ\\ew_drifts') | |||
|
85 | ||||
|
86 | ||||
|
87 | def clickFunctiontree(self,index): | |||
|
88 | indexclick= index.model().itemFromIndex(index).text() | |||
|
89 | #print indexclick | |||
|
90 | NumofPro=indexclick[8:10] | |||
|
91 | self.valuep=NumofPro | |||
|
92 | #print self.valuep | |||
|
93 | NameofPro=indexclick[0:7] | |||
|
94 | self.namepTree=NameofPro | |||
|
95 | #print self.namepTree | |||
195 |
|
96 | |||
|
97 | ||||
196 | @pyqtSignature("") |
|
98 | @pyqtSignature("") | |
197 |
def on_a |
|
99 | def on_addpBtn_clicked(self): | |
198 | """ |
|
|||
199 | EMPEZAR EL PROCESAMIENTO. |
|
|||
200 |
|
|
100 | """ | |
201 | # TODO: not implemented yet |
|
101 | ANADIR UN NUEVO PROYECTO | |
202 | #raise NotImplementedErr |
|
102 | """ | |
|
103 | print "En este nivel se abre el window" | |||
203 |
|
104 | |||
204 | @pyqtSignature("") |
|
|||
205 | def on_actionPausaObj_triggered(self): |
|
|||
206 | """ |
|
|||
207 | PAUSAR LAS OPERACIONES |
|
|||
208 | """ |
|
|||
209 | # TODO: not implemented yet |
|
|||
210 | # raise NotImplemente |
|
|||
211 |
|
105 | |||
212 | #*###################MENU OPTIONS###################### |
|
106 | self.showWindow() | |
213 |
|
107 | |||
214 | @pyqtSignature("") |
|
108 | def showWindow(self): | |
215 | def on_actionconfigLogfileObj_triggered(self): |
|
109 | self.configProject=Window(self) | |
|
110 | #self.configProject.closed.connect(self.show) | |||
|
111 | self.configProject.show() | |||
|
112 | #self.configProject.closed.connect(self.show) | |||
|
113 | self.configProject.saveButton.clicked.connect(self.reciveParameters) | |||
|
114 | self.configProject.closed.connect(self.createProject) | |||
|
115 | ||||
|
116 | def reciveParameters(self): | |||
|
117 | self.namep,self.description =self.configProject.almacena() | |||
|
118 | ||||
|
119 | def createProject(self): | |||
|
120 | ||||
|
121 | print "En este nivel se debe crear el proyecto,id,nombre,desc" | |||
|
122 | #+++++Creacion del Objeto Controller-XML++++++++++# | |||
|
123 | self.idp += 1 | |||
|
124 | self.controllerObj = Project() | |||
|
125 | id=int(self.idp) | |||
|
126 | name=str(self.namep) | |||
|
127 | desc=str(self.description) | |||
|
128 | self.parentItem=self.model.invisibleRootItem() | |||
|
129 | self.controllerObj.arbol=QtGui.QStandardItem(QtCore.QString("Project %0").arg(self.idp)) | |||
|
130 | self.controllerObj.setup(id = id, name=name, description=desc) | |||
|
131 | self.parentItem.appendRow(self.controllerObj.arbol) | |||
|
132 | self.proObjList.append(self.controllerObj)#+++++++++++++++++++LISTA DE PROYECTO++++++++++++++++++++++++++++# | |||
|
133 | self.parentItem=self.controllerObj.arbol | |||
|
134 | self.loadProjects() | |||
|
135 | ||||
|
136 | print "Porfavor ingrese los parámetros de configuracion del Proyecto" | |||
|
137 | ||||
|
138 | def loadProjects(self): | |||
|
139 | self.proConfCmbBox.clear() | |||
|
140 | for i in self.proObjList: | |||
|
141 | self.proConfCmbBox.addItem("Project"+str(i.id)) | |||
|
142 | ||||
|
143 | @pyqtSignature("int") | |||
|
144 | def on_dataTypeCmbBox_activated(self,index): | |||
|
145 | self.dataFormatTxt.setReadOnly(True) | |||
|
146 | if index==0: | |||
|
147 | self.datatype='Voltage' | |||
|
148 | elif index==1: | |||
|
149 | self.datatype='Spectra' | |||
|
150 | else : | |||
|
151 | self.datatype='' | |||
|
152 | self.dataFormatTxt.setReadOnly(False) | |||
|
153 | self.dataFormatTxt.setText(self.datatype) | |||
|
154 | ||||
|
155 | def existDir(self, var_dir): | |||
216 | """ |
|
156 | """ | |
217 | Slot Documentation goes here |
|
157 | METODO PARA VERIFICAR SI LA RUTA EXISTE-VAR_DIR | |
|
158 | VARIABLE DIRECCION | |||
218 | """ |
|
159 | """ | |
219 | self.Luna = Workspace(self) |
|
160 | if os.path.isdir(var_dir): | |
220 | #print self.Luna.dirCmbBox.currentText() |
|
161 | return True | |
|
162 | else: | |||
|
163 | self.textEdit.append("Incorrect path:" + str(var_dir)) | |||
|
164 | return False | |||
221 |
|
165 | |||
222 | @pyqtSignature("") |
|
166 | def loadDays(self): | |
223 | def on_actionconfigserverObj_triggered(self): |
|
|||
224 | """ |
|
167 | """ | |
225 | CONFIGURACION DE SERVIDOR. |
|
168 | METODO PARA CARGAR LOS DIAS | |
226 | """ |
|
169 | """ | |
227 | # TODO: not implemented yet |
|
170 | self.variableList=[] | |
228 | #raise NotImplementedError |
|
171 | self.starDateCmbBox.clear() | |
|
172 | self.endDateCmbBox.clear() | |||
229 |
|
173 | |||
230 | #*################# MENU HELPS########################## |
|
174 | Dirlist = os.listdir(self.dataPath) | |
231 |
|
175 | Dirlist.sort() | ||
232 | @pyqtSignature("") |
|
|||
233 | def on_actionAboutObj_triggered(self): |
|
|||
234 | """ |
|
|||
235 | Slot documentation goes here. |
|
|||
236 | """ |
|
|||
237 | # TODO: not implemented yet |
|
|||
238 | #raise NotImplementedError |
|
|||
239 |
|
176 | |||
240 | @pyqtSignature("") |
|
177 | for a in range(0, len(Dirlist)): | |
241 | def on_actionPrfObj_triggered(self): |
|
178 | fname= Dirlist[a] | |
242 | """ |
|
179 | Doy=fname[5:8] | |
243 | Slot documentation goes here. |
|
180 | fname = fname[1:5] | |
244 | """ |
|
181 | print fname | |
245 | # TODO: not implemented yet |
|
182 | fecha=Doy2Date(int(fname),int(Doy)) | |
246 | #raise NotImplementedError |
|
183 | fechaList=fecha.change2date() | |
247 |
|
184 | #print fechaList[0] | ||
248 | #+################################################## |
|
185 | Dirlist[a]=fname+"/"+str(fechaList[0])+"/"+str(fechaList[1]) | |
249 |
|
186 | #+"-"+ fechaList[0]+"-"+fechaList[1] | ||
250 | @pyqtSignature("") |
|
|||
251 | def on_actionOpenObj_triggered(self): |
|
|||
252 | """ |
|
|||
253 | Slot documentation goes here. |
|
|||
254 | """ |
|
|||
255 | # TODO: not implemented yet |
|
|||
256 | #raise No |
|
|||
257 |
|
||||
258 | @pyqtSignature("") |
|
|||
259 | def on_actioncreateObj_triggered(self): |
|
|||
260 | """ |
|
|||
261 | Slot documentation goes here. |
|
|||
262 | """ |
|
|||
263 | self.on_addpBtn_clicked() |
|
|||
264 |
|
||||
265 | @pyqtSignature("") |
|
|||
266 | def on_actionstopObj_triggered(self): |
|
|||
267 | """ |
|
|||
268 | CARGA UN ARCHIVO DE CONFIGURACION ANTERIOR |
|
|||
269 | """ |
|
|||
270 | # TODO: not implemented yet |
|
|||
271 | #raise NotImplementedError |
|
|||
272 |
|
||||
273 | @pyqtSignature("") |
|
|||
274 | def on_actionPlayObj_triggered(self): |
|
|||
275 | """ |
|
|||
276 | EMPEZAR EL PROCESAMIENTO. |
|
|||
277 | """ |
|
|||
278 | # TODO: not implemented yet |
|
|||
279 | #raise NotImplementedError |
|
|||
280 |
|
||||
281 | #*################VENTANA EXPLORADOR DE PROYECTOS###################### |
|
|||
282 |
|
187 | |||
283 | @pyqtSignature("") |
|
188 | #---------------AQUI TIENE QUE SER MODIFICADO--------# | |
284 | def on_addpBtn_clicked(self): |
|
|||
285 | """ |
|
|||
286 | AADIR UN NUEVO PROYECTO |
|
|||
287 | """ |
|
|||
288 | self.windowshow() |
|
|||
289 | self.idp += 1 |
|
|||
290 | self.Pro=Project() |
|
|||
291 | self.proObjList.append(self.Pro) |
|
|||
292 | self.parentItem=self.model.invisibleRootItem() |
|
|||
293 | self.ProjectObj = QtGui.QStandardItem(QtCore.QString("Project %0").arg(self.idp)) |
|
|||
294 | self.parentItem.appendRow(self.ProjectObj) |
|
|||
295 | self.projectObjList.append(self.ProjectObj) |
|
|||
296 | self.parentItem=self.ProjectObj |
|
|||
297 |
|
189 | |||
298 | @pyqtSignature("") |
|
190 | #Se cargan las listas para seleccionar StartDay y StopDay (QComboBox) | |
299 | def on_addbBtn_clicked(self): |
|
191 | for i in range(0, (len(Dirlist))): | |
300 | """ |
|
192 | self.variableList.append(Dirlist[i]) | |
301 | AÑADIR UNA RAMA DE PROCESAMIENTO |
|
|||
302 | """ |
|
|||
303 | #print self.valuep |
|
|||
304 | #print self.namep |
|
|||
305 | #print self.valueb |
|
|||
306 |
|
||||
307 | #if self.namep ==str("Project"): |
|
|||
308 | self.idb += 1 |
|
|||
309 | self.Bra=self.proObjList[int(self.valuep)-1].addProcBranch(id=self.idb,name='Branch') |
|
|||
310 | self.braObjList.append(self.Bra) |
|
|||
311 | self.parentItem=self.projectObjList[int(self.valuep)-1] |
|
|||
312 | #= |
|
|||
313 | self.countBperPObjList.append(self.valuep) |
|
|||
314 | # LisBperP=self.countBperPObjList |
|
|||
315 |
|
||||
316 | self.BranchObj= QtGui.QStandardItem(QtCore.QString("Branch %1 ").arg(self.idb)) |
|
|||
317 | self.parentItem.appendRow(self.BranchObj) |
|
|||
318 | self.branchObjList.append(self.BranchObj) |
|
|||
319 | self.parentItem=self.BranchObj |
|
|||
320 |
|
193 | |||
321 | @pyqtSignature("") |
|
194 | for i in self.variableList: | |
322 | def on_addoBtn_clicked(self): |
|
195 | self.starDateCmbBox.addItem(i) | |
323 | """ |
|
196 | self.endDateCmbBox.addItem(i) | |
324 | AÑADIR UN TIPO DE PROCESAMIENTO. |
|
197 | self.endDateCmbBox.setCurrentIndex(self.starDateCmbBox.count()-1) | |
325 | """ |
|
|||
326 | if self.namep ==str("Project"): |
|
|||
327 | self.totalTree() |
|
|||
328 | #===================== |
|
|||
329 | if self.namep ==str("Voltage"): |
|
|||
330 | self.ids += 1 |
|
|||
331 | self.Spec=self.volObjList[int(self.valuep)-1].addUPSUB(id=self.ids, name='Spectra', type='Pri') |
|
|||
332 | self.specObjList.append(self.Spec) |
|
|||
333 | self.parentItem=self.voltageObjList[int(self.valuep)-1] |
|
|||
334 | self.SpectraObj= QtGui.QStandardItem(QtCore.QString("Spectra %2").arg(self.ids)) |
|
|||
335 | self.parentItem.appendRow(self.SpectraObj) |
|
|||
336 | self.spectraObjList.append(self.SpectraObj) |
|
|||
337 | self.parentItem=self.SpectraObj |
|
|||
338 |
|
||||
339 | if self.namep ==str("Spectra"): |
|
|||
340 | self.idc += 1 |
|
|||
341 | self.Cor=self.specObjList[int(self.valuep)-1].addUP2SUB(id=self.idc, name='Correlation', type='Pri') |
|
|||
342 | self.corObjList.append(self.Cor) |
|
|||
343 | self.parentItem=self.spectraObjList[int(self.valuep)-1] |
|
|||
344 | self.CorrelationObj= QtGui.QStandardItem(QtCore.QString("Correlation %3").arg(self.idc)) |
|
|||
345 | self.parentItem.appendRow(self.CorrelationObj) |
|
|||
346 | self.correlationObjList.append(self.CorrelationObj) |
|
|||
347 | self.parentItem=self.CorrelationObj |
|
|||
348 |
|
||||
349 | if self.namep == str("Branch "): |
|
|||
350 | if self.DataType== str("r"): |
|
|||
351 | self.idv += 1 |
|
|||
352 | if len(self.valuep)==0: |
|
|||
353 | print "construir rama" |
|
|||
354 | else: |
|
|||
355 | self.Vol=self.braObjList[int(self.valuep)-1].addUP(id=self.idv, name='Voltage', type='Pri') |
|
|||
356 | self.volObjList.append(self.Vol) |
|
|||
357 | self.parentItem=self.branchObjList[int(self.valuep)-1] |
|
|||
358 | self.VoltageObj= QtGui.QStandardItem(QtCore.QString("Voltage %2").arg(self.idv)) |
|
|||
359 | self.parentItem.appendRow(self.VoltageObj) |
|
|||
360 | self.voltageObjList.append(self.VoltageObj) |
|
|||
361 | self.parentItem=self.VoltageObj |
|
|||
362 |
|
||||
363 | if self.DataType== str("pdata"): |
|
|||
364 | self.ids += 1 |
|
|||
365 | if len(self.valuep)==0: |
|
|||
366 | print "construir rama" |
|
|||
367 | else: |
|
|||
368 | self.Spec=self.braObjList[int(self.valuep)-1].addUPSUB(id=self.ids, name='Spectra', type='Pri') |
|
|||
369 | self.specObjList.append(self.Spec) |
|
|||
370 | self.parentItem=self.branchObjList[int(self.valuep)-1] |
|
|||
371 | self.SpectraObj= QtGui.QStandardItem(QtCore.QString("Spectra %2").arg(self.ids)) |
|
|||
372 | self.parentItem.appendRow(self.SpectraObj) |
|
|||
373 | self.spectraObjList.append(self.SpectraObj) |
|
|||
374 | self.parentItem=self.SpectraObj |
|
|||
375 |
|
||||
376 | def totalTree(self): |
|
|||
377 | b= self.proObjList[int(self.valuep)-1] |
|
|||
378 | b.procBranchObjList # Objetos de tipo Branch |
|
|||
379 | print "Project"+str(self.valuep) +"Branch", |
|
|||
380 | for i in range(0 , len(b.procBranchObjList)): |
|
|||
381 | print b.procBranchObjList[i].id, #objetos de tipo branch 1,2,3 o 4,5 o 6 |
|
|||
382 | print "" |
|
|||
383 | for i in range(0 , len(b.procBranchObjList)): |
|
|||
384 | print "Branch"+ str(b.procBranchObjList[i].id) |
|
|||
385 |
|
||||
386 | for i in range(0 , len(b.procBranchObjList)): |
|
|||
387 | print b.procBranchObjList[i].id |
|
|||
388 | c= self.braObjList[(b.procBranchObjList[i].id)-1] |
|
|||
389 | c.upsubObjList |
|
|||
390 | for i in range(0,len(c.upsubObjList)): |
|
|||
391 | print "Spectra"+str(c.upsubObjList[i].id), |
|
|||
392 | #*********************VENTANA CONFIGURACION DE PROYECTOS************************************ |
|
|||
393 |
|
||||
394 | #***********************PESTAÑA DE PROYECTOS************************ |
|
|||
395 |
|
||||
396 | #*************************MODO BASICO O AVANZADO***************** |
|
|||
397 |
|
198 | |||
398 | @pyqtSignature("QString") |
|
199 | self.getsubList() | |
399 | def on_operationModeCmbBox_activated(self, p0): |
|
200 | self.dataOkBtn.setEnabled(True) | |
|
201 | ||||
|
202 | def getsubList(self): | |||
400 | """ |
|
203 | """ | |
401 | Slot documentation goes here. |
|
204 | OBTIENE EL RANDO DE LAS FECHAS SELECCIONADAS | |
402 | """ |
|
205 | """ | |
403 | pass |
|
206 | self.subList=[] | |
|
207 | for i in self.variableList[self.starDateCmbBox.currentIndex():self.starDateCmbBox.currentIndex() + self.endDateCmbBox.currentIndex()+1]: | |||
|
208 | self.subList.append(i) | |||
404 |
|
209 | |||
405 | #***********************TIPOS DE DATOS A GRABAR****************************** |
|
|||
406 |
|
||||
407 | @pyqtSignature("int") |
|
|||
408 | def on_dataFormatCmbBox_activated(self,index): |
|
|||
409 | """ |
|
|||
410 | SE EJECUTA CUANDO SE ELIGE UN ITEM DE LA LISTA |
|
|||
411 | ADEMAS SE CARGA LA LISTA DE DIAS SEGUN EL TIPO DE ARCHIVO SELECCIONADO |
|
|||
412 | """ |
|
|||
413 | self.dataFormatTxt.setReadOnly(True) |
|
|||
414 | if index == 0: |
|
|||
415 | self.DataType ='r' |
|
|||
416 | elif index == 1: |
|
|||
417 | self.DataType ='pdata' |
|
|||
418 | else : |
|
|||
419 | self.DataType ='' |
|
|||
420 | self.dataFormatTxt.setReadOnly(False) |
|
|||
421 | self.dataFormatTxt.setText(self.DataType) |
|
|||
422 | # self.loadDays(self) |
|
|||
423 |
|
||||
424 | @pyqtSignature("") |
|
210 | @pyqtSignature("") | |
425 | def on_dataPathBrowse_clicked(self): |
|
211 | def on_dataPathBrowse_clicked(self): | |
426 | """ |
|
212 | """ | |
@@ -429,9 +215,8 class MainWindow(QMainWindow, Ui_MainWindow): | |||||
429 | self.dataPath = str(QtGui.QFileDialog.getExistingDirectory(self, 'Open Directory', './', QtGui.QFileDialog.ShowDirsOnly)) |
|
215 | self.dataPath = str(QtGui.QFileDialog.getExistingDirectory(self, 'Open Directory', './', QtGui.QFileDialog.ShowDirsOnly)) | |
430 | self.dataPathTxt.setText(self.dataPath) |
|
216 | self.dataPathTxt.setText(self.dataPath) | |
431 | self.statusDpath=self.existDir(self.dataPath) |
|
217 | self.statusDpath=self.existDir(self.dataPath) | |
432 |
self.load |
|
218 | self.loadDays() | |
433 | self.loadDays() |
|
219 | ||
434 |
|
||||
435 | @pyqtSignature("int") |
|
220 | @pyqtSignature("int") | |
436 | def on_starDateCmbBox_activated(self, index): |
|
221 | def on_starDateCmbBox_activated(self, index): | |
437 | """ |
|
222 | """ | |
@@ -457,440 +242,233 class MainWindow(QMainWindow, Ui_MainWindow): | |||||
457 | self.starDateCmbBox.setCurrentIndex(var_StartDay_index) |
|
242 | self.starDateCmbBox.setCurrentIndex(var_StartDay_index) | |
458 | self.getsubList() #Se carga var_sublist[] con el rango de las fechas seleccionadas |
|
243 | self.getsubList() #Se carga var_sublist[] con el rango de las fechas seleccionadas | |
459 |
|
244 | |||
460 |
@pyqtSignature(" |
|
245 | @pyqtSignature("int") | |
461 | def on_readModeCmBox_activated(self, p0): |
|
246 | def on_readModeCmBox_activated(self, p0): | |
462 | """ |
|
247 | """ | |
463 | Slot documentation goes here. |
|
248 | Slot documentation goes here. | |
464 | """ |
|
249 | """ | |
465 | print self.readModeCmBox.currentText() |
|
250 | if p0==0: | |
466 |
|
251 | self.online=0 | ||
467 | @pyqtSignature("int") |
|
252 | elif p0==1: | |
468 | def on_initialTimeSlider_valueChanged(self, initvalue): |
|
253 | self.online=1 | |
469 |
|
|
254 | ||
470 | SELECCION DE LA HORA DEL EXPERIMENTO -INITIAL TIME |
|
|||
471 | """ |
|
|||
472 | self.iniciodisplay=initvalue |
|
|||
473 | self.initialtimeLcd.display(initvalue) |
|
|||
474 | self.starTem=initvalue |
|
|||
475 |
|
||||
476 | @pyqtSignature("int") |
|
|||
477 | def on_finalTimeSlider_valueChanged(self, finalvalue): |
|
|||
478 | """ |
|
|||
479 | SELECCION DE LA HORA DEL EXPERIMENTO -FINAL TIME |
|
|||
480 | """ |
|
|||
481 | finalvalue = self.iniciodisplay + finalvalue |
|
|||
482 | if finalvalue >24: |
|
|||
483 | finalvalue = 24 |
|
|||
484 | self.finaltimeLcd.display(finalvalue) |
|
|||
485 | self.endTem=finalvalue |
|
|||
486 |
|
||||
487 | @pyqtSignature("QString") |
|
|||
488 | def on_yearCmbBox_activated(self, year): |
|
|||
489 | """ |
|
|||
490 | SELECCION DEL AÑO |
|
|||
491 | """ |
|
|||
492 | self.year = year |
|
|||
493 | #print self.year |
|
|||
494 |
|
||||
495 | @pyqtSignature("") |
|
|||
496 | def on_dataCancelBtn_clicked(self): |
|
|||
497 | """ |
|
|||
498 | SAVE- BUTTON CANCEL |
|
|||
499 | """ |
|
|||
500 | # TODO: not implemented yet |
|
|||
501 | #raise NotImplementedError |
|
|||
502 |
|
||||
503 | @pyqtSignature("") |
|
255 | @pyqtSignature("") | |
504 | def on_dataOkBtn_clicked(self): |
|
256 | def on_dataOkBtn_clicked(self): | |
505 | """ |
|
257 | """ | |
506 | SAVE-BUTTON OK |
|
258 | Slot documentation goes here. | |
507 | """ |
|
259 | """ | |
508 | #print self.ventanaproject.almacena() |
|
260 | print "En este nivel se pasa el tipo de dato con el que se trabaja,path,startDate,endDate,startTime,endTime,online" | |
509 | print "alex" |
|
261 | ||
510 | print self.Workspace.dirCmbBox.currentText() |
|
262 | projectObj=self.proObjList[int(self.proConfCmbBox.currentIndex())] | |
|
263 | datatype=str(self.dataTypeCmbBox.currentText()) | |||
|
264 | path=str(self.dataPathTxt.text()) | |||
|
265 | online=int(self.online) | |||
|
266 | starDate=str(self.starDateCmbBox.currentText()) | |||
|
267 | endDate=str(self.endDateCmbBox.currentText()) | |||
|
268 | ||||
|
269 | ||||
|
270 | self.readUnitConfObj = projectObj.addReadUnit(datatype=datatype, | |||
|
271 | path=path, | |||
|
272 | startDate=starDate, | |||
|
273 | endDate=endDate, | |||
|
274 | startTime='06:10:00', | |||
|
275 | endTime='23:59:59', | |||
|
276 | online=online) | |||
|
277 | ||||
|
278 | self.readUnitConfObjList.append(self.readUnitConfObj) | |||
|
279 | ||||
|
280 | print "self.readUnitConfObj.getId",self.readUnitConfObj.getId(),datatype,path,starDate,endDate,online | |||
|
281 | ||||
|
282 | ||||
511 | self.model_2=treeModel() |
|
283 | self.model_2=treeModel() | |
512 | #lines = unicode(self.textEdit_2.toPlainText()).split('\n') |
|
284 | ||
513 | #print lines |
|
285 | self.model_2.setParams(name=projectObj.name+str(projectObj.id), | |
514 | if self.ventanaproject.almacena()==None: |
|
286 | directorio=path, | |
515 | name=str(self.namep) |
|
287 | workspace="C:\\WorkspaceGUI", | |
516 | name=str(self.ventanaproject.almacena()) |
|
|||
517 |
|
||||
518 | self.model_2.setParams(name=name, |
|
|||
519 | directorio=str(self.dataPathTxt.text()), |
|
|||
520 | workspace=str(self.Workspace.dirCmbBox.currentText()), |
|
|||
521 | opmode=str(self.operationModeCmbBox.currentText()), |
|
|||
522 | remode=str(self.readModeCmBox.currentText()), |
|
288 | remode=str(self.readModeCmBox.currentText()), | |
523 |
dataformat= |
|
289 | dataformat=datatype, | |
524 |
date=str( |
|
290 | date=str(starDate)+"-"+str(endDate), | |
525 |
initTime= |
|
291 | initTime='06:10:00', | |
526 |
endTime= |
|
292 | endTime='23:59:59', | |
527 |
timezone="Local" |
|
293 | timezone="Local" , | |
528 |
|
|
294 | Summary="test de prueba") | |
529 | self.model_2.arbol() |
|
295 | self.model_2.arbol() | |
530 | self.treeView_2.setModel(self.model_2) |
|
296 | self.treeView_2.setModel(self.model_2) | |
531 | self.treeView_2.expandAll() |
|
297 | self.treeView_2.expandAll() | |
532 |
|
298 | |||
533 | #*############METODOS PARA EL PATH-YEAR-DAYS########################### |
|
299 | ||
534 |
|
300 | |||
535 | def existDir(self, var_dir): |
|
301 | ||
536 |
|
|
302 | ||
537 | METODO PARA VERIFICAR SI LA RUTA EXISTE-VAR_DIR |
|
303 | ||
538 | VARIABLE DIRECCION |
|
304 | ||
539 | """ |
|
305 | @pyqtSignature("") | |
540 | if os.path.isdir(var_dir): |
|
306 | def on_addUnitProces_clicked(self): | |
541 | return True |
|
|||
542 | else: |
|
|||
543 | self.textEdit.append("Incorrect path:" + str(var_dir)) |
|
|||
544 | return False |
|
|||
545 |
|
||||
546 | def loadYears(self): |
|
|||
547 | """ |
|
|||
548 | METODO PARA SELECCIONAR EL AÑO |
|
|||
549 | """ |
|
|||
550 | self.variableList=[] |
|
|||
551 | self.yearCmbBox.clear() |
|
|||
552 | if self.statusDpath == False: |
|
|||
553 | self.dataOkBtn.setEnabled(False) |
|
|||
554 | return |
|
|||
555 | if self.DataType == '': |
|
|||
556 | return |
|
|||
557 |
|
||||
558 | Dirlist = os.listdir(self.dataPath) |
|
|||
559 |
|
||||
560 | for y in range(0, len(Dirlist)): |
|
|||
561 | fyear= Dirlist[y] |
|
|||
562 | fyear = fyear[1:5] |
|
|||
563 | Dirlist[y]=fyear |
|
|||
564 |
|
||||
565 | Dirlist=list(set(Dirlist)) |
|
|||
566 | Dirlist.sort() |
|
|||
567 |
|
||||
568 | if len(Dirlist) == 0: |
|
|||
569 | self.textEdit.append("File not found") |
|
|||
570 | self.dataOkBtn.setEnabled(False) |
|
|||
571 | return |
|
|||
572 | #Se cargan las listas para seleccionar StartDay y StopDay (QComboBox) |
|
|||
573 | for i in range(0, (len(Dirlist))): |
|
|||
574 | self.variableList.append(Dirlist[i]) |
|
|||
575 | for i in self.variableList: |
|
|||
576 | self.yearCmbBox.addItem(i) |
|
|||
577 |
|
||||
578 | def loadDays(self): |
|
|||
579 | """ |
|
307 | """ | |
580 | METODO PARA CARGAR LOS DIAS |
|
308 | Slot documentation goes here. | |
581 | """ |
|
309 | """ | |
582 | self.variableList=[] |
|
310 | # print "En este nivel se adiciona una rama de procesamiento, y se le concatena con el id" | |
583 | self.starDateCmbBox.clear() |
|
311 | # self.procUnitConfObj0 = self.controllerObj.addProcUnit(datatype='Voltage', inputId=self.readUnitConfObj.getId()) | |
584 | self.endDateCmbBox.clear() |
|
312 | self.showUp() | |
585 |
|
313 | |||
586 | Dirlist = os.listdir(self.dataPath) |
|
314 | def showUp(self): | |
587 | Dirlist.sort() |
|
|||
588 |
|
315 | |||
589 | for a in range(0, len(Dirlist)): |
|
316 | self.configUP=UnitProcess(self) | |
590 | fname= Dirlist[a] |
|
317 | for i in self.proObjList: | |
591 | Doy=fname[5:8] |
|
318 | self.configUP.getfromWindowList.append(i) | |
592 | fname = fname[1:5] |
|
319 | #print i | |
593 | print fname |
|
320 | for i in self.upObjList: | |
594 | fecha=Doy2Date(int(fname),int(Doy)) |
|
321 | self.configUP.getfromWindowList.append(i) | |
595 | fechaList=fecha.change2date() |
|
322 | self.configUP.loadTotalList() | |
596 | #print fechaList[0] |
|
323 | self.configUP.show() | |
597 | Dirlist[a]=fname+"-"+str(fechaList[0])+"-"+str(fechaList[1]) |
|
324 | self.configUP.unitPsavebut.clicked.connect(self.reciveUPparameters) | |
598 | #+"-"+ fechaList[0]+"-"+fechaList[1] |
|
325 | self.configUP.closed.connect(self.createUP) | |
599 |
|
||||
600 | #---------------AQUI TIENE QUE SER MODIFICADO--------# |
|
|||
601 |
|
326 | |||
602 |
|
327 | def reciveUPparameters(self): | ||
603 |
|
||||
604 |
|
||||
605 |
|
||||
606 | #Se cargan las listas para seleccionar StartDay y StopDay (QComboBox) |
|
|||
607 | for i in range(0, (len(Dirlist))): |
|
|||
608 | self.variableList.append(Dirlist[i]) |
|
|||
609 |
|
328 | |||
610 | for i in self.variableList: |
|
329 | self.uporProObjRecover,self.upType=self.configUP.almacena() | |
611 | self.starDateCmbBox.addItem(i) |
|
330 | ||
612 | self.endDateCmbBox.addItem(i) |
|
331 | ||
613 | self.endDateCmbBox.setCurrentIndex(self.starDateCmbBox.count()-1) |
|
332 | def createUP(self): | |
614 |
|
333 | print "En este nivel se adiciona una rama de procesamiento, y se le concatena con el id" | ||
615 | self.getsubList() |
|
334 | projectObj=self.proObjList[int(self.proConfCmbBox.currentIndex())] | |
616 | self.dataOkBtn.setEnabled(True) |
|
335 | ||
617 |
|
336 | datatype=str(self.upType) | ||
618 | def getsubList(self): |
|
337 | uporprojectObj=self.uporProObjRecover | |
619 | """ |
|
338 | #+++++++++++LET FLY+++++++++++# | |
620 | OBTIENE EL RANDO DE LAS FECHAS SELECCIONADAS |
|
339 | if uporprojectObj.getElementName()=='ProcUnit': | |
621 | """ |
|
340 | inputId=uporprojectObj.getId() | |
622 | self.subList=[] |
|
341 | elif uporprojectObj.getElementName()=='Project': | |
623 | for i in self.variableList[self.starDateCmbBox.currentIndex():self.starDateCmbBox.currentIndex() + self.endDateCmbBox.currentIndex()+1]: |
|
342 | inputId=self.readUnitConfObjList[uporprojectObj.id-1].getId() | |
624 | self.subList.append(i) |
|
343 | ||
625 |
|
344 | |||
626 | #*################ METODO PARA GUARDAR ARCHIVO DE CONFIGURACION ################# |
|
345 | self.procUnitConfObj1 = projectObj.addProcUnit(datatype=datatype, inputId=inputId) | |
627 | # def SaveConfig(self): |
|
346 | self.upObjList.append(self.procUnitConfObj1) | |
628 | # |
|
347 | print inputId | |
629 | # desc = "Este es un test" |
|
348 | print self.procUnitConfObj1.getId() | |
630 | # filename=str(self.workspace.dirCmbBox.currentText())+"\\"+"Config"+str(self.valuep)+".xml" |
|
349 | self.parentItem=uporprojectObj.arbol | |
631 | # projectObj=self.proObjList[int(self.valuep)-1] |
|
350 | self.numbertree=int(self.procUnitConfObj1.getId())-1 | |
632 | # projectObj.setParms(id =int(self.valuep),name=str(self.namep),description=desc) |
|
351 | self.procUnitConfObj1.arbol=QtGui.QStandardItem(QtCore.QString(datatype +"%1 ").arg(self.numbertree)) | |
633 | # print self.valuep |
|
352 | self.parentItem.appendRow(self.procUnitConfObj1.arbol) | |
634 | # print self.namep |
|
353 | self.parentItem=self.procUnitConfObj1.arbol | |
635 | # |
|
354 | self.loadUp() | |
636 | # readBranchObj = projectObj.addReadBranch(id=str(self.valuep), |
|
355 | self.treeView.expandAll() | |
637 | # dpath=str(self.dataPathTxt.text()), |
|
356 | ||
638 | # dataformat=str(self.dataFormatTxt.text()), |
|
357 | def loadUp(self): | |
639 | # opMode=str(self.operationModeCmbBox.currentText()), |
|
358 | self.addOpUpselec.clear() | |
640 | # readMode=str(self.readModeCmBox.currentText()), |
|
359 | ||
641 | # startDate=str(self.starDateCmbBox.currentText()), |
|
360 | for i in self.upObjList: | |
642 | # endDate=str(self.endDateCmbBox.currentText()), |
|
361 | name=i.getElementName() | |
643 | # startTime=str(self.starTem), |
|
362 | id=int(i.id)-1 | |
644 | # endTime=str(self.endTem)) |
|
363 | self.addOpUpselec.addItem(name+str(id)) | |
645 | # |
|
364 | ||
646 | # |
|
|||
647 | # branchNumber= len(projectObj.procBranchObjList) #Numero de Ramas |
|
|||
648 | # #=======================readBranchObj============== |
|
|||
649 | # for i in range(0,branchNumber): |
|
|||
650 | # projectObj.procBranchObjList[i] |
|
|||
651 | # idb=projectObj.procBranchObjList[i].id |
|
|||
652 | # # opObjTotal={} |
|
|||
653 | # |
|
|||
654 | # for j in range(0,branchNumber): |
|
|||
655 | # idb=projectObj.procBranchObjList[j].id |
|
|||
656 | # branch=self.braObjList[(idb)-1] |
|
|||
657 | # branch.upObjList |
|
|||
658 | # volNumber=len(branch.upObjList) |
|
|||
659 | # for i in range(0,volNumber): |
|
|||
660 | # unitProcess=branch.upObjList[i] |
|
|||
661 | # idv=branch.upObjList[i].id |
|
|||
662 | # |
|
|||
663 | # opObj11 = unitProcess.addOperation(id=1,name='removeDC', priority=1) |
|
|||
664 | # opObj11.addParameter(name='type', value='1') |
|
|||
665 | # opObj2 = unitProcess.addOperation(id=2,name='removeInterference', priority=1) |
|
|||
666 | # opObj3 = unitProcess.addOperation(id=3,name='removeSatelites', priority=1) |
|
|||
667 | # opObj4 = unitProcess.addOperation(id=4,name='coherent Integration', priority=1) |
|
|||
668 | # |
|
|||
669 | # projectObj.writeXml(filename) |
|
|||
670 | # |
|
|||
671 | #*############METODOS PARA INICIALIZAR-CONFIGURAR-CARGAR ARCHIVO-CARGAR VARIABLES######################## |
|
|||
672 |
|
365 | |||
673 | def setParam(self): |
|
366 | ||
|
367 | @pyqtSignature("int") | |||
|
368 | def on_selecChannelopVolCEB_stateChanged(self, p0): | |||
674 | """ |
|
369 | """ | |
675 | INICIALIZACION DE PARAMETROS PARA PRUEBAS |
|
370 | Slot documentation goes here. | |
676 | """ |
|
371 | """ | |
677 | #self.dataProyectTxt.setText('Test') |
|
372 | if p0==2: | |
678 | self.dataFormatTxt.setText('r') |
|
373 | upProcessSelect=self.upObjList[int(self.addOpUpselec.currentIndex())] | |
679 | self.dataPathTxt.setText('C:\\Users\\alex\\Documents\\ROJ\\ew_drifts') |
|
374 | opObj10=upProcessSelect.addOperation(name='selectChannels') | |
680 | self.dataWaitTxt.setText('0') |
|
375 | print opObj10.id | |
681 |
|
376 | self.operObjList.append(opObj10) | ||
682 | def make_parameters_conf(self): |
|
377 | print " Ingresa seleccion de Canales" | |
|
378 | if p0==0: | |||
|
379 | print " deshabilitado" | |||
|
380 | ||||
|
381 | @pyqtSignature("int") | |||
|
382 | def on_selecHeighopVolCEB_stateChanged(self, p0): | |||
683 | """ |
|
383 | """ | |
684 | ARCHIVO DE CONFIGURACION cCRA parameters.conf |
|
384 | Slot documentation goes here. | |
685 | """ |
|
385 | """ | |
686 |
|
|
386 | if p0==2: | |
687 |
|
387 | upProcessSelect=self.upObjList[int(self.addOpUpselec.currentIndex())] | ||
688 | def getParam(self): |
|
388 | opObj10=upProcessSelect.addOperation(name='selectHeights') | |
|
389 | print opObj10.id | |||
|
390 | self.operObjList.append(opObj10) | |||
|
391 | print " Select Type of Profile" | |||
|
392 | if p0==0: | |||
|
393 | print " deshabilitado" | |||
|
394 | ||||
|
395 | ||||
|
396 | ||||
|
397 | @pyqtSignature("int") | |||
|
398 | def on_coherentIntegrationCEB_stateChanged(self, p0): | |||
689 | """ |
|
399 | """ | |
690 | CARGA Proyect.xml |
|
400 | Slot documentation goes here. | |
691 | """ |
|
401 | """ | |
692 | print "Archivo XML AUN No adjuntado" |
|
402 | if p0==2: | |
|
403 | upProcessSelect=self.upObjList[int(self.addOpUpselec.currentIndex())] | |||
|
404 | opObj10=upProcessSelect.addOperation(name='CohInt', optype='other') | |||
|
405 | print opObj10.id | |||
|
406 | self.operObjList.append(opObj10) | |||
|
407 | print "Choose number of Cohint" | |||
|
408 | if p0==0: | |||
|
409 | print " deshabilitado" | |||
|
410 | ||||
693 |
|
411 | |||
694 | def setVariables(self): |
|
412 | @pyqtSignature("") | |
695 | """ |
|
413 | def on_dataopVolOkBtn_clicked(self): | |
696 | ACTUALIZACION DEL VALOR DE LAS VARIABLES CON LOS PARAMETROS SELECCIONADOS |
|
|||
697 |
|
|
414 | """ | |
698 | self.dataPath = str(self.dataPathTxt.text()) #0 |
|
415 | Slot documentation goes here. | |
699 | self.DataType= str(self.dataFormatTxt.text()) #3 |
|
416 | """ | |
700 |
|
417 | # print self.selecChannelopVolCEB.isOn() | ||
701 | def windowshow(self): |
|
418 | # print self.selecHeighopVolCEB.isOn() | |
702 | self.ventanaproject= Window(self) |
|
419 | # print self.coherentIntegrationCEB.isOn() | |
703 | self.ventanaproject.closed.connect(self.show) |
|
|||
704 | self.ventanaproject.show() |
|
|||
705 | # self.window() |
|
|||
706 | # self.window.closed.connect(self.show) |
|
|||
707 | # self.window.show() |
|
|||
708 | #self.hide() |
|
|||
709 |
|
||||
710 | def closeEvent(self, event): |
|
|||
711 | self.closed.emit() |
|
|||
712 | event.accept() |
|
|||
713 |
|
||||
714 |
|
||||
715 | class treeModel(QtCore.QAbstractItemModel): |
|
|||
716 | ''' |
|
|||
717 | a model to display a few names, ordered by encabezado |
|
|||
718 | ''' |
|
|||
719 | name=None |
|
|||
720 | directorio=None |
|
|||
721 | workspace=None |
|
|||
722 | opmode=None |
|
|||
723 | remode=None |
|
|||
724 | dataformat=None |
|
|||
725 | date=None |
|
|||
726 | initTime=None |
|
|||
727 | endTime=None |
|
|||
728 | timezone=None |
|
|||
729 | #Summary=None |
|
|||
730 |
|
||||
731 | def __init__(self ,parent=None): |
|
|||
732 | super(treeModel, self).__init__(parent) |
|
|||
733 | self.people = [] |
|
|||
734 |
|
420 | |||
735 | def arbol(self): |
|
|||
736 | for caracteristica,principal, descripcion in (("Properties","Name",self.name), |
|
|||
737 | ("Properties","Data Path",self.directorio), |
|
|||
738 | ("Properties","Workspace",self.workspace), |
|
|||
739 | ("Properties","Operation Mode ",self.opmode), |
|
|||
740 | ("Parameters", "Read Mode ",self.remode), |
|
|||
741 | ("Parameters", "DataFormat ",self.dataformat), |
|
|||
742 | ("Parameters", "Date ",self.date), |
|
|||
743 | ("Parameters", "Init Time ",self.initTime), |
|
|||
744 | ("Parameters", "Final Time ",self.endTime), |
|
|||
745 | ("Parameters", " Time zone ",self.timezone), |
|
|||
746 | ("Parameters", "Profiles ","1"), |
|
|||
747 | # ("Description", "Summary ", self.Summary), |
|
|||
748 | ): |
|
|||
749 | person = person_class(caracteristica, principal, descripcion) |
|
|||
750 | self.people.append(person) |
|
|||
751 |
|
||||
752 | self.rootItem = TreeItem(None, "ALL", None) |
|
|||
753 | self.parents = {0 : self.rootItem} |
|
|||
754 | self.setupModelData() |
|
|||
755 |
|
421 | |||
756 | #def veamos(self): |
|
|||
757 | # self.update= MainWindow(self) |
|
|||
758 | # self.update.dataProyectTxt.text() |
|
|||
759 | # return self.update.dataProyectTxt.text() |
|
|||
760 | def setParams(self,name,directorio,workspace,opmode,remode,dataformat,date,initTime,endTime,timezone): |
|
|||
761 | self.name=name |
|
|||
762 | self.workspace=workspace |
|
|||
763 | self.directorio= directorio |
|
|||
764 | self.opmode=opmode |
|
|||
765 | self.remode=remode |
|
|||
766 | self.dataformat=dataformat |
|
|||
767 | self.date=date |
|
|||
768 | self.initTime=initTime |
|
|||
769 | self.endTime=endTime |
|
|||
770 | self.timezone=timezone |
|
|||
771 | #self.Summary=Summary |
|
|||
772 |
|
422 | |||
773 |
|
423 | # if self.coherentIntegrationCEB.enabled(): | ||
774 | def columnCount(self, parent=None): |
|
424 | # self.operObjList[0]. | |
775 | if parent and parent.isValid(): |
|
425 | # | |
776 | return parent.internalPointer().columnCount() |
|
426 | ||
777 | else: |
|
427 | @pyqtSignature("") | |
778 | return len(HORIZONTAL_HEADERS) |
|
428 | def on_dataopSpecOkBtn_clicked(self): | |
779 |
|
429 | """ | ||
780 | def data(self, index, role): |
|
430 | Slot documentation goes here. | |
781 | if not index.isValid(): |
|
431 | """ | |
782 | return QtCore.QVariant() |
|
432 | print "Añadimos operaciones Spectra,nchannels,value,format" | |
783 |
|
||||
784 | item = index.internalPointer() |
|
|||
785 | if role == QtCore.Qt.DisplayRole: |
|
|||
786 | return item.data(index.column()) |
|
|||
787 | if role == QtCore.Qt.UserRole: |
|
|||
788 | if item: |
|
|||
789 | return item.person |
|
|||
790 |
|
||||
791 | return QtCore.QVariant() |
|
|||
792 |
|
||||
793 | def headerData(self, column, orientation, role): |
|
|||
794 | if (orientation == QtCore.Qt.Horizontal and |
|
|||
795 | role == QtCore.Qt.DisplayRole): |
|
|||
796 | try: |
|
|||
797 | return QtCore.QVariant(HORIZONTAL_HEADERS[column]) |
|
|||
798 | except IndexError: |
|
|||
799 | pass |
|
|||
800 |
|
||||
801 | return QtCore.QVariant() |
|
|||
802 |
|
||||
803 | def index(self, row, column, parent): |
|
|||
804 | if not self.hasIndex(row, column, parent): |
|
|||
805 | return QtCore.QModelIndex() |
|
|||
806 |
|
||||
807 | if not parent.isValid(): |
|
|||
808 | parentItem = self.rootItem |
|
|||
809 | else: |
|
|||
810 | parentItem = parent.internalPointer() |
|
|||
811 |
|
||||
812 | childItem = parentItem.child(row) |
|
|||
813 | if childItem: |
|
|||
814 | return self.createIndex(row, column, childItem) |
|
|||
815 | else: |
|
|||
816 | return QtCore.QModelIndex() |
|
|||
817 |
|
||||
818 | def parent(self, index): |
|
|||
819 | if not index.isValid(): |
|
|||
820 | return QtCore.QModelIndex() |
|
|||
821 |
|
||||
822 | childItem = index.internalPointer() |
|
|||
823 | if not childItem: |
|
|||
824 | return QtCore.QModelIndex() |
|
|||
825 |
|
||||
826 | parentItem = childItem.parent() |
|
|||
827 |
|
||||
828 | if parentItem == self.rootItem: |
|
|||
829 | return QtCore.QModelIndex() |
|
|||
830 |
|
433 | |||
831 | return self.createIndex(parentItem.row(), 0, parentItem) |
|
434 | opObj10 = self.procUnitConfObj0.addOperation(name='selectChannels') | |
|
435 | opObj10.addParameter(name='channelList', value='3,4,5', format='intlist') | |||
832 |
|
436 | |||
833 | def rowCount(self, parent=QtCore.QModelIndex()): |
|
437 | opObj10 = self.procUnitConfObj0.addOperation(name='selectHeights') | |
834 | if parent.column() > 0: |
|
438 | opObj10.addParameter(name='minHei', value='90', format='float') | |
835 | return 0 |
|
439 | opObj10.addParameter(name='maxHei', value='180', format='float') | |
836 | if not parent.isValid(): |
|
|||
837 | p_Item = self.rootItem |
|
|||
838 | else: |
|
|||
839 | p_Item = parent.internalPointer() |
|
|||
840 | return p_Item.childCount() |
|
|||
841 |
|
440 | |||
842 | def setupModelData(self): |
|
441 | opObj12 = self.procUnitConfObj0.addOperation(name='CohInt', optype='other') | |
843 | for person in self.people: |
|
442 | opObj12.addParameter(name='n', value='10', format='int') | |
844 | if person.descripcion: |
|
443 | ||
845 | encabezado = person.caracteristica |
|
|||
846 |
|
||||
847 |
|
||||
848 | if not self.parents.has_key(encabezado): |
|
|||
849 | newparent = TreeItem(None, encabezado, self.rootItem) |
|
|||
850 | self.rootItem.appendChild(newparent) |
|
|||
851 |
|
444 | |||
852 | self.parents[encabezado] = newparent |
|
445 | @pyqtSignature("") | |
|
446 | def on_dataGraphSpecOkBtn_clicked(self): | |||
|
447 | """ | |||
|
448 | Slot documentation goes here. | |||
|
449 | """ | |||
|
450 | print "Graficar Spec op" | |||
|
451 | # TODO: not implemented yet | |||
|
452 | #raise NotImplementedError | |||
853 |
|
453 | |||
854 | parentItem = self.parents[encabezado] |
|
|||
855 | newItem = TreeItem(person, "", parentItem) |
|
|||
856 | parentItem.appendChild(newItem) |
|
|||
857 |
|
454 | |||
858 | def searchModel(self, person): |
|
455 | ||
859 | ''' |
|
|||
860 | get the modelIndex for a given appointment |
|
|||
861 | ''' |
|
|||
862 | def searchNode(node): |
|
|||
863 | ''' |
|
|||
864 | a function called recursively, looking at all nodes beneath node |
|
|||
865 | ''' |
|
|||
866 | for child in node.childItems: |
|
|||
867 | if person == child.person: |
|
|||
868 | index = self.createIndex(child.row(), 0, child) |
|
|||
869 | return index |
|
|||
870 |
|
||||
871 | if child.childCount() > 0: |
|
|||
872 | result = searchNode(child) |
|
|||
873 | if result: |
|
|||
874 | return result |
|
|||
875 |
|
456 | |||
876 | retarg = searchNode(self.parents[0]) |
|
457 | @pyqtSignature("") | |
877 | #print retarg |
|
458 | def on_actionguardarObj_triggered(self): | |
878 | return retarg |
|
459 | """ | |
|
460 | GUARDAR EL ARCHIVO DE CONFIGURACION XML | |||
|
461 | """ | |||
|
462 | if self.idp==1: | |||
|
463 | self.valuep=1 | |||
879 |
|
464 | |||
880 | def find_GivenName(self, principal): |
|
465 | print "Escribiendo el archivo XML" | |
881 | app = None |
|
466 | filename="C:\\WorkspaceGUI\\CONFIG"+str(self.valuep)+".xml" | |
882 | for person in self.people: |
|
467 | self.controllerObj=self.proObjList[int(self.valuep)-1] | |
883 | if person.principal == principal: |
|
468 | self.controllerObj.writeXml(filename) | |
884 | app = person |
|
|||
885 | break |
|
|||
886 | if app != None: |
|
|||
887 | index = self.searchModel(app) |
|
|||
888 | return (True, index) |
|
|||
889 | return (False, None) |
|
|||
890 |
|
469 | |||
891 |
|
|
470 | ||
892 |
|
471 | class Window(QMainWindow, Ui_window): | ||
893 | class Workspace(QMainWindow, Ui_Workspace): |
|
|||
894 | """ |
|
472 | """ | |
895 | Class documentation goes here. |
|
473 | Class documentation goes here. | |
896 | """ |
|
474 | """ | |
@@ -901,134 +479,137 class Workspace(QMainWindow, Ui_Workspace): | |||||
901 | """ |
|
479 | """ | |
902 | QMainWindow.__init__(self, parent) |
|
480 | QMainWindow.__init__(self, parent) | |
903 | self.setupUi(self) |
|
481 | self.setupUi(self) | |
904 | #*####### DIRECTORIO DE TRABAJO #########*# |
|
482 | self.name=0 | |
905 | self.dirCmbBox.setItemText(0, QtGui.QApplication.translate("MainWindow", "C:\WorkSpaceGui", None, QtGui.QApplication.UnicodeUTF8)) |
|
483 | self.nameproject=None | |
906 | self.dir=str("C:\WorkSpaceGui") |
|
484 | self.proyectNameLine.setText('My_name_is...') | |
907 | self.dirCmbBox.addItem(self.dir) |
|
485 | self.descriptionTextEdit.setText('Write a description...') | |
908 |
|
486 | |||
|
487 | ||||
909 | @pyqtSignature("") |
|
488 | @pyqtSignature("") | |
910 |
def on_ |
|
489 | def on_cancelButton_clicked(self): | |
911 | """ |
|
490 | """ | |
912 | Slot documentation goes here. |
|
491 | Slot documentation goes here. | |
913 | """ |
|
492 | """ | |
914 | self.dirBrowse = str(QtGui.QFileDialog.getExistingDirectory(self, 'Open Directory', './', QtGui.QFileDialog.ShowDirsOnly)) |
|
493 | # TODO: not implemented yet | |
915 | self.dirCmbBox.addItem(self.dirBrowse) |
|
494 | #raise NotImplementedError | |
|
495 | ||||
|
496 | self.hide() | |||
916 |
|
497 | |||
917 | @pyqtSignature("") |
|
498 | @pyqtSignature("") | |
918 |
def on_ |
|
499 | def on_okButton_clicked(self): | |
919 | """ |
|
500 | """ | |
920 | Slot documentation goes here. |
|
501 | Slot documentation goes here. | |
921 | """ |
|
502 | """ | |
|
503 | #self.almacena() | |||
|
504 | self.close() | |||
922 |
|
505 | |||
923 | @pyqtSignature("") |
|
506 | @pyqtSignature("") | |
924 |
def on_ |
|
507 | def on_saveButton_clicked(self): | |
925 | """ |
|
508 | """ | |
926 | VISTA DE INTERFAZ GRÃFICA |
|
509 | Slot documentation goes here. | |
927 | """ |
|
510 | """ | |
928 |
self. |
|
511 | self.almacena() | |
|
512 | # self.close() | |||
929 |
|
513 | |||
930 |
|
514 | def almacena(self): | ||
931 | @pyqtSignature("") |
|
515 | #print str(self.proyectNameLine.text()) | |
932 | def on_dirCancelbtn_clicked(self): |
|
516 | self.nameproject=str(self.proyectNameLine.text()) | |
933 | """ |
|
517 | self.description=str(self.descriptionTextEdit.toPlainText()) | |
934 | Cerrar |
|
518 | return self.nameproject,self.description | |
935 |
|
|
519 | ||
936 | self.close() |
|
|||
937 |
|
||||
938 | def showmemainwindow(self): |
|
|||
939 | self.Dialog= MainWindow(self) |
|
|||
940 | self.Dialog.closed.connect(self.show) |
|
|||
941 | self.Dialog.show() |
|
|||
942 | self.hide() |
|
|||
943 |
|
||||
944 | def closeEvent(self, event): |
|
520 | def closeEvent(self, event): | |
945 | self.closed.emit() |
|
521 | self.closed.emit() | |
946 | event.accept() |
|
522 | event.accept() | |
947 |
|
||||
948 |
|
523 | |||
949 | class InitWindow(QMainWindow, Ui_InitWindow): |
|
524 | ||
|
525 | class UnitProcess(QMainWindow, Ui_UnitProcess): | |||
950 | """ |
|
526 | """ | |
951 | Class documentation goes here. |
|
527 | Class documentation goes here. | |
952 | """ |
|
528 | """ | |
|
529 | closed=pyqtSignal() | |||
953 | def __init__(self, parent = None): |
|
530 | def __init__(self, parent = None): | |
954 | """ |
|
531 | """ | |
955 | Constructor |
|
532 | Constructor | |
956 | """ |
|
533 | """ | |
957 | QMainWindow.__init__(self, parent) |
|
534 | QMainWindow.__init__(self, parent) | |
958 | self.setupUi(self) |
|
535 | self.setupUi(self) | |
959 |
|
536 | self.getFromWindow=None | ||
960 |
|
537 | self.getfromWindowList=[] | ||
961 | @pyqtSignature("") |
|
538 | ||
962 | def on_pushButton_2_clicked(self): |
|
539 | self.listUP=None | |
963 | """ |
|
|||
964 | Close First Window |
|
|||
965 | """ |
|
|||
966 | self.close() |
|
|||
967 |
|
540 | |||
968 | @pyqtSignature("") |
|
541 | def loadTotalList(self): | |
969 | def on_pushButton_clicked(self): |
|
542 | self.comboInputBox.clear() | |
|
543 | for i in self.getfromWindowList: | |||
|
544 | name=i.getElementName() | |||
|
545 | id= i.id | |||
|
546 | if i.getElementName()=='ProcUnit': | |||
|
547 | id=int(i.id)-1 | |||
|
548 | self.comboInputBox.addItem(str(name)+str(id)) | |||
|
549 | ||||
|
550 | @pyqtSignature("QString") | |||
|
551 | def on_comboInputBox_activated(self, p0): | |||
970 | """ |
|
552 | """ | |
971 | Show Workspace Window |
|
553 | Slot documentation goes here. | |
972 | """ |
|
554 | """ | |
973 | self.showmeconfig() |
|
555 | ||
|
556 | # TODO: not implemented yet | |||
|
557 | #raise NotImplementedError | |||
974 |
|
558 | |||
975 | def showmeconfig(self): |
|
559 | @pyqtSignature("QString") | |
976 | ''' |
|
560 | def on_comboTypeBox_activated(self, p0): | |
977 | Method to call Workspace |
|
|||
978 | ''' |
|
|||
979 |
|
||||
980 | self.config=Workspace(self) |
|
|||
981 | self.config.closed.connect(self.show) |
|
|||
982 | self.config.show() |
|
|||
983 | self.hide() |
|
|||
984 |
|
||||
985 |
|
||||
986 | class Window(QMainWindow, Ui_window): |
|
|||
987 | """ |
|
|||
988 | Class documentation goes here. |
|
|||
989 | """ |
|
|||
990 | closed=pyqtSignal() |
|
|||
991 | def __init__(self, parent = None): |
|
|||
992 | """ |
|
561 | """ | |
993 | Constructor |
|
562 | Slot documentation goes here. | |
994 | """ |
|
563 | """ | |
995 | QMainWindow.__init__(self, parent) |
|
564 | # TODO: not implemented yet | |
996 | self.setupUi(self) |
|
565 | #raise NotImplementedError | |
997 | self.name=0 |
|
566 | ||
998 | self.nameproject=None |
|
|||
999 |
|
||||
1000 | @pyqtSignature("") |
|
567 | @pyqtSignature("") | |
1001 |
def on_ |
|
568 | def on_unitPokbut_clicked(self): | |
1002 | """ |
|
569 | """ | |
1003 | Slot documentation goes here. |
|
570 | Slot documentation goes here. | |
1004 | """ |
|
571 | """ | |
1005 | # TODO: not implemented yet |
|
572 | # TODO: not implemented yet | |
1006 | #raise NotImplementedError |
|
573 | #raise NotImplementedError | |
1007 |
self. |
|
574 | self.close() | |
1008 |
|
575 | |||
1009 | @pyqtSignature("") |
|
576 | @pyqtSignature("") | |
1010 |
def on_ |
|
577 | def on_unitPsavebut_clicked(self): | |
1011 | """ |
|
578 | """ | |
1012 | Slot documentation goes here. |
|
579 | Slot documentation goes here. | |
1013 | """ |
|
580 | """ | |
1014 | # TODO: not implemented yet |
|
581 | # TODO: not implemented yet | |
1015 | #raise NotImplementedError |
|
582 | #raise NotImplementedError | |
1016 |
|
|
583 | #self.getListMainWindow() | |
1017 |
print |
|
584 | print "alex" | |
1018 | self.close() |
|
|||
1019 |
|
585 | |||
|
586 | #for i in self.getfromWindowList: | |||
|
587 | #print i | |||
|
588 | ||||
|
589 | self.almacena() | |||
1020 |
|
590 | |||
|
591 | @pyqtSignature("") | |||
|
592 | def on_unitPcancelbut_clicked(self): | |||
|
593 | """ | |||
|
594 | Slot documentation goes here. | |||
|
595 | """ | |||
|
596 | # TODO: not implemented yet | |||
|
597 | #raise NotImplementedError | |||
|
598 | self.hide() | |||
|
599 | ||||
1021 | def almacena(self): |
|
600 | def almacena(self): | |
1022 | #print str(self.proyectNameLine.text()) |
|
601 | self.getFromWindow=self.getfromWindowList[int(self.comboInputBox.currentIndex())] | |
1023 |
self.name |
|
602 | #self.nameofUP= str(self.nameUptxt.text()) | |
1024 | return self.nameproject |
|
603 | self.typeofUP= str(self.comboTypeBox.currentText()) | |
1025 |
|
604 | return self.getFromWindow,self.typeofUP | ||
|
605 | ||||
1026 | def closeEvent(self, event): |
|
606 | def closeEvent(self, event): | |
1027 | self.closed.emit() |
|
607 | self.closed.emit() | |
1028 | event.accept() |
|
608 | event.accept() | |
1029 |
|
609 | |||
1030 |
|
|
610 | ||
1031 |
|
|
611 | ||
1032 |
|
||||
1033 |
|
612 | |||
|
613 | ||||
|
614 | ||||
1034 | No newline at end of file |
|
615 |
@@ -1,5 +1,188 | |||||
1 | from PyQt4 import QtCore |
|
1 | from PyQt4 import QtCore | |
2 |
|
2 | |||
|
3 | HORIZONTAL_HEADERS = ("ITEM :"," DATOS : " ) | |||
|
4 | ||||
|
5 | HORIZONTAL = ("RAMA :",) | |||
|
6 | ||||
|
7 | class treeModel(QtCore.QAbstractItemModel): | |||
|
8 | ''' | |||
|
9 | a model to display a few names, ordered by encabezado | |||
|
10 | ''' | |||
|
11 | name=None | |||
|
12 | directorio=None | |||
|
13 | workspace=None | |||
|
14 | remode=None | |||
|
15 | dataformat=None | |||
|
16 | date=None | |||
|
17 | initTime=None | |||
|
18 | endTime=None | |||
|
19 | timezone=None | |||
|
20 | Summary=None | |||
|
21 | ||||
|
22 | def __init__(self ,parent=None): | |||
|
23 | super(treeModel, self).__init__(parent) | |||
|
24 | self.people = [] | |||
|
25 | ||||
|
26 | def arbol(self): | |||
|
27 | for caracteristica,principal, descripcion in (("Properties","Name",self.name), | |||
|
28 | ("Properties","Data Path",self.directorio), | |||
|
29 | ("Properties","Workspace",self.workspace), | |||
|
30 | ("Parameters", "Read Mode ",self.remode), | |||
|
31 | ("Parameters", "DataType ",self.dataformat), | |||
|
32 | ("Parameters", "Date ",self.date), | |||
|
33 | ("Parameters", "Init Time ",self.initTime), | |||
|
34 | ("Parameters", "Final Time ",self.endTime), | |||
|
35 | ("Parameters", " Time zone ",self.timezone), | |||
|
36 | ("Parameters", "Profiles ","1"), | |||
|
37 | ("Description", "Summary ", self.Summary), | |||
|
38 | ): | |||
|
39 | person = person_class(caracteristica, principal, descripcion) | |||
|
40 | self.people.append(person) | |||
|
41 | ||||
|
42 | self.rootItem = TreeItem(None, "ALL", None) | |||
|
43 | self.parents = {0 : self.rootItem} | |||
|
44 | self.setupModelData() | |||
|
45 | ||||
|
46 | #def veamos(self): | |||
|
47 | # self.update= MainWindow(self) | |||
|
48 | # self.update.dataProyectTxt.text() | |||
|
49 | # return self.update.dataProyectTxt.text() | |||
|
50 | def setParams(self,name,directorio,workspace,remode,dataformat,date,initTime,endTime,timezone,Summary): | |||
|
51 | self.name=name | |||
|
52 | self.workspace=workspace | |||
|
53 | self.directorio= directorio | |||
|
54 | self.remode=remode | |||
|
55 | self.dataformat=dataformat | |||
|
56 | self.date=date | |||
|
57 | self.initTime=initTime | |||
|
58 | self.endTime=endTime | |||
|
59 | self.timezone=timezone | |||
|
60 | self.Summary=Summary | |||
|
61 | ||||
|
62 | ||||
|
63 | def columnCount(self, parent=None): | |||
|
64 | if parent and parent.isValid(): | |||
|
65 | return parent.internalPointer().columnCount() | |||
|
66 | else: | |||
|
67 | return len(HORIZONTAL_HEADERS) | |||
|
68 | ||||
|
69 | def data(self, index, role): | |||
|
70 | if not index.isValid(): | |||
|
71 | return QtCore.QVariant() | |||
|
72 | ||||
|
73 | item = index.internalPointer() | |||
|
74 | if role == QtCore.Qt.DisplayRole: | |||
|
75 | return item.data(index.column()) | |||
|
76 | if role == QtCore.Qt.UserRole: | |||
|
77 | if item: | |||
|
78 | return item.person | |||
|
79 | ||||
|
80 | return QtCore.QVariant() | |||
|
81 | ||||
|
82 | def headerData(self, column, orientation, role): | |||
|
83 | if (orientation == QtCore.Qt.Horizontal and | |||
|
84 | role == QtCore.Qt.DisplayRole): | |||
|
85 | try: | |||
|
86 | return QtCore.QVariant(HORIZONTAL_HEADERS[column]) | |||
|
87 | except IndexError: | |||
|
88 | pass | |||
|
89 | ||||
|
90 | return QtCore.QVariant() | |||
|
91 | ||||
|
92 | def index(self, row, column, parent): | |||
|
93 | if not self.hasIndex(row, column, parent): | |||
|
94 | return QtCore.QModelIndex() | |||
|
95 | ||||
|
96 | if not parent.isValid(): | |||
|
97 | parentItem = self.rootItem | |||
|
98 | else: | |||
|
99 | parentItem = parent.internalPointer() | |||
|
100 | ||||
|
101 | childItem = parentItem.child(row) | |||
|
102 | if childItem: | |||
|
103 | return self.createIndex(row, column, childItem) | |||
|
104 | else: | |||
|
105 | return QtCore.QModelIndex() | |||
|
106 | ||||
|
107 | def parent(self, index): | |||
|
108 | if not index.isValid(): | |||
|
109 | return QtCore.QModelIndex() | |||
|
110 | ||||
|
111 | childItem = index.internalPointer() | |||
|
112 | if not childItem: | |||
|
113 | return QtCore.QModelIndex() | |||
|
114 | ||||
|
115 | parentItem = childItem.parent() | |||
|
116 | ||||
|
117 | if parentItem == self.rootItem: | |||
|
118 | return QtCore.QModelIndex() | |||
|
119 | ||||
|
120 | return self.createIndex(parentItem.row(), 0, parentItem) | |||
|
121 | ||||
|
122 | def rowCount(self, parent=QtCore.QModelIndex()): | |||
|
123 | if parent.column() > 0: | |||
|
124 | return 0 | |||
|
125 | if not parent.isValid(): | |||
|
126 | p_Item = self.rootItem | |||
|
127 | else: | |||
|
128 | p_Item = parent.internalPointer() | |||
|
129 | return p_Item.childCount() | |||
|
130 | ||||
|
131 | def setupModelData(self): | |||
|
132 | for person in self.people: | |||
|
133 | if person.descripcion: | |||
|
134 | encabezado = person.caracteristica | |||
|
135 | ||||
|
136 | ||||
|
137 | if not self.parents.has_key(encabezado): | |||
|
138 | newparent = TreeItem(None, encabezado, self.rootItem) | |||
|
139 | self.rootItem.appendChild(newparent) | |||
|
140 | ||||
|
141 | self.parents[encabezado] = newparent | |||
|
142 | ||||
|
143 | parentItem = self.parents[encabezado] | |||
|
144 | newItem = TreeItem(person, "", parentItem) | |||
|
145 | parentItem.appendChild(newItem) | |||
|
146 | ||||
|
147 | def searchModel(self, person): | |||
|
148 | ''' | |||
|
149 | get the modelIndex for a given appointment | |||
|
150 | ''' | |||
|
151 | def searchNode(node): | |||
|
152 | ''' | |||
|
153 | a function called recursively, looking at all nodes beneath node | |||
|
154 | ''' | |||
|
155 | for child in node.childItems: | |||
|
156 | if person == child.person: | |||
|
157 | index = self.createIndex(child.row(), 0, child) | |||
|
158 | return index | |||
|
159 | ||||
|
160 | if child.childCount() > 0: | |||
|
161 | result = searchNode(child) | |||
|
162 | if result: | |||
|
163 | return result | |||
|
164 | ||||
|
165 | retarg = searchNode(self.parents[0]) | |||
|
166 | #print retarg | |||
|
167 | return retarg | |||
|
168 | ||||
|
169 | def find_GivenName(self, principal): | |||
|
170 | app = None | |||
|
171 | for person in self.people: | |||
|
172 | if person.principal == principal: | |||
|
173 | app = person | |||
|
174 | break | |||
|
175 | if app != None: | |||
|
176 | index = self.searchModel(app) | |||
|
177 | return (True, index) | |||
|
178 | return (False, None) | |||
|
179 | ||||
|
180 | ||||
|
181 | ||||
|
182 | ||||
|
183 | ||||
|
184 | ||||
|
185 | ||||
3 | class person_class(object): |
|
186 | class person_class(object): | |
4 | ''' |
|
187 | ''' | |
5 | a trivial custom data object |
|
188 | a trivial custom data object |
This diff has been collapsed as it changes many lines, (610 lines changed) Show them Hide them | |||||
@@ -1,8 +1,8 | |||||
1 | # -*- coding: utf-8 -*- |
|
1 | # -*- coding: utf-8 -*- | |
2 |
|
2 | |||
3 |
# Form implementation generated from reading ui file 'C:\Users\alex\ericworkspace\UIDOS\MainWindow |
|
3 | # Form implementation generated from reading ui file 'C:\Users\alex\ericworkspace\UIDOS\MainWindow_NOVTRES.ui' | |
4 | # |
|
4 | # | |
5 |
# Created: Mon Dec |
|
5 | # Created: Mon Dec 10 11:44:05 2012 | |
6 | # by: PyQt4 UI code generator 4.9.4 |
|
6 | # by: PyQt4 UI code generator 4.9.4 | |
7 | # |
|
7 | # | |
8 | # WARNING! All changes made in this file will be lost! |
|
8 | # WARNING! All changes made in this file will be lost! | |
@@ -17,7 +17,7 except AttributeError: | |||||
17 | class Ui_MainWindow(object): |
|
17 | class Ui_MainWindow(object): | |
18 | def setupUi(self, MainWindow): |
|
18 | def setupUi(self, MainWindow): | |
19 | MainWindow.setObjectName(_fromUtf8("MainWindow")) |
|
19 | MainWindow.setObjectName(_fromUtf8("MainWindow")) | |
20 |
MainWindow.resize(85 |
|
20 | MainWindow.resize(854, 569) | |
21 | self.centralWidget = QtGui.QWidget(MainWindow) |
|
21 | self.centralWidget = QtGui.QWidget(MainWindow) | |
22 | self.centralWidget.setObjectName(_fromUtf8("centralWidget")) |
|
22 | self.centralWidget.setObjectName(_fromUtf8("centralWidget")) | |
23 | self.frame_2 = QtGui.QFrame(self.centralWidget) |
|
23 | self.frame_2 = QtGui.QFrame(self.centralWidget) | |
@@ -55,20 +55,17 class Ui_MainWindow(object): | |||||
55 | self.frame_9.setFrameShadow(QtGui.QFrame.Plain) |
|
55 | self.frame_9.setFrameShadow(QtGui.QFrame.Plain) | |
56 | self.frame_9.setObjectName(_fromUtf8("frame_9")) |
|
56 | self.frame_9.setObjectName(_fromUtf8("frame_9")) | |
57 | self.label = QtGui.QLabel(self.frame_9) |
|
57 | self.label = QtGui.QLabel(self.frame_9) | |
58 |
self.label.setGeometry(QtCore.QRect( |
|
58 | self.label.setGeometry(QtCore.QRect(70, 0, 101, 31)) | |
59 | font = QtGui.QFont() |
|
59 | font = QtGui.QFont() | |
60 | font.setPointSize(11) |
|
60 | font.setPointSize(11) | |
61 | self.label.setFont(font) |
|
61 | self.label.setFont(font) | |
62 | self.label.setObjectName(_fromUtf8("label")) |
|
62 | self.label.setObjectName(_fromUtf8("label")) | |
63 | self.addpBtn = QtGui.QPushButton(self.frame_9) |
|
63 | self.addpBtn = QtGui.QPushButton(self.frame_9) | |
64 |
self.addpBtn.setGeometry(QtCore.QRect( |
|
64 | self.addpBtn.setGeometry(QtCore.QRect(20, 30, 91, 23)) | |
65 | self.addpBtn.setObjectName(_fromUtf8("addpBtn")) |
|
65 | self.addpBtn.setObjectName(_fromUtf8("addpBtn")) | |
66 |
self.add |
|
66 | self.addUnitProces = QtGui.QPushButton(self.frame_9) | |
67 |
self.add |
|
67 | self.addUnitProces.setGeometry(QtCore.QRect(120, 30, 91, 23)) | |
68 |
self.add |
|
68 | self.addUnitProces.setObjectName(_fromUtf8("addUnitProces")) | |
69 | self.addoBtn = QtGui.QPushButton(self.frame_9) |
|
|||
70 | self.addoBtn.setGeometry(QtCore.QRect(160, 30, 61, 23)) |
|
|||
71 | self.addoBtn.setObjectName(_fromUtf8("addoBtn")) |
|
|||
72 | self.scrollArea = QtGui.QScrollArea(self.frame) |
|
69 | self.scrollArea = QtGui.QScrollArea(self.frame) | |
73 | self.scrollArea.setGeometry(QtCore.QRect(10, 80, 231, 421)) |
|
70 | self.scrollArea.setGeometry(QtCore.QRect(10, 80, 231, 421)) | |
74 | self.scrollArea.setWidgetResizable(True) |
|
71 | self.scrollArea.setWidgetResizable(True) | |
@@ -96,7 +93,7 class Ui_MainWindow(object): | |||||
96 | self.tab_5 = QtGui.QWidget() |
|
93 | self.tab_5 = QtGui.QWidget() | |
97 | self.tab_5.setObjectName(_fromUtf8("tab_5")) |
|
94 | self.tab_5.setObjectName(_fromUtf8("tab_5")) | |
98 | self.frame_5 = QtGui.QFrame(self.tab_5) |
|
95 | self.frame_5 = QtGui.QFrame(self.tab_5) | |
99 |
self.frame_5.setGeometry(QtCore.QRect(10, 1 |
|
96 | self.frame_5.setGeometry(QtCore.QRect(10, 130, 261, 31)) | |
100 | font = QtGui.QFont() |
|
97 | font = QtGui.QFont() | |
101 | font.setPointSize(10) |
|
98 | font.setPointSize(10) | |
102 | self.frame_5.setFont(font) |
|
99 | self.frame_5.setFont(font) | |
@@ -124,38 +121,38 class Ui_MainWindow(object): | |||||
124 | self.dataWaitLine.setFont(font) |
|
121 | self.dataWaitLine.setFont(font) | |
125 | self.dataWaitLine.setObjectName(_fromUtf8("dataWaitLine")) |
|
122 | self.dataWaitLine.setObjectName(_fromUtf8("dataWaitLine")) | |
126 | self.dataWaitTxt = QtGui.QLineEdit(self.frame_5) |
|
123 | self.dataWaitTxt = QtGui.QLineEdit(self.frame_5) | |
127 |
self.dataWaitTxt.setGeometry(QtCore.QRect(230, 10, 21, |
|
124 | self.dataWaitTxt.setGeometry(QtCore.QRect(230, 10, 21, 16)) | |
128 | self.dataWaitTxt.setObjectName(_fromUtf8("dataWaitTxt")) |
|
125 | self.dataWaitTxt.setObjectName(_fromUtf8("dataWaitTxt")) | |
129 | self.frame_4 = QtGui.QFrame(self.tab_5) |
|
126 | self.frame_4 = QtGui.QFrame(self.tab_5) | |
130 |
self.frame_4.setGeometry(QtCore.QRect(10, 60, 261, |
|
127 | self.frame_4.setGeometry(QtCore.QRect(10, 60, 261, 61)) | |
131 | self.frame_4.setFrameShape(QtGui.QFrame.StyledPanel) |
|
128 | self.frame_4.setFrameShape(QtGui.QFrame.StyledPanel) | |
132 | self.frame_4.setFrameShadow(QtGui.QFrame.Plain) |
|
129 | self.frame_4.setFrameShadow(QtGui.QFrame.Plain) | |
133 | self.frame_4.setObjectName(_fromUtf8("frame_4")) |
|
130 | self.frame_4.setObjectName(_fromUtf8("frame_4")) | |
134 |
self.data |
|
131 | self.dataTypeLine = QtGui.QLabel(self.frame_4) | |
135 |
self.data |
|
132 | self.dataTypeLine.setGeometry(QtCore.QRect(10, 10, 81, 16)) | |
136 | font = QtGui.QFont() |
|
133 | font = QtGui.QFont() | |
137 | font.setPointSize(10) |
|
134 | font.setPointSize(10) | |
138 |
self.data |
|
135 | self.dataTypeLine.setFont(font) | |
139 |
self.data |
|
136 | self.dataTypeLine.setObjectName(_fromUtf8("dataTypeLine")) | |
140 | self.dataPathline = QtGui.QLabel(self.frame_4) |
|
137 | self.dataPathline = QtGui.QLabel(self.frame_4) | |
141 |
self.dataPathline.setGeometry(QtCore.QRect(10, |
|
138 | self.dataPathline.setGeometry(QtCore.QRect(10, 40, 81, 19)) | |
142 | font = QtGui.QFont() |
|
139 | font = QtGui.QFont() | |
143 | font.setPointSize(10) |
|
140 | font.setPointSize(10) | |
144 | self.dataPathline.setFont(font) |
|
141 | self.dataPathline.setFont(font) | |
145 | self.dataPathline.setObjectName(_fromUtf8("dataPathline")) |
|
142 | self.dataPathline.setObjectName(_fromUtf8("dataPathline")) | |
146 |
self.data |
|
143 | self.dataTypeCmbBox = QtGui.QComboBox(self.frame_4) | |
147 |
self.data |
|
144 | self.dataTypeCmbBox.setGeometry(QtCore.QRect(80, 10, 111, 21)) | |
148 | font = QtGui.QFont() |
|
145 | font = QtGui.QFont() | |
149 | font.setPointSize(10) |
|
146 | font.setPointSize(10) | |
150 |
self.data |
|
147 | self.dataTypeCmbBox.setFont(font) | |
151 |
self.data |
|
148 | self.dataTypeCmbBox.setObjectName(_fromUtf8("dataTypeCmbBox")) | |
152 |
self.data |
|
149 | self.dataTypeCmbBox.addItem(_fromUtf8("")) | |
153 |
self.data |
|
150 | self.dataTypeCmbBox.addItem(_fromUtf8("")) | |
154 | self.dataPathTxt = QtGui.QLineEdit(self.frame_4) |
|
151 | self.dataPathTxt = QtGui.QLineEdit(self.frame_4) | |
155 |
self.dataPathTxt.setGeometry(QtCore.QRect( |
|
152 | self.dataPathTxt.setGeometry(QtCore.QRect(80, 40, 141, 16)) | |
156 | self.dataPathTxt.setObjectName(_fromUtf8("dataPathTxt")) |
|
153 | self.dataPathTxt.setObjectName(_fromUtf8("dataPathTxt")) | |
157 | self.dataPathBrowse = QtGui.QPushButton(self.frame_4) |
|
154 | self.dataPathBrowse = QtGui.QPushButton(self.frame_4) | |
158 |
self.dataPathBrowse.setGeometry(QtCore.QRect(230, |
|
155 | self.dataPathBrowse.setGeometry(QtCore.QRect(230, 40, 20, 16)) | |
159 | self.dataPathBrowse.setObjectName(_fromUtf8("dataPathBrowse")) |
|
156 | self.dataPathBrowse.setObjectName(_fromUtf8("dataPathBrowse")) | |
160 | self.dataFormatTxt = QtGui.QLineEdit(self.frame_4) |
|
157 | self.dataFormatTxt = QtGui.QLineEdit(self.frame_4) | |
161 | self.dataFormatTxt.setGeometry(QtCore.QRect(200, 10, 51, 16)) |
|
158 | self.dataFormatTxt.setGeometry(QtCore.QRect(200, 10, 51, 16)) | |
@@ -166,421 +163,138 class Ui_MainWindow(object): | |||||
166 | self.frame_3.setFrameShadow(QtGui.QFrame.Plain) |
|
163 | self.frame_3.setFrameShadow(QtGui.QFrame.Plain) | |
167 | self.frame_3.setObjectName(_fromUtf8("frame_3")) |
|
164 | self.frame_3.setObjectName(_fromUtf8("frame_3")) | |
168 | self.dataOperationModeline = QtGui.QLabel(self.frame_3) |
|
165 | self.dataOperationModeline = QtGui.QLabel(self.frame_3) | |
169 |
self.dataOperationModeline.setGeometry(QtCore.QRect(10, 10, 1 |
|
166 | self.dataOperationModeline.setGeometry(QtCore.QRect(10, 10, 131, 20)) | |
170 | font = QtGui.QFont() |
|
167 | font = QtGui.QFont() | |
171 | font.setPointSize(10) |
|
168 | font.setPointSize(10) | |
172 | self.dataOperationModeline.setFont(font) |
|
169 | self.dataOperationModeline.setFont(font) | |
173 | self.dataOperationModeline.setObjectName(_fromUtf8("dataOperationModeline")) |
|
170 | self.dataOperationModeline.setObjectName(_fromUtf8("dataOperationModeline")) | |
174 |
self. |
|
171 | self.proConfCmbBox = QtGui.QComboBox(self.frame_3) | |
175 |
self. |
|
172 | self.proConfCmbBox.setGeometry(QtCore.QRect(150, 10, 101, 20)) | |
176 | font = QtGui.QFont() |
|
173 | font = QtGui.QFont() | |
177 | font.setPointSize(10) |
|
174 | font.setPointSize(10) | |
178 |
self. |
|
175 | self.proConfCmbBox.setFont(font) | |
179 |
self. |
|
176 | self.proConfCmbBox.setObjectName(_fromUtf8("proConfCmbBox")) | |
180 | self.operationModeCmbBox.addItem(_fromUtf8("")) |
|
|||
181 | self.operationModeCmbBox.addItem(_fromUtf8("")) |
|
|||
182 | self.frame_8 = QtGui.QFrame(self.tab_5) |
|
177 | self.frame_8 = QtGui.QFrame(self.tab_5) | |
183 |
self.frame_8.setGeometry(QtCore.QRect(10, 1 |
|
178 | self.frame_8.setGeometry(QtCore.QRect(10, 170, 261, 71)) | |
184 | self.frame_8.setFrameShape(QtGui.QFrame.StyledPanel) |
|
179 | self.frame_8.setFrameShape(QtGui.QFrame.StyledPanel) | |
185 | self.frame_8.setFrameShadow(QtGui.QFrame.Plain) |
|
180 | self.frame_8.setFrameShadow(QtGui.QFrame.Plain) | |
186 | self.frame_8.setObjectName(_fromUtf8("frame_8")) |
|
181 | self.frame_8.setObjectName(_fromUtf8("frame_8")) | |
187 | self.dataYearLine = QtGui.QLabel(self.frame_8) |
|
|||
188 | self.dataYearLine.setGeometry(QtCore.QRect(10, 10, 41, 16)) |
|
|||
189 | font = QtGui.QFont() |
|
|||
190 | font.setPointSize(10) |
|
|||
191 | self.dataYearLine.setFont(font) |
|
|||
192 | self.dataYearLine.setObjectName(_fromUtf8("dataYearLine")) |
|
|||
193 | self.dataStartLine = QtGui.QLabel(self.frame_8) |
|
182 | self.dataStartLine = QtGui.QLabel(self.frame_8) | |
194 |
self.dataStartLine.setGeometry(QtCore.QRect( |
|
183 | self.dataStartLine.setGeometry(QtCore.QRect(10, 10, 69, 16)) | |
195 | font = QtGui.QFont() |
|
184 | font = QtGui.QFont() | |
196 | font.setPointSize(10) |
|
185 | font.setPointSize(10) | |
197 | self.dataStartLine.setFont(font) |
|
186 | self.dataStartLine.setFont(font) | |
198 | self.dataStartLine.setObjectName(_fromUtf8("dataStartLine")) |
|
187 | self.dataStartLine.setObjectName(_fromUtf8("dataStartLine")) | |
199 | self.dataEndline = QtGui.QLabel(self.frame_8) |
|
188 | self.dataEndline = QtGui.QLabel(self.frame_8) | |
200 |
self.dataEndline.setGeometry(QtCore.QRect(1 |
|
189 | self.dataEndline.setGeometry(QtCore.QRect(10, 30, 61, 16)) | |
201 | font = QtGui.QFont() |
|
190 | font = QtGui.QFont() | |
202 | font.setPointSize(10) |
|
191 | font.setPointSize(10) | |
203 | self.dataEndline.setFont(font) |
|
192 | self.dataEndline.setFont(font) | |
204 | self.dataEndline.setObjectName(_fromUtf8("dataEndline")) |
|
193 | self.dataEndline.setObjectName(_fromUtf8("dataEndline")) | |
205 | self.yearCmbBox = QtGui.QComboBox(self.frame_8) |
|
|||
206 | self.yearCmbBox.setGeometry(QtCore.QRect(10, 30, 61, 16)) |
|
|||
207 | font = QtGui.QFont() |
|
|||
208 | font.setPointSize(10) |
|
|||
209 | self.yearCmbBox.setFont(font) |
|
|||
210 | self.yearCmbBox.setObjectName(_fromUtf8("yearCmbBox")) |
|
|||
211 | self.starDateCmbBox = QtGui.QComboBox(self.frame_8) |
|
194 | self.starDateCmbBox = QtGui.QComboBox(self.frame_8) | |
212 |
self.starDateCmbBox.setGeometry(QtCore.QRect( |
|
195 | self.starDateCmbBox.setGeometry(QtCore.QRect(100, 10, 141, 16)) | |
213 | self.starDateCmbBox.setObjectName(_fromUtf8("starDateCmbBox")) |
|
196 | self.starDateCmbBox.setObjectName(_fromUtf8("starDateCmbBox")) | |
214 | self.endDateCmbBox = QtGui.QComboBox(self.frame_8) |
|
197 | self.endDateCmbBox = QtGui.QComboBox(self.frame_8) | |
215 |
self.endDateCmbBox.setGeometry(QtCore.QRect(1 |
|
198 | self.endDateCmbBox.setGeometry(QtCore.QRect(100, 30, 141, 16)) | |
216 | self.endDateCmbBox.setObjectName(_fromUtf8("endDateCmbBox")) |
|
199 | self.endDateCmbBox.setObjectName(_fromUtf8("endDateCmbBox")) | |
217 | self.LTReferenceRdBtn = QtGui.QRadioButton(self.frame_8) |
|
200 | self.LTReferenceRdBtn = QtGui.QRadioButton(self.frame_8) | |
218 |
self.LTReferenceRdBtn.setGeometry(QtCore.QRect( |
|
201 | self.LTReferenceRdBtn.setGeometry(QtCore.QRect(30, 50, 211, 21)) | |
219 | font = QtGui.QFont() |
|
202 | font = QtGui.QFont() | |
220 | font.setPointSize(8) |
|
203 | font.setPointSize(8) | |
221 | self.LTReferenceRdBtn.setFont(font) |
|
204 | self.LTReferenceRdBtn.setFont(font) | |
222 | self.LTReferenceRdBtn.setObjectName(_fromUtf8("LTReferenceRdBtn")) |
|
205 | self.LTReferenceRdBtn.setObjectName(_fromUtf8("LTReferenceRdBtn")) | |
223 | self.frame_10 = QtGui.QFrame(self.tab_5) |
|
206 | self.frame_10 = QtGui.QFrame(self.tab_5) | |
224 |
self.frame_10.setGeometry(QtCore.QRect(10, 2 |
|
207 | self.frame_10.setGeometry(QtCore.QRect(10, 250, 261, 71)) | |
225 | self.frame_10.setFrameShape(QtGui.QFrame.StyledPanel) |
|
208 | self.frame_10.setFrameShape(QtGui.QFrame.StyledPanel) | |
226 | self.frame_10.setFrameShadow(QtGui.QFrame.Plain) |
|
209 | self.frame_10.setFrameShadow(QtGui.QFrame.Plain) | |
227 | self.frame_10.setObjectName(_fromUtf8("frame_10")) |
|
210 | self.frame_10.setObjectName(_fromUtf8("frame_10")) | |
228 | self.initialTimeSlider = QtGui.QSlider(self.frame_10) |
|
|||
229 | self.initialTimeSlider.setGeometry(QtCore.QRect(70, 10, 141, 20)) |
|
|||
230 | self.initialTimeSlider.setMaximum(24) |
|
|||
231 | self.initialTimeSlider.setOrientation(QtCore.Qt.Horizontal) |
|
|||
232 | self.initialTimeSlider.setObjectName(_fromUtf8("initialTimeSlider")) |
|
|||
233 | self.dataInitialTimeLine = QtGui.QLabel(self.frame_10) |
|
211 | self.dataInitialTimeLine = QtGui.QLabel(self.frame_10) | |
234 |
self.dataInitialTimeLine.setGeometry(QtCore.QRect( |
|
212 | self.dataInitialTimeLine.setGeometry(QtCore.QRect(30, 10, 61, 16)) | |
235 | font = QtGui.QFont() |
|
213 | font = QtGui.QFont() | |
236 | font.setPointSize(9) |
|
214 | font.setPointSize(9) | |
237 | self.dataInitialTimeLine.setFont(font) |
|
215 | self.dataInitialTimeLine.setFont(font) | |
238 | self.dataInitialTimeLine.setObjectName(_fromUtf8("dataInitialTimeLine")) |
|
216 | self.dataInitialTimeLine.setObjectName(_fromUtf8("dataInitialTimeLine")) | |
239 | self.dataFinelTimeLine = QtGui.QLabel(self.frame_10) |
|
217 | self.dataFinelTimeLine = QtGui.QLabel(self.frame_10) | |
240 |
self.dataFinelTimeLine.setGeometry(QtCore.QRect( |
|
218 | self.dataFinelTimeLine.setGeometry(QtCore.QRect(30, 40, 61, 16)) | |
241 | font = QtGui.QFont() |
|
219 | font = QtGui.QFont() | |
242 | font.setPointSize(9) |
|
220 | font.setPointSize(9) | |
243 | self.dataFinelTimeLine.setFont(font) |
|
221 | self.dataFinelTimeLine.setFont(font) | |
244 | self.dataFinelTimeLine.setObjectName(_fromUtf8("dataFinelTimeLine")) |
|
222 | self.dataFinelTimeLine.setObjectName(_fromUtf8("dataFinelTimeLine")) | |
245 |
self. |
|
223 | self.startTimeEdit = QtGui.QTimeEdit(self.frame_10) | |
246 |
self. |
|
224 | self.startTimeEdit.setGeometry(QtCore.QRect(110, 10, 131, 20)) | |
247 | self.finalTimeSlider.setMaximum(24) |
|
225 | self.startTimeEdit.setObjectName(_fromUtf8("startTimeEdit")) | |
248 | self.finalTimeSlider.setOrientation(QtCore.Qt.Horizontal) |
|
226 | self.timeEdit_2 = QtGui.QTimeEdit(self.frame_10) | |
249 | self.finalTimeSlider.setObjectName(_fromUtf8("finalTimeSlider")) |
|
227 | self.timeEdit_2.setGeometry(QtCore.QRect(110, 40, 131, 21)) | |
250 | self.initialtimeLcd = QtGui.QLCDNumber(self.frame_10) |
|
228 | self.timeEdit_2.setObjectName(_fromUtf8("timeEdit_2")) | |
251 | self.initialtimeLcd.setGeometry(QtCore.QRect(210, 10, 41, 16)) |
|
|||
252 | palette = QtGui.QPalette() |
|
|||
253 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
254 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
255 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.WindowText, brush) |
|
|||
256 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
257 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
258 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Button, brush) |
|
|||
259 | brush = QtGui.QBrush(QtGui.QColor(161, 161, 161)) |
|
|||
260 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
261 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Light, brush) |
|
|||
262 | brush = QtGui.QBrush(QtGui.QColor(134, 134, 134)) |
|
|||
263 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
264 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Midlight, brush) |
|
|||
265 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
266 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
267 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Dark, brush) |
|
|||
268 | brush = QtGui.QBrush(QtGui.QColor(71, 71, 71)) |
|
|||
269 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
270 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Mid, brush) |
|
|||
271 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
272 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
273 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Text, brush) |
|
|||
274 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
275 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
276 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.BrightText, brush) |
|
|||
277 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
278 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
279 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.ButtonText, brush) |
|
|||
280 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
281 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
282 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Base, brush) |
|
|||
283 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
284 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
285 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Window, brush) |
|
|||
286 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
287 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
288 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Shadow, brush) |
|
|||
289 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
290 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
291 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.AlternateBase, brush) |
|
|||
292 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 220)) |
|
|||
293 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
294 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.ToolTipBase, brush) |
|
|||
295 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
296 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
297 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.ToolTipText, brush) |
|
|||
298 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
299 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
300 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.WindowText, brush) |
|
|||
301 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
302 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
303 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Button, brush) |
|
|||
304 | brush = QtGui.QBrush(QtGui.QColor(161, 161, 161)) |
|
|||
305 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
306 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Light, brush) |
|
|||
307 | brush = QtGui.QBrush(QtGui.QColor(134, 134, 134)) |
|
|||
308 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
309 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Midlight, brush) |
|
|||
310 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
311 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
312 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Dark, brush) |
|
|||
313 | brush = QtGui.QBrush(QtGui.QColor(71, 71, 71)) |
|
|||
314 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
315 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Mid, brush) |
|
|||
316 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
317 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
318 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Text, brush) |
|
|||
319 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
320 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
321 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.BrightText, brush) |
|
|||
322 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
323 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
324 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.ButtonText, brush) |
|
|||
325 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
326 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
327 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Base, brush) |
|
|||
328 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
329 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
330 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Window, brush) |
|
|||
331 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
332 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
333 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Shadow, brush) |
|
|||
334 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
335 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
336 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.AlternateBase, brush) |
|
|||
337 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 220)) |
|
|||
338 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
339 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.ToolTipBase, brush) |
|
|||
340 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
341 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
342 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.ToolTipText, brush) |
|
|||
343 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
344 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
345 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.WindowText, brush) |
|
|||
346 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
347 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
348 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Button, brush) |
|
|||
349 | brush = QtGui.QBrush(QtGui.QColor(161, 161, 161)) |
|
|||
350 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
351 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Light, brush) |
|
|||
352 | brush = QtGui.QBrush(QtGui.QColor(134, 134, 134)) |
|
|||
353 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
354 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Midlight, brush) |
|
|||
355 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
356 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
357 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Dark, brush) |
|
|||
358 | brush = QtGui.QBrush(QtGui.QColor(71, 71, 71)) |
|
|||
359 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
360 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Mid, brush) |
|
|||
361 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
362 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
363 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Text, brush) |
|
|||
364 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
365 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
366 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.BrightText, brush) |
|
|||
367 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
368 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
369 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.ButtonText, brush) |
|
|||
370 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
371 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
372 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Base, brush) |
|
|||
373 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
374 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
375 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Window, brush) |
|
|||
376 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
377 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
378 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Shadow, brush) |
|
|||
379 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
380 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
381 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.AlternateBase, brush) |
|
|||
382 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 220)) |
|
|||
383 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
384 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.ToolTipBase, brush) |
|
|||
385 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
386 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
387 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.ToolTipText, brush) |
|
|||
388 | self.initialtimeLcd.setPalette(palette) |
|
|||
389 | font = QtGui.QFont() |
|
|||
390 | font.setPointSize(14) |
|
|||
391 | font.setBold(True) |
|
|||
392 | font.setWeight(75) |
|
|||
393 | self.initialtimeLcd.setFont(font) |
|
|||
394 | self.initialtimeLcd.setObjectName(_fromUtf8("initialtimeLcd")) |
|
|||
395 | self.finaltimeLcd = QtGui.QLCDNumber(self.frame_10) |
|
|||
396 | self.finaltimeLcd.setGeometry(QtCore.QRect(210, 30, 41, 16)) |
|
|||
397 | palette = QtGui.QPalette() |
|
|||
398 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
399 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
400 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.WindowText, brush) |
|
|||
401 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
402 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
403 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Button, brush) |
|
|||
404 | brush = QtGui.QBrush(QtGui.QColor(161, 161, 161)) |
|
|||
405 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
406 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Light, brush) |
|
|||
407 | brush = QtGui.QBrush(QtGui.QColor(134, 134, 134)) |
|
|||
408 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
409 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Midlight, brush) |
|
|||
410 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
411 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
412 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Dark, brush) |
|
|||
413 | brush = QtGui.QBrush(QtGui.QColor(71, 71, 71)) |
|
|||
414 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
415 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Mid, brush) |
|
|||
416 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
417 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
418 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Text, brush) |
|
|||
419 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
420 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
421 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.BrightText, brush) |
|
|||
422 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
423 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
424 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.ButtonText, brush) |
|
|||
425 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
426 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
427 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Base, brush) |
|
|||
428 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
429 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
430 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Window, brush) |
|
|||
431 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
432 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
433 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.Shadow, brush) |
|
|||
434 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
435 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
436 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.AlternateBase, brush) |
|
|||
437 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 220)) |
|
|||
438 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
439 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.ToolTipBase, brush) |
|
|||
440 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
441 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
442 | palette.setBrush(QtGui.QPalette.Active, QtGui.QPalette.ToolTipText, brush) |
|
|||
443 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
444 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
445 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.WindowText, brush) |
|
|||
446 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
447 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
448 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Button, brush) |
|
|||
449 | brush = QtGui.QBrush(QtGui.QColor(161, 161, 161)) |
|
|||
450 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
451 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Light, brush) |
|
|||
452 | brush = QtGui.QBrush(QtGui.QColor(134, 134, 134)) |
|
|||
453 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
454 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Midlight, brush) |
|
|||
455 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
456 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
457 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Dark, brush) |
|
|||
458 | brush = QtGui.QBrush(QtGui.QColor(71, 71, 71)) |
|
|||
459 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
460 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Mid, brush) |
|
|||
461 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
462 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
463 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Text, brush) |
|
|||
464 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
465 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
466 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.BrightText, brush) |
|
|||
467 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
468 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
469 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.ButtonText, brush) |
|
|||
470 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
471 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
472 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Base, brush) |
|
|||
473 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
474 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
475 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Window, brush) |
|
|||
476 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
477 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
478 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.Shadow, brush) |
|
|||
479 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
480 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
481 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.AlternateBase, brush) |
|
|||
482 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 220)) |
|
|||
483 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
484 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.ToolTipBase, brush) |
|
|||
485 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
486 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
487 | palette.setBrush(QtGui.QPalette.Inactive, QtGui.QPalette.ToolTipText, brush) |
|
|||
488 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
489 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
490 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.WindowText, brush) |
|
|||
491 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
492 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
493 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Button, brush) |
|
|||
494 | brush = QtGui.QBrush(QtGui.QColor(161, 161, 161)) |
|
|||
495 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
496 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Light, brush) |
|
|||
497 | brush = QtGui.QBrush(QtGui.QColor(134, 134, 134)) |
|
|||
498 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
499 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Midlight, brush) |
|
|||
500 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
501 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
502 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Dark, brush) |
|
|||
503 | brush = QtGui.QBrush(QtGui.QColor(71, 71, 71)) |
|
|||
504 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
505 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Mid, brush) |
|
|||
506 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
507 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
508 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Text, brush) |
|
|||
509 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 255)) |
|
|||
510 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
511 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.BrightText, brush) |
|
|||
512 | brush = QtGui.QBrush(QtGui.QColor(53, 53, 53)) |
|
|||
513 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
514 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.ButtonText, brush) |
|
|||
515 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
516 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
517 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Base, brush) |
|
|||
518 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
519 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
520 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Window, brush) |
|
|||
521 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
522 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
523 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.Shadow, brush) |
|
|||
524 | brush = QtGui.QBrush(QtGui.QColor(107, 107, 107)) |
|
|||
525 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
526 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.AlternateBase, brush) |
|
|||
527 | brush = QtGui.QBrush(QtGui.QColor(255, 255, 220)) |
|
|||
528 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
529 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.ToolTipBase, brush) |
|
|||
530 | brush = QtGui.QBrush(QtGui.QColor(0, 0, 0)) |
|
|||
531 | brush.setStyle(QtCore.Qt.SolidPattern) |
|
|||
532 | palette.setBrush(QtGui.QPalette.Disabled, QtGui.QPalette.ToolTipText, brush) |
|
|||
533 | self.finaltimeLcd.setPalette(palette) |
|
|||
534 | self.finaltimeLcd.setObjectName(_fromUtf8("finaltimeLcd")) |
|
|||
535 | self.dataOkBtn = QtGui.QPushButton(self.tab_5) |
|
229 | self.dataOkBtn = QtGui.QPushButton(self.tab_5) | |
536 |
self.dataOkBtn.setGeometry(QtCore.QRect(80, 3 |
|
230 | self.dataOkBtn.setGeometry(QtCore.QRect(80, 320, 61, 21)) | |
537 | self.dataOkBtn.setObjectName(_fromUtf8("dataOkBtn")) |
|
231 | self.dataOkBtn.setObjectName(_fromUtf8("dataOkBtn")) | |
538 | self.dataCancelBtn = QtGui.QPushButton(self.tab_5) |
|
232 | self.dataCancelBtn = QtGui.QPushButton(self.tab_5) | |
539 |
self.dataCancelBtn.setGeometry(QtCore.QRect(1 |
|
233 | self.dataCancelBtn.setGeometry(QtCore.QRect(150, 320, 61, 21)) | |
540 | self.dataCancelBtn.setObjectName(_fromUtf8("dataCancelBtn")) |
|
234 | self.dataCancelBtn.setObjectName(_fromUtf8("dataCancelBtn")) | |
541 | self.tabWidget.addTab(self.tab_5, _fromUtf8("")) |
|
235 | self.tabWidget.addTab(self.tab_5, _fromUtf8("")) | |
542 | self.tab_7 = QtGui.QWidget() |
|
236 | self.tab_7 = QtGui.QWidget() | |
543 | self.tab_7.setObjectName(_fromUtf8("tab_7")) |
|
237 | self.tab_7.setObjectName(_fromUtf8("tab_7")) | |
544 | self.gridLayout_10 = QtGui.QGridLayout(self.tab_7) |
|
|||
545 | self.gridLayout_10.setObjectName(_fromUtf8("gridLayout_10")) |
|
|||
546 | self.tabWidget_3 = QtGui.QTabWidget(self.tab_7) |
|
238 | self.tabWidget_3 = QtGui.QTabWidget(self.tab_7) | |
|
239 | self.tabWidget_3.setGeometry(QtCore.QRect(10, 20, 261, 301)) | |||
547 | self.tabWidget_3.setObjectName(_fromUtf8("tabWidget_3")) |
|
240 | self.tabWidget_3.setObjectName(_fromUtf8("tabWidget_3")) | |
548 | self.tab_3 = QtGui.QWidget() |
|
241 | self.tab_3 = QtGui.QWidget() | |
549 | self.tab_3.setObjectName(_fromUtf8("tab_3")) |
|
242 | self.tab_3.setObjectName(_fromUtf8("tab_3")) | |
550 | self.frame_13 = QtGui.QFrame(self.tab_3) |
|
243 | self.frame_13 = QtGui.QFrame(self.tab_3) | |
551 |
self.frame_13.setGeometry(QtCore.QRect(10, |
|
244 | self.frame_13.setGeometry(QtCore.QRect(10, 10, 231, 201)) | |
552 | self.frame_13.setFrameShape(QtGui.QFrame.StyledPanel) |
|
245 | self.frame_13.setFrameShape(QtGui.QFrame.StyledPanel) | |
553 | self.frame_13.setFrameShadow(QtGui.QFrame.Plain) |
|
246 | self.frame_13.setFrameShadow(QtGui.QFrame.Plain) | |
554 | self.frame_13.setObjectName(_fromUtf8("frame_13")) |
|
247 | self.frame_13.setObjectName(_fromUtf8("frame_13")) | |
555 | self.removeDCCEB = QtGui.QCheckBox(self.frame_13) |
|
248 | self.removeDCCEB = QtGui.QCheckBox(self.frame_13) | |
556 |
self.removeDCCEB.setGeometry(QtCore.QRect(10, |
|
249 | self.removeDCCEB.setGeometry(QtCore.QRect(10, 100, 91, 17)) | |
557 | font = QtGui.QFont() |
|
250 | font = QtGui.QFont() | |
558 | font.setPointSize(10) |
|
251 | font.setPointSize(10) | |
559 | self.removeDCCEB.setFont(font) |
|
252 | self.removeDCCEB.setFont(font) | |
560 | self.removeDCCEB.setObjectName(_fromUtf8("removeDCCEB")) |
|
253 | self.removeDCCEB.setObjectName(_fromUtf8("removeDCCEB")) | |
561 | self.coherentIntegrationCEB = QtGui.QCheckBox(self.frame_13) |
|
254 | self.coherentIntegrationCEB = QtGui.QCheckBox(self.frame_13) | |
562 |
self.coherentIntegrationCEB.setGeometry(QtCore.QRect(10, 1 |
|
255 | self.coherentIntegrationCEB.setGeometry(QtCore.QRect(10, 170, 141, 17)) | |
563 | font = QtGui.QFont() |
|
256 | font = QtGui.QFont() | |
564 | font.setPointSize(10) |
|
257 | font.setPointSize(10) | |
565 | self.coherentIntegrationCEB.setFont(font) |
|
258 | self.coherentIntegrationCEB.setFont(font) | |
566 | self.coherentIntegrationCEB.setObjectName(_fromUtf8("coherentIntegrationCEB")) |
|
259 | self.coherentIntegrationCEB.setObjectName(_fromUtf8("coherentIntegrationCEB")) | |
567 | self.removeDCcob = QtGui.QComboBox(self.frame_13) |
|
260 | self.removeDCcob = QtGui.QComboBox(self.frame_13) | |
568 |
self.removeDCcob.setGeometry(QtCore.QRect(1 |
|
261 | self.removeDCcob.setGeometry(QtCore.QRect(130, 100, 91, 20)) | |
569 | self.removeDCcob.setObjectName(_fromUtf8("removeDCcob")) |
|
262 | self.removeDCcob.setObjectName(_fromUtf8("removeDCcob")) | |
570 | self.numberIntegration = QtGui.QLineEdit(self.frame_13) |
|
263 | self.numberIntegration = QtGui.QLineEdit(self.frame_13) | |
571 |
self.numberIntegration.setGeometry(QtCore.QRect(150, 1 |
|
264 | self.numberIntegration.setGeometry(QtCore.QRect(150, 170, 71, 21)) | |
572 | self.numberIntegration.setObjectName(_fromUtf8("numberIntegration")) |
|
265 | self.numberIntegration.setObjectName(_fromUtf8("numberIntegration")) | |
573 | self.decodeCEB = QtGui.QCheckBox(self.frame_13) |
|
266 | self.decodeCEB = QtGui.QCheckBox(self.frame_13) | |
574 |
self.decodeCEB.setGeometry(QtCore.QRect(10, |
|
267 | self.decodeCEB.setGeometry(QtCore.QRect(10, 130, 101, 21)) | |
575 | font = QtGui.QFont() |
|
268 | font = QtGui.QFont() | |
576 | font.setPointSize(10) |
|
269 | font.setPointSize(10) | |
577 | self.decodeCEB.setFont(font) |
|
270 | self.decodeCEB.setFont(font) | |
578 | self.decodeCEB.setObjectName(_fromUtf8("decodeCEB")) |
|
271 | self.decodeCEB.setObjectName(_fromUtf8("decodeCEB")) | |
579 | self.decodeCcob = QtGui.QComboBox(self.frame_13) |
|
272 | self.decodeCcob = QtGui.QComboBox(self.frame_13) | |
580 |
self.decodeCcob.setGeometry(QtCore.QRect(1 |
|
273 | self.decodeCcob.setGeometry(QtCore.QRect(130, 130, 91, 20)) | |
581 | self.decodeCcob.setObjectName(_fromUtf8("decodeCcob")) |
|
274 | self.decodeCcob.setObjectName(_fromUtf8("decodeCcob")) | |
|
275 | self.profileOpVolcob = QtGui.QComboBox(self.frame_13) | |||
|
276 | self.profileOpVolcob.setGeometry(QtCore.QRect(130, 40, 91, 22)) | |||
|
277 | font = QtGui.QFont() | |||
|
278 | font.setPointSize(8) | |||
|
279 | self.profileOpVolcob.setFont(font) | |||
|
280 | self.profileOpVolcob.setObjectName(_fromUtf8("profileOpVolcob")) | |||
|
281 | self.profileOpVolcob.addItem(_fromUtf8("")) | |||
|
282 | self.profileOpVolcob.addItem(_fromUtf8("")) | |||
|
283 | self.selecChannelopVolCEB = QtGui.QCheckBox(self.frame_13) | |||
|
284 | self.selecChannelopVolCEB.setGeometry(QtCore.QRect(10, 10, 121, 21)) | |||
|
285 | self.selecChannelopVolCEB.setObjectName(_fromUtf8("selecChannelopVolCEB")) | |||
|
286 | self.selecHeighopVolCEB = QtGui.QCheckBox(self.frame_13) | |||
|
287 | self.selecHeighopVolCEB.setGeometry(QtCore.QRect(10, 40, 121, 21)) | |||
|
288 | self.selecHeighopVolCEB.setObjectName(_fromUtf8("selecHeighopVolCEB")) | |||
|
289 | self.numberChannelopVol = QtGui.QLineEdit(self.frame_13) | |||
|
290 | self.numberChannelopVol.setEnabled(True) | |||
|
291 | self.numberChannelopVol.setGeometry(QtCore.QRect(130, 10, 91, 20)) | |||
|
292 | self.numberChannelopVol.setObjectName(_fromUtf8("numberChannelopVol")) | |||
|
293 | self.lineHeighProfileTxtopVol = QtGui.QLineEdit(self.frame_13) | |||
|
294 | self.lineHeighProfileTxtopVol.setGeometry(QtCore.QRect(10, 70, 211, 20)) | |||
|
295 | self.lineHeighProfileTxtopVol.setObjectName(_fromUtf8("lineHeighProfileTxtopVol")) | |||
582 | self.frame_14 = QtGui.QFrame(self.tab_3) |
|
296 | self.frame_14 = QtGui.QFrame(self.tab_3) | |
583 |
self.frame_14.setGeometry(QtCore.QRect(10, 2 |
|
297 | self.frame_14.setGeometry(QtCore.QRect(10, 220, 231, 41)) | |
584 | self.frame_14.setFrameShape(QtGui.QFrame.StyledPanel) |
|
298 | self.frame_14.setFrameShape(QtGui.QFrame.StyledPanel) | |
585 | self.frame_14.setFrameShadow(QtGui.QFrame.Plain) |
|
299 | self.frame_14.setFrameShadow(QtGui.QFrame.Plain) | |
586 | self.frame_14.setObjectName(_fromUtf8("frame_14")) |
|
300 | self.frame_14.setObjectName(_fromUtf8("frame_14")) | |
@@ -701,12 +415,12 class Ui_MainWindow(object): | |||||
701 | self.comboBox_10 = QtGui.QComboBox(self.frame_19) |
|
415 | self.comboBox_10 = QtGui.QComboBox(self.frame_19) | |
702 | self.comboBox_10.setGeometry(QtCore.QRect(90, 10, 131, 16)) |
|
416 | self.comboBox_10.setGeometry(QtCore.QRect(90, 10, 131, 16)) | |
703 | self.comboBox_10.setObjectName(_fromUtf8("comboBox_10")) |
|
417 | self.comboBox_10.setObjectName(_fromUtf8("comboBox_10")) | |
704 |
self.dataOkBtn |
|
418 | self.dataGraphVolOkBtn = QtGui.QPushButton(self.tab_2) | |
705 |
self.dataOkBtn |
|
419 | self.dataGraphVolOkBtn.setGeometry(QtCore.QRect(60, 250, 71, 21)) | |
706 |
self.dataOkBtn |
|
420 | self.dataGraphVolOkBtn.setObjectName(_fromUtf8("dataGraphVolOkBtn")) | |
707 |
self.dataCancelBtn |
|
421 | self.dataGraphVolCancelBtn = QtGui.QPushButton(self.tab_2) | |
708 |
self.dataCancelBtn |
|
422 | self.dataGraphVolCancelBtn.setGeometry(QtCore.QRect(140, 250, 71, 21)) | |
709 |
self.dataCancelBtn |
|
423 | self.dataGraphVolCancelBtn.setObjectName(_fromUtf8("dataGraphVolCancelBtn")) | |
710 | self.tabWidget_3.addTab(self.tab_2, _fromUtf8("")) |
|
424 | self.tabWidget_3.addTab(self.tab_2, _fromUtf8("")) | |
711 | self.tab_4 = QtGui.QWidget() |
|
425 | self.tab_4 = QtGui.QWidget() | |
712 | self.tab_4.setObjectName(_fromUtf8("tab_4")) |
|
426 | self.tab_4.setObjectName(_fromUtf8("tab_4")) | |
@@ -735,20 +449,21 class Ui_MainWindow(object): | |||||
735 | self.frame_48.setFrameShape(QtGui.QFrame.StyledPanel) |
|
449 | self.frame_48.setFrameShape(QtGui.QFrame.StyledPanel) | |
736 | self.frame_48.setFrameShadow(QtGui.QFrame.Plain) |
|
450 | self.frame_48.setFrameShadow(QtGui.QFrame.Plain) | |
737 | self.frame_48.setObjectName(_fromUtf8("frame_48")) |
|
451 | self.frame_48.setObjectName(_fromUtf8("frame_48")) | |
738 |
self.data |
|
452 | self.datasaveVolOkBtn = QtGui.QPushButton(self.frame_48) | |
739 |
self.data |
|
453 | self.datasaveVolOkBtn.setGeometry(QtCore.QRect(30, 10, 71, 21)) | |
740 |
self.data |
|
454 | self.datasaveVolOkBtn.setObjectName(_fromUtf8("datasaveVolOkBtn")) | |
741 |
self.dataCancelBtn |
|
455 | self.datasaveVolCancelBtn = QtGui.QPushButton(self.frame_48) | |
742 |
self.dataCancelBtn |
|
456 | self.datasaveVolCancelBtn.setGeometry(QtCore.QRect(130, 10, 71, 21)) | |
743 |
self.dataCancelBtn |
|
457 | self.datasaveVolCancelBtn.setObjectName(_fromUtf8("datasaveVolCancelBtn")) | |
744 | self.tabWidget_3.addTab(self.tab_4, _fromUtf8("")) |
|
458 | self.tabWidget_3.addTab(self.tab_4, _fromUtf8("")) | |
745 | self.gridLayout_10.addWidget(self.tabWidget_3, 0, 0, 1, 1) |
|
459 | self.addOpUpselec = QtGui.QComboBox(self.tab_7) | |
|
460 | self.addOpUpselec.setGeometry(QtCore.QRect(10, 0, 91, 21)) | |||
|
461 | self.addOpUpselec.setObjectName(_fromUtf8("addOpUpselec")) | |||
746 | self.tabWidget.addTab(self.tab_7, _fromUtf8("")) |
|
462 | self.tabWidget.addTab(self.tab_7, _fromUtf8("")) | |
747 | self.tab_6 = QtGui.QWidget() |
|
463 | self.tab_6 = QtGui.QWidget() | |
748 | self.tab_6.setObjectName(_fromUtf8("tab_6")) |
|
464 | self.tab_6.setObjectName(_fromUtf8("tab_6")) | |
749 | self.gridLayout_11 = QtGui.QGridLayout(self.tab_6) |
|
|||
750 | self.gridLayout_11.setObjectName(_fromUtf8("gridLayout_11")) |
|
|||
751 | self.tabWidget_4 = QtGui.QTabWidget(self.tab_6) |
|
465 | self.tabWidget_4 = QtGui.QTabWidget(self.tab_6) | |
|
466 | self.tabWidget_4.setGeometry(QtCore.QRect(9, 9, 261, 321)) | |||
752 | self.tabWidget_4.setObjectName(_fromUtf8("tabWidget_4")) |
|
467 | self.tabWidget_4.setObjectName(_fromUtf8("tabWidget_4")) | |
753 | self.tab_8 = QtGui.QWidget() |
|
468 | self.tab_8 = QtGui.QWidget() | |
754 | self.tab_8.setObjectName(_fromUtf8("tab_8")) |
|
469 | self.tab_8.setObjectName(_fromUtf8("tab_8")) | |
@@ -798,18 +513,18 class Ui_MainWindow(object): | |||||
798 | self.frame_35.setFrameShape(QtGui.QFrame.StyledPanel) |
|
513 | self.frame_35.setFrameShape(QtGui.QFrame.StyledPanel) | |
799 | self.frame_35.setFrameShadow(QtGui.QFrame.Plain) |
|
514 | self.frame_35.setFrameShadow(QtGui.QFrame.Plain) | |
800 | self.frame_35.setObjectName(_fromUtf8("frame_35")) |
|
515 | self.frame_35.setObjectName(_fromUtf8("frame_35")) | |
801 |
self.dataOkBtn |
|
516 | self.dataopSpecOkBtn = QtGui.QPushButton(self.frame_35) | |
802 |
self.dataOkBtn |
|
517 | self.dataopSpecOkBtn.setGeometry(QtCore.QRect(30, 10, 71, 21)) | |
803 |
self.dataOkBtn |
|
518 | self.dataopSpecOkBtn.setObjectName(_fromUtf8("dataopSpecOkBtn")) | |
804 |
self.dataCancelBtn |
|
519 | self.dataopSpecCancelBtn = QtGui.QPushButton(self.frame_35) | |
805 |
self.dataCancelBtn |
|
520 | self.dataopSpecCancelBtn.setGeometry(QtCore.QRect(130, 10, 71, 21)) | |
806 |
self.dataCancelBtn |
|
521 | self.dataopSpecCancelBtn.setObjectName(_fromUtf8("dataopSpecCancelBtn")) | |
807 | self.tabWidget_4.addTab(self.tab_8, _fromUtf8("")) |
|
522 | self.tabWidget_4.addTab(self.tab_8, _fromUtf8("")) | |
808 | self.tab_10 = QtGui.QWidget() |
|
523 | self.tab_10 = QtGui.QWidget() | |
809 | self.tab_10.setObjectName(_fromUtf8("tab_10")) |
|
524 | self.tab_10.setObjectName(_fromUtf8("tab_10")) | |
810 |
self.dataCancelBtn |
|
525 | self.dataGraphSpecCancelBtn = QtGui.QPushButton(self.tab_10) | |
811 |
self.dataCancelBtn |
|
526 | self.dataGraphSpecCancelBtn.setGeometry(QtCore.QRect(140, 270, 71, 21)) | |
812 |
self.dataCancelBtn |
|
527 | self.dataGraphSpecCancelBtn.setObjectName(_fromUtf8("dataGraphSpecCancelBtn")) | |
813 | self.frame_39 = QtGui.QFrame(self.tab_10) |
|
528 | self.frame_39 = QtGui.QFrame(self.tab_10) | |
814 | self.frame_39.setGeometry(QtCore.QRect(10, 90, 231, 21)) |
|
529 | self.frame_39.setGeometry(QtCore.QRect(10, 90, 231, 21)) | |
815 | self.frame_39.setFrameShape(QtGui.QFrame.StyledPanel) |
|
530 | self.frame_39.setFrameShape(QtGui.QFrame.StyledPanel) | |
@@ -896,9 +611,9 class Ui_MainWindow(object): | |||||
896 | self.checkBox_74.setGeometry(QtCore.QRect(190, 80, 20, 26)) |
|
611 | self.checkBox_74.setGeometry(QtCore.QRect(190, 80, 20, 26)) | |
897 | self.checkBox_74.setText(_fromUtf8("")) |
|
612 | self.checkBox_74.setText(_fromUtf8("")) | |
898 | self.checkBox_74.setObjectName(_fromUtf8("checkBox_74")) |
|
613 | self.checkBox_74.setObjectName(_fromUtf8("checkBox_74")) | |
899 |
self.dataOkBtn |
|
614 | self.dataGraphSpecOkBtn = QtGui.QPushButton(self.tab_10) | |
900 |
self.dataOkBtn |
|
615 | self.dataGraphSpecOkBtn.setGeometry(QtCore.QRect(60, 270, 71, 21)) | |
901 |
self.dataOkBtn |
|
616 | self.dataGraphSpecOkBtn.setObjectName(_fromUtf8("dataGraphSpecOkBtn")) | |
902 | self.frame_38 = QtGui.QFrame(self.tab_10) |
|
617 | self.frame_38 = QtGui.QFrame(self.tab_10) | |
903 | self.frame_38.setGeometry(QtCore.QRect(10, 10, 231, 71)) |
|
618 | self.frame_38.setGeometry(QtCore.QRect(10, 10, 231, 71)) | |
904 | self.frame_38.setFrameShape(QtGui.QFrame.StyledPanel) |
|
619 | self.frame_38.setFrameShape(QtGui.QFrame.StyledPanel) | |
@@ -982,14 +697,13 class Ui_MainWindow(object): | |||||
982 | self.frame_49.setFrameShape(QtGui.QFrame.StyledPanel) |
|
697 | self.frame_49.setFrameShape(QtGui.QFrame.StyledPanel) | |
983 | self.frame_49.setFrameShadow(QtGui.QFrame.Plain) |
|
698 | self.frame_49.setFrameShadow(QtGui.QFrame.Plain) | |
984 | self.frame_49.setObjectName(_fromUtf8("frame_49")) |
|
699 | self.frame_49.setObjectName(_fromUtf8("frame_49")) | |
985 |
self.dataOkBtn |
|
700 | self.datasaveSpecOkBtn = QtGui.QPushButton(self.frame_49) | |
986 |
self.dataOkBtn |
|
701 | self.datasaveSpecOkBtn.setGeometry(QtCore.QRect(30, 10, 71, 21)) | |
987 |
self.dataOkBtn |
|
702 | self.datasaveSpecOkBtn.setObjectName(_fromUtf8("datasaveSpecOkBtn")) | |
988 |
self.dataCancelBtn |
|
703 | self.datasaveSpecCancelBtn = QtGui.QPushButton(self.frame_49) | |
989 |
self.dataCancelBtn |
|
704 | self.datasaveSpecCancelBtn.setGeometry(QtCore.QRect(130, 10, 71, 21)) | |
990 |
self.dataCancelBtn |
|
705 | self.datasaveSpecCancelBtn.setObjectName(_fromUtf8("datasaveSpecCancelBtn")) | |
991 | self.tabWidget_4.addTab(self.tab_11, _fromUtf8("")) |
|
706 | self.tabWidget_4.addTab(self.tab_11, _fromUtf8("")) | |
992 | self.gridLayout_11.addWidget(self.tabWidget_4, 0, 0, 1, 1) |
|
|||
993 | self.tabWidget.addTab(self.tab_6, _fromUtf8("")) |
|
707 | self.tabWidget.addTab(self.tab_6, _fromUtf8("")) | |
994 | self.tab_9 = QtGui.QWidget() |
|
708 | self.tab_9 = QtGui.QWidget() | |
995 | self.tab_9.setObjectName(_fromUtf8("tab_9")) |
|
709 | self.tab_9.setObjectName(_fromUtf8("tab_9")) | |
@@ -1018,12 +732,12 class Ui_MainWindow(object): | |||||
1018 | self.frame_36.setFrameShape(QtGui.QFrame.StyledPanel) |
|
732 | self.frame_36.setFrameShape(QtGui.QFrame.StyledPanel) | |
1019 | self.frame_36.setFrameShadow(QtGui.QFrame.Plain) |
|
733 | self.frame_36.setFrameShadow(QtGui.QFrame.Plain) | |
1020 | self.frame_36.setObjectName(_fromUtf8("frame_36")) |
|
734 | self.frame_36.setObjectName(_fromUtf8("frame_36")) | |
1021 |
self.dataOkBtn |
|
735 | self.dataopCorrOkBtn = QtGui.QPushButton(self.frame_36) | |
1022 |
self.dataOkBtn |
|
736 | self.dataopCorrOkBtn.setGeometry(QtCore.QRect(30, 10, 71, 21)) | |
1023 |
self.dataOkBtn |
|
737 | self.dataopCorrOkBtn.setObjectName(_fromUtf8("dataopCorrOkBtn")) | |
1024 |
self.dataCancelBtn |
|
738 | self.dataopCorrCancelBtn = QtGui.QPushButton(self.frame_36) | |
1025 |
self.dataCancelBtn |
|
739 | self.dataopCorrCancelBtn.setGeometry(QtCore.QRect(130, 10, 71, 21)) | |
1026 |
self.dataCancelBtn |
|
740 | self.dataopCorrCancelBtn.setObjectName(_fromUtf8("dataopCorrCancelBtn")) | |
1027 | self.tabWidget_5.addTab(self.tab_12, _fromUtf8("")) |
|
741 | self.tabWidget_5.addTab(self.tab_12, _fromUtf8("")) | |
1028 | self.tab_13 = QtGui.QWidget() |
|
742 | self.tab_13 = QtGui.QWidget() | |
1029 | self.tab_13.setObjectName(_fromUtf8("tab_13")) |
|
743 | self.tab_13.setObjectName(_fromUtf8("tab_13")) | |
@@ -1121,12 +835,12 class Ui_MainWindow(object): | |||||
1121 | self.checkBox_68.setGeometry(QtCore.QRect(190, 30, 31, 26)) |
|
835 | self.checkBox_68.setGeometry(QtCore.QRect(190, 30, 31, 26)) | |
1122 | self.checkBox_68.setText(_fromUtf8("")) |
|
836 | self.checkBox_68.setText(_fromUtf8("")) | |
1123 | self.checkBox_68.setObjectName(_fromUtf8("checkBox_68")) |
|
837 | self.checkBox_68.setObjectName(_fromUtf8("checkBox_68")) | |
1124 |
self.dataOkBtn |
|
838 | self.dataGraphCorrOkBtn = QtGui.QPushButton(self.tab_13) | |
1125 |
self.dataOkBtn |
|
839 | self.dataGraphCorrOkBtn.setGeometry(QtCore.QRect(60, 270, 71, 21)) | |
1126 |
self.dataOkBtn |
|
840 | self.dataGraphCorrOkBtn.setObjectName(_fromUtf8("dataGraphCorrOkBtn")) | |
1127 |
self.dataCancelBtn |
|
841 | self.dataGraphCorrCancelBtn = QtGui.QPushButton(self.tab_13) | |
1128 |
self.dataCancelBtn |
|
842 | self.dataGraphCorrCancelBtn.setGeometry(QtCore.QRect(140, 270, 71, 21)) | |
1129 |
self.dataCancelBtn |
|
843 | self.dataGraphCorrCancelBtn.setObjectName(_fromUtf8("dataGraphCorrCancelBtn")) | |
1130 | self.tabWidget_5.addTab(self.tab_13, _fromUtf8("")) |
|
844 | self.tabWidget_5.addTab(self.tab_13, _fromUtf8("")) | |
1131 | self.tab_14 = QtGui.QWidget() |
|
845 | self.tab_14 = QtGui.QWidget() | |
1132 | self.tab_14.setObjectName(_fromUtf8("tab_14")) |
|
846 | self.tab_14.setObjectName(_fromUtf8("tab_14")) | |
@@ -1158,12 +872,12 class Ui_MainWindow(object): | |||||
1158 | self.frame_50.setFrameShape(QtGui.QFrame.StyledPanel) |
|
872 | self.frame_50.setFrameShape(QtGui.QFrame.StyledPanel) | |
1159 | self.frame_50.setFrameShadow(QtGui.QFrame.Plain) |
|
873 | self.frame_50.setFrameShadow(QtGui.QFrame.Plain) | |
1160 | self.frame_50.setObjectName(_fromUtf8("frame_50")) |
|
874 | self.frame_50.setObjectName(_fromUtf8("frame_50")) | |
1161 |
self.dataOkBtn |
|
875 | self.datasaveCorrOkBtn = QtGui.QPushButton(self.frame_50) | |
1162 |
self.dataOkBtn |
|
876 | self.datasaveCorrOkBtn.setGeometry(QtCore.QRect(30, 10, 71, 21)) | |
1163 |
self.dataOkBtn |
|
877 | self.datasaveCorrOkBtn.setObjectName(_fromUtf8("datasaveCorrOkBtn")) | |
1164 |
self.dataCancelBtn |
|
878 | self.dataSaveCorrCancelBtn = QtGui.QPushButton(self.frame_50) | |
1165 |
self.dataCancelBtn |
|
879 | self.dataSaveCorrCancelBtn.setGeometry(QtCore.QRect(130, 10, 71, 21)) | |
1166 |
self.dataCancelBtn |
|
880 | self.dataSaveCorrCancelBtn.setObjectName(_fromUtf8("dataSaveCorrCancelBtn")) | |
1167 | self.tabWidget_5.addTab(self.tab_14, _fromUtf8("")) |
|
881 | self.tabWidget_5.addTab(self.tab_14, _fromUtf8("")) | |
1168 | self.gridLayout_12.addWidget(self.tabWidget_5, 0, 0, 1, 1) |
|
882 | self.gridLayout_12.addWidget(self.tabWidget_5, 0, 0, 1, 1) | |
1169 | self.tabWidget.addTab(self.tab_9, _fromUtf8("")) |
|
883 | self.tabWidget.addTab(self.tab_9, _fromUtf8("")) | |
@@ -1178,14 +892,14 class Ui_MainWindow(object): | |||||
1178 | self.tab = QtGui.QWidget() |
|
892 | self.tab = QtGui.QWidget() | |
1179 | self.tab.setObjectName(_fromUtf8("tab")) |
|
893 | self.tab.setObjectName(_fromUtf8("tab")) | |
1180 | self.textEdit = Qsci.QsciScintilla(self.tab) |
|
894 | self.textEdit = Qsci.QsciScintilla(self.tab) | |
1181 |
self.textEdit.setGeometry(QtCore.QRect(10, 0, 261, |
|
895 | self.textEdit.setGeometry(QtCore.QRect(10, 10, 261, 61)) | |
1182 | self.textEdit.setToolTip(_fromUtf8("")) |
|
896 | self.textEdit.setToolTip(_fromUtf8("")) | |
1183 | self.textEdit.setWhatsThis(_fromUtf8("")) |
|
897 | self.textEdit.setWhatsThis(_fromUtf8("")) | |
1184 | self.textEdit.setObjectName(_fromUtf8("textEdit")) |
|
898 | self.textEdit.setObjectName(_fromUtf8("textEdit")) | |
1185 | self.tabWidget_2.addTab(self.tab, _fromUtf8("")) |
|
899 | self.tabWidget_2.addTab(self.tab, _fromUtf8("")) | |
1186 | MainWindow.setCentralWidget(self.centralWidget) |
|
900 | MainWindow.setCentralWidget(self.centralWidget) | |
1187 | self.menuBar = QtGui.QMenuBar(MainWindow) |
|
901 | self.menuBar = QtGui.QMenuBar(MainWindow) | |
1188 |
self.menuBar.setGeometry(QtCore.QRect(0, 0, 85 |
|
902 | self.menuBar.setGeometry(QtCore.QRect(0, 0, 854, 21)) | |
1189 | self.menuBar.setObjectName(_fromUtf8("menuBar")) |
|
903 | self.menuBar.setObjectName(_fromUtf8("menuBar")) | |
1190 | self.menuFILE = QtGui.QMenu(self.menuBar) |
|
904 | self.menuFILE = QtGui.QMenu(self.menuBar) | |
1191 | self.menuFILE.setObjectName(_fromUtf8("menuFILE")) |
|
905 | self.menuFILE.setObjectName(_fromUtf8("menuFILE")) | |
@@ -1284,27 +998,35 class Ui_MainWindow(object): | |||||
1284 | self.tabWidget_5.setCurrentIndex(0) |
|
998 | self.tabWidget_5.setCurrentIndex(0) | |
1285 | self.tabWidget_2.setCurrentIndex(0) |
|
999 | self.tabWidget_2.setCurrentIndex(0) | |
1286 | QtCore.QMetaObject.connectSlotsByName(MainWindow) |
|
1000 | QtCore.QMetaObject.connectSlotsByName(MainWindow) | |
|
1001 | ||||
|
1002 | #++++++++++++++++++NEW PROPERTIES+++++++++++++++++# | |||
|
1003 | QtGui.QToolTip.setFont(QtGui.QFont('SansSerif', 10)) | |||
|
1004 | self.addpBtn.setToolTip('Add_New_Project') | |||
|
1005 | self.addUnitProces.setToolTip('Add_New_Unit_Process') | |||
|
1006 | ||||
|
1007 | #++++++++++++++++++NEW PROPERTIES+++++++++++++++++# | |||
|
1008 | self.model = QtGui.QStandardItemModel() | |||
|
1009 | self.treeView.setModel(self.model) | |||
|
1010 | self.treeView.clicked.connect(self.clickFunctiontree) | |||
|
1011 | self.treeView.expandAll() | |||
|
1012 | #self.treeView.clicked.connect(self.treefunction1) | |||
1287 |
|
1013 | |||
1288 | def retranslateUi(self, MainWindow): |
|
1014 | def retranslateUi(self, MainWindow): | |
1289 | MainWindow.setWindowTitle(QtGui.QApplication.translate("MainWindow", "MainWindow", None, QtGui.QApplication.UnicodeUTF8)) |
|
1015 | MainWindow.setWindowTitle(QtGui.QApplication.translate("MainWindow", "MainWindow", None, QtGui.QApplication.UnicodeUTF8)) | |
1290 | self.label_46.setText(QtGui.QApplication.translate("MainWindow", "Project Properties", None, QtGui.QApplication.UnicodeUTF8)) |
|
1016 | self.label_46.setText(QtGui.QApplication.translate("MainWindow", "Project Properties", None, QtGui.QApplication.UnicodeUTF8)) | |
1291 | self.label.setText(QtGui.QApplication.translate("MainWindow", "Project Explorer", None, QtGui.QApplication.UnicodeUTF8)) |
|
1017 | self.label.setText(QtGui.QApplication.translate("MainWindow", "Project Explorer", None, QtGui.QApplication.UnicodeUTF8)) | |
1292 |
self.addpBtn.setText(QtGui.QApplication.translate("MainWindow", "P |
|
1018 | self.addpBtn.setText(QtGui.QApplication.translate("MainWindow", "PROJECT", None, QtGui.QApplication.UnicodeUTF8)) | |
1293 |
self.add |
|
1019 | self.addUnitProces.setText(QtGui.QApplication.translate("MainWindow", "UNIT PROCESS", None, QtGui.QApplication.UnicodeUTF8)) | |
1294 | self.addoBtn.setText(QtGui.QApplication.translate("MainWindow", "Object", None, QtGui.QApplication.UnicodeUTF8)) |
|
|||
1295 | self.label_55.setText(QtGui.QApplication.translate("MainWindow", "Read Mode:", None, QtGui.QApplication.UnicodeUTF8)) |
|
1020 | self.label_55.setText(QtGui.QApplication.translate("MainWindow", "Read Mode:", None, QtGui.QApplication.UnicodeUTF8)) | |
1296 | self.readModeCmBox.setItemText(0, QtGui.QApplication.translate("MainWindow", "OffLine", None, QtGui.QApplication.UnicodeUTF8)) |
|
1021 | self.readModeCmBox.setItemText(0, QtGui.QApplication.translate("MainWindow", "OffLine", None, QtGui.QApplication.UnicodeUTF8)) | |
1297 | self.readModeCmBox.setItemText(1, QtGui.QApplication.translate("MainWindow", "OnLine", None, QtGui.QApplication.UnicodeUTF8)) |
|
1022 | self.readModeCmBox.setItemText(1, QtGui.QApplication.translate("MainWindow", "OnLine", None, QtGui.QApplication.UnicodeUTF8)) | |
1298 | self.dataWaitLine.setText(QtGui.QApplication.translate("MainWindow", "Wait(sec):", None, QtGui.QApplication.UnicodeUTF8)) |
|
1023 | self.dataWaitLine.setText(QtGui.QApplication.translate("MainWindow", "Wait(sec):", None, QtGui.QApplication.UnicodeUTF8)) | |
1299 |
self.data |
|
1024 | self.dataTypeLine.setText(QtGui.QApplication.translate("MainWindow", "Data type :", None, QtGui.QApplication.UnicodeUTF8)) | |
1300 | self.dataPathline.setText(QtGui.QApplication.translate("MainWindow", "Data Path :", None, QtGui.QApplication.UnicodeUTF8)) |
|
1025 | self.dataPathline.setText(QtGui.QApplication.translate("MainWindow", "Data Path :", None, QtGui.QApplication.UnicodeUTF8)) | |
1301 |
self.data |
|
1026 | self.dataTypeCmbBox.setItemText(0, QtGui.QApplication.translate("MainWindow", "Voltage", None, QtGui.QApplication.UnicodeUTF8)) | |
1302 |
self.data |
|
1027 | self.dataTypeCmbBox.setItemText(1, QtGui.QApplication.translate("MainWindow", "Spectra", None, QtGui.QApplication.UnicodeUTF8)) | |
1303 | self.dataPathBrowse.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) |
|
1028 | self.dataPathBrowse.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) | |
1304 |
self.dataOperationModeline.setText(QtGui.QApplication.translate("MainWindow", " |
|
1029 | self.dataOperationModeline.setText(QtGui.QApplication.translate("MainWindow", "Project Configuration:", None, QtGui.QApplication.UnicodeUTF8)) | |
1305 | self.operationModeCmbBox.setItemText(0, QtGui.QApplication.translate("MainWindow", "Basico", None, QtGui.QApplication.UnicodeUTF8)) |
|
|||
1306 | self.operationModeCmbBox.setItemText(1, QtGui.QApplication.translate("MainWindow", "Avanzado", None, QtGui.QApplication.UnicodeUTF8)) |
|
|||
1307 | self.dataYearLine.setText(QtGui.QApplication.translate("MainWindow", "Year:", None, QtGui.QApplication.UnicodeUTF8)) |
|
|||
1308 | self.dataStartLine.setText(QtGui.QApplication.translate("MainWindow", "Start date :", None, QtGui.QApplication.UnicodeUTF8)) |
|
1030 | self.dataStartLine.setText(QtGui.QApplication.translate("MainWindow", "Start date :", None, QtGui.QApplication.UnicodeUTF8)) | |
1309 | self.dataEndline.setText(QtGui.QApplication.translate("MainWindow", "End date :", None, QtGui.QApplication.UnicodeUTF8)) |
|
1031 | self.dataEndline.setText(QtGui.QApplication.translate("MainWindow", "End date :", None, QtGui.QApplication.UnicodeUTF8)) | |
1310 | self.LTReferenceRdBtn.setText(QtGui.QApplication.translate("MainWindow", "Local time frame of reference", None, QtGui.QApplication.UnicodeUTF8)) |
|
1032 | self.LTReferenceRdBtn.setText(QtGui.QApplication.translate("MainWindow", "Local time frame of reference", None, QtGui.QApplication.UnicodeUTF8)) | |
@@ -1316,6 +1038,10 class Ui_MainWindow(object): | |||||
1316 | self.removeDCCEB.setText(QtGui.QApplication.translate("MainWindow", "Remove DC", None, QtGui.QApplication.UnicodeUTF8)) |
|
1038 | self.removeDCCEB.setText(QtGui.QApplication.translate("MainWindow", "Remove DC", None, QtGui.QApplication.UnicodeUTF8)) | |
1317 | self.coherentIntegrationCEB.setText(QtGui.QApplication.translate("MainWindow", "Coherent Integration", None, QtGui.QApplication.UnicodeUTF8)) |
|
1039 | self.coherentIntegrationCEB.setText(QtGui.QApplication.translate("MainWindow", "Coherent Integration", None, QtGui.QApplication.UnicodeUTF8)) | |
1318 | self.decodeCEB.setText(QtGui.QApplication.translate("MainWindow", "Decodification", None, QtGui.QApplication.UnicodeUTF8)) |
|
1040 | self.decodeCEB.setText(QtGui.QApplication.translate("MainWindow", "Decodification", None, QtGui.QApplication.UnicodeUTF8)) | |
|
1041 | self.profileOpVolcob.setItemText(0, QtGui.QApplication.translate("MainWindow", "ProfileList", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
1042 | self.profileOpVolcob.setItemText(1, QtGui.QApplication.translate("MainWindow", "ProfileRangeList", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
1043 | self.selecChannelopVolCEB.setText(QtGui.QApplication.translate("MainWindow", "Select Channels", None, QtGui.QApplication.UnicodeUTF8)) | |||
|
1044 | self.selecHeighopVolCEB.setText(QtGui.QApplication.translate("MainWindow", "Select Heights", None, QtGui.QApplication.UnicodeUTF8)) | |||
1319 | self.dataopVolOkBtn.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) |
|
1045 | self.dataopVolOkBtn.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |
1320 | self.dataopVolCancelBtn.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) |
|
1046 | self.dataopVolCancelBtn.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |
1321 | self.tabWidget_3.setTabText(self.tabWidget_3.indexOf(self.tab_3), QtGui.QApplication.translate("MainWindow", "Operations", None, QtGui.QApplication.UnicodeUTF8)) |
|
1047 | self.tabWidget_3.setTabText(self.tabWidget_3.indexOf(self.tab_3), QtGui.QApplication.translate("MainWindow", "Operations", None, QtGui.QApplication.UnicodeUTF8)) | |
@@ -1330,24 +1056,24 class Ui_MainWindow(object): | |||||
1330 | self.label_13.setText(QtGui.QApplication.translate("MainWindow", "FTP server", None, QtGui.QApplication.UnicodeUTF8)) |
|
1056 | self.label_13.setText(QtGui.QApplication.translate("MainWindow", "FTP server", None, QtGui.QApplication.UnicodeUTF8)) | |
1331 | self.label_14.setText(QtGui.QApplication.translate("MainWindow", "FTP path", None, QtGui.QApplication.UnicodeUTF8)) |
|
1057 | self.label_14.setText(QtGui.QApplication.translate("MainWindow", "FTP path", None, QtGui.QApplication.UnicodeUTF8)) | |
1332 | self.toolButton_2.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) |
|
1058 | self.toolButton_2.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) | |
1333 |
self.dataOkBtn |
|
1059 | self.dataGraphVolOkBtn.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |
1334 |
self.dataCancelBtn |
|
1060 | self.dataGraphVolCancelBtn.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |
1335 | self.tabWidget_3.setTabText(self.tabWidget_3.indexOf(self.tab_2), QtGui.QApplication.translate("MainWindow", "Graphics", None, QtGui.QApplication.UnicodeUTF8)) |
|
1061 | self.tabWidget_3.setTabText(self.tabWidget_3.indexOf(self.tab_2), QtGui.QApplication.translate("MainWindow", "Graphics", None, QtGui.QApplication.UnicodeUTF8)) | |
1336 | self.dataPathlabelOutVol.setText(QtGui.QApplication.translate("MainWindow", "Path", None, QtGui.QApplication.UnicodeUTF8)) |
|
1062 | self.dataPathlabelOutVol.setText(QtGui.QApplication.translate("MainWindow", "Path", None, QtGui.QApplication.UnicodeUTF8)) | |
1337 | self.dataOutVolPathBrowse.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) |
|
1063 | self.dataOutVolPathBrowse.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) | |
1338 | self.dataSufixlabelOutVol.setText(QtGui.QApplication.translate("MainWindow", "Sufix", None, QtGui.QApplication.UnicodeUTF8)) |
|
1064 | self.dataSufixlabelOutVol.setText(QtGui.QApplication.translate("MainWindow", "Sufix", None, QtGui.QApplication.UnicodeUTF8)) | |
1339 |
self.data |
|
1065 | self.datasaveVolOkBtn.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |
1340 |
self.dataCancelBtn |
|
1066 | self.datasaveVolCancelBtn.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |
1341 | self.tabWidget_3.setTabText(self.tabWidget_3.indexOf(self.tab_4), QtGui.QApplication.translate("MainWindow", "Save Data", None, QtGui.QApplication.UnicodeUTF8)) |
|
1067 | self.tabWidget_3.setTabText(self.tabWidget_3.indexOf(self.tab_4), QtGui.QApplication.translate("MainWindow", "Save Data", None, QtGui.QApplication.UnicodeUTF8)) | |
1342 | self.tabWidget.setTabText(self.tabWidget.indexOf(self.tab_7), QtGui.QApplication.translate("MainWindow", "Voltage", None, QtGui.QApplication.UnicodeUTF8)) |
|
1068 | self.tabWidget.setTabText(self.tabWidget.indexOf(self.tab_7), QtGui.QApplication.translate("MainWindow", "Voltage", None, QtGui.QApplication.UnicodeUTF8)) | |
1343 | self.checkBox_49.setText(QtGui.QApplication.translate("MainWindow", "Remove DC", None, QtGui.QApplication.UnicodeUTF8)) |
|
1069 | self.checkBox_49.setText(QtGui.QApplication.translate("MainWindow", "Remove DC", None, QtGui.QApplication.UnicodeUTF8)) | |
1344 | self.checkBox_50.setText(QtGui.QApplication.translate("MainWindow", "Remove Interference", None, QtGui.QApplication.UnicodeUTF8)) |
|
1070 | self.checkBox_50.setText(QtGui.QApplication.translate("MainWindow", "Remove Interference", None, QtGui.QApplication.UnicodeUTF8)) | |
1345 | self.checkBox_51.setText(QtGui.QApplication.translate("MainWindow", "Integration Incoherent", None, QtGui.QApplication.UnicodeUTF8)) |
|
1071 | self.checkBox_51.setText(QtGui.QApplication.translate("MainWindow", "Integration Incoherent", None, QtGui.QApplication.UnicodeUTF8)) | |
1346 | self.checkBox_52.setText(QtGui.QApplication.translate("MainWindow", "Operation 4", None, QtGui.QApplication.UnicodeUTF8)) |
|
1072 | self.checkBox_52.setText(QtGui.QApplication.translate("MainWindow", "Operation 4", None, QtGui.QApplication.UnicodeUTF8)) | |
1347 |
self.dataOkBtn |
|
1073 | self.dataopSpecOkBtn.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |
1348 |
self.dataCancelBtn |
|
1074 | self.dataopSpecCancelBtn.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |
1349 | self.tabWidget_4.setTabText(self.tabWidget_4.indexOf(self.tab_8), QtGui.QApplication.translate("MainWindow", "Operations", None, QtGui.QApplication.UnicodeUTF8)) |
|
1075 | self.tabWidget_4.setTabText(self.tabWidget_4.indexOf(self.tab_8), QtGui.QApplication.translate("MainWindow", "Operations", None, QtGui.QApplication.UnicodeUTF8)) | |
1350 |
self.dataCancelBtn |
|
1076 | self.dataGraphSpecCancelBtn.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |
1351 | self.label_80.setText(QtGui.QApplication.translate("MainWindow", "Type", None, QtGui.QApplication.UnicodeUTF8)) |
|
1077 | self.label_80.setText(QtGui.QApplication.translate("MainWindow", "Type", None, QtGui.QApplication.UnicodeUTF8)) | |
1352 | self.label_81.setText(QtGui.QApplication.translate("MainWindow", "Show", None, QtGui.QApplication.UnicodeUTF8)) |
|
1078 | self.label_81.setText(QtGui.QApplication.translate("MainWindow", "Show", None, QtGui.QApplication.UnicodeUTF8)) | |
1353 | self.label_82.setText(QtGui.QApplication.translate("MainWindow", "Save", None, QtGui.QApplication.UnicodeUTF8)) |
|
1079 | self.label_82.setText(QtGui.QApplication.translate("MainWindow", "Save", None, QtGui.QApplication.UnicodeUTF8)) | |
@@ -1356,7 +1082,7 class Ui_MainWindow(object): | |||||
1356 | self.label_85.setText(QtGui.QApplication.translate("MainWindow", "CROSS-SPECTRA", None, QtGui.QApplication.UnicodeUTF8)) |
|
1082 | self.label_85.setText(QtGui.QApplication.translate("MainWindow", "CROSS-SPECTRA", None, QtGui.QApplication.UnicodeUTF8)) | |
1357 | self.label_86.setText(QtGui.QApplication.translate("MainWindow", "NOISE", None, QtGui.QApplication.UnicodeUTF8)) |
|
1083 | self.label_86.setText(QtGui.QApplication.translate("MainWindow", "NOISE", None, QtGui.QApplication.UnicodeUTF8)) | |
1358 | self.label_100.setText(QtGui.QApplication.translate("MainWindow", "PHASE", None, QtGui.QApplication.UnicodeUTF8)) |
|
1084 | self.label_100.setText(QtGui.QApplication.translate("MainWindow", "PHASE", None, QtGui.QApplication.UnicodeUTF8)) | |
1359 |
self.dataOkBtn |
|
1085 | self.dataGraphSpecOkBtn.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |
1360 | self.label_78.setText(QtGui.QApplication.translate("MainWindow", "Path", None, QtGui.QApplication.UnicodeUTF8)) |
|
1086 | self.label_78.setText(QtGui.QApplication.translate("MainWindow", "Path", None, QtGui.QApplication.UnicodeUTF8)) | |
1361 | self.label_79.setText(QtGui.QApplication.translate("MainWindow", "Prefix", None, QtGui.QApplication.UnicodeUTF8)) |
|
1087 | self.label_79.setText(QtGui.QApplication.translate("MainWindow", "Prefix", None, QtGui.QApplication.UnicodeUTF8)) | |
1362 | self.toolButton_17.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) |
|
1088 | self.toolButton_17.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) | |
@@ -1368,13 +1094,13 class Ui_MainWindow(object): | |||||
1368 | self.label_20.setText(QtGui.QApplication.translate("MainWindow", "Path", None, QtGui.QApplication.UnicodeUTF8)) |
|
1094 | self.label_20.setText(QtGui.QApplication.translate("MainWindow", "Path", None, QtGui.QApplication.UnicodeUTF8)) | |
1369 | self.toolButton_5.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) |
|
1095 | self.toolButton_5.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) | |
1370 | self.label_21.setText(QtGui.QApplication.translate("MainWindow", "Sufix", None, QtGui.QApplication.UnicodeUTF8)) |
|
1096 | self.label_21.setText(QtGui.QApplication.translate("MainWindow", "Sufix", None, QtGui.QApplication.UnicodeUTF8)) | |
1371 |
self.dataOkBtn |
|
1097 | self.datasaveSpecOkBtn.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |
1372 |
self.dataCancelBtn |
|
1098 | self.datasaveSpecCancelBtn.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |
1373 | self.tabWidget_4.setTabText(self.tabWidget_4.indexOf(self.tab_11), QtGui.QApplication.translate("MainWindow", "Save Data", None, QtGui.QApplication.UnicodeUTF8)) |
|
1099 | self.tabWidget_4.setTabText(self.tabWidget_4.indexOf(self.tab_11), QtGui.QApplication.translate("MainWindow", "Save Data", None, QtGui.QApplication.UnicodeUTF8)) | |
1374 | self.tabWidget.setTabText(self.tabWidget.indexOf(self.tab_6), QtGui.QApplication.translate("MainWindow", "Spectra", None, QtGui.QApplication.UnicodeUTF8)) |
|
1100 | self.tabWidget.setTabText(self.tabWidget.indexOf(self.tab_6), QtGui.QApplication.translate("MainWindow", "Spectra", None, QtGui.QApplication.UnicodeUTF8)) | |
1375 | self.checkBox_53.setText(QtGui.QApplication.translate("MainWindow", "Integration", None, QtGui.QApplication.UnicodeUTF8)) |
|
1101 | self.checkBox_53.setText(QtGui.QApplication.translate("MainWindow", "Integration", None, QtGui.QApplication.UnicodeUTF8)) | |
1376 |
self.dataOkBtn |
|
1102 | self.dataopCorrOkBtn.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |
1377 |
self.dataCancelBtn |
|
1103 | self.dataopCorrCancelBtn.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |
1378 | self.tabWidget_5.setTabText(self.tabWidget_5.indexOf(self.tab_12), QtGui.QApplication.translate("MainWindow", "Operations", None, QtGui.QApplication.UnicodeUTF8)) |
|
1104 | self.tabWidget_5.setTabText(self.tabWidget_5.indexOf(self.tab_12), QtGui.QApplication.translate("MainWindow", "Operations", None, QtGui.QApplication.UnicodeUTF8)) | |
1379 | self.label_95.setText(QtGui.QApplication.translate("MainWindow", "Type", None, QtGui.QApplication.UnicodeUTF8)) |
|
1105 | self.label_95.setText(QtGui.QApplication.translate("MainWindow", "Type", None, QtGui.QApplication.UnicodeUTF8)) | |
1380 | self.label_96.setText(QtGui.QApplication.translate("MainWindow", "Show", None, QtGui.QApplication.UnicodeUTF8)) |
|
1106 | self.label_96.setText(QtGui.QApplication.translate("MainWindow", "Show", None, QtGui.QApplication.UnicodeUTF8)) | |
@@ -1386,15 +1112,15 class Ui_MainWindow(object): | |||||
1386 | self.label_99.setText(QtGui.QApplication.translate("MainWindow", "Prefix", None, QtGui.QApplication.UnicodeUTF8)) |
|
1112 | self.label_99.setText(QtGui.QApplication.translate("MainWindow", "Prefix", None, QtGui.QApplication.UnicodeUTF8)) | |
1387 | self.toolButton_20.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) |
|
1113 | self.toolButton_20.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) | |
1388 | self.label_91.setText(QtGui.QApplication.translate("MainWindow", "POTENCIA", None, QtGui.QApplication.UnicodeUTF8)) |
|
1114 | self.label_91.setText(QtGui.QApplication.translate("MainWindow", "POTENCIA", None, QtGui.QApplication.UnicodeUTF8)) | |
1389 |
self.dataOkBtn |
|
1115 | self.dataGraphCorrOkBtn.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |
1390 |
self.dataCancelBtn |
|
1116 | self.dataGraphCorrCancelBtn.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |
1391 | self.tabWidget_5.setTabText(self.tabWidget_5.indexOf(self.tab_13), QtGui.QApplication.translate("MainWindow", "Graphics", None, QtGui.QApplication.UnicodeUTF8)) |
|
1117 | self.tabWidget_5.setTabText(self.tabWidget_5.indexOf(self.tab_13), QtGui.QApplication.translate("MainWindow", "Graphics", None, QtGui.QApplication.UnicodeUTF8)) | |
1392 | self.label_17.setText(QtGui.QApplication.translate("MainWindow", "Data format", None, QtGui.QApplication.UnicodeUTF8)) |
|
1118 | self.label_17.setText(QtGui.QApplication.translate("MainWindow", "Data format", None, QtGui.QApplication.UnicodeUTF8)) | |
1393 | self.label_18.setText(QtGui.QApplication.translate("MainWindow", "Path", None, QtGui.QApplication.UnicodeUTF8)) |
|
1119 | self.label_18.setText(QtGui.QApplication.translate("MainWindow", "Path", None, QtGui.QApplication.UnicodeUTF8)) | |
1394 | self.toolButton_4.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) |
|
1120 | self.toolButton_4.setText(QtGui.QApplication.translate("MainWindow", "...", None, QtGui.QApplication.UnicodeUTF8)) | |
1395 | self.label_19.setText(QtGui.QApplication.translate("MainWindow", "Sufix", None, QtGui.QApplication.UnicodeUTF8)) |
|
1121 | self.label_19.setText(QtGui.QApplication.translate("MainWindow", "Sufix", None, QtGui.QApplication.UnicodeUTF8)) | |
1396 |
self.dataOkBtn |
|
1122 | self.datasaveCorrOkBtn.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |
1397 |
self.dataCancelBtn |
|
1123 | self.dataSaveCorrCancelBtn.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |
1398 | self.tabWidget_5.setTabText(self.tabWidget_5.indexOf(self.tab_14), QtGui.QApplication.translate("MainWindow", "Save Data", None, QtGui.QApplication.UnicodeUTF8)) |
|
1124 | self.tabWidget_5.setTabText(self.tabWidget_5.indexOf(self.tab_14), QtGui.QApplication.translate("MainWindow", "Save Data", None, QtGui.QApplication.UnicodeUTF8)) | |
1399 | self.tabWidget.setTabText(self.tabWidget.indexOf(self.tab_9), QtGui.QApplication.translate("MainWindow", "Correlation", None, QtGui.QApplication.UnicodeUTF8)) |
|
1125 | self.tabWidget.setTabText(self.tabWidget.indexOf(self.tab_9), QtGui.QApplication.translate("MainWindow", "Correlation", None, QtGui.QApplication.UnicodeUTF8)) | |
1400 | self.tabWidget_2.setTabText(self.tabWidget_2.indexOf(self.tab), QtGui.QApplication.translate("MainWindow", "Ouput Branch", None, QtGui.QApplication.UnicodeUTF8)) |
|
1126 | self.tabWidget_2.setTabText(self.tabWidget_2.indexOf(self.tab), QtGui.QApplication.translate("MainWindow", "Ouput Branch", None, QtGui.QApplication.UnicodeUTF8)) |
@@ -2,7 +2,7 | |||||
2 |
|
2 | |||
3 | # Form implementation generated from reading ui file 'C:\Users\alex\ericworkspace\UIDOS\window.ui' |
|
3 | # Form implementation generated from reading ui file 'C:\Users\alex\ericworkspace\UIDOS\window.ui' | |
4 | # |
|
4 | # | |
5 |
# Created: |
|
5 | # Created: Thu Dec 06 08:56:59 2012 | |
6 | # by: PyQt4 UI code generator 4.9.4 |
|
6 | # by: PyQt4 UI code generator 4.9.4 | |
7 | # |
|
7 | # | |
8 | # WARNING! All changes made in this file will be lost! |
|
8 | # WARNING! All changes made in this file will be lost! | |
@@ -33,10 +33,10 class Ui_window(object): | |||||
33 | self.label_2.setFont(font) |
|
33 | self.label_2.setFont(font) | |
34 | self.label_2.setObjectName(_fromUtf8("label_2")) |
|
34 | self.label_2.setObjectName(_fromUtf8("label_2")) | |
35 | self.cancelButton = QtGui.QPushButton(self.centralWidget) |
|
35 | self.cancelButton = QtGui.QPushButton(self.centralWidget) | |
36 |
self.cancelButton.setGeometry(QtCore.QRect(1 |
|
36 | self.cancelButton.setGeometry(QtCore.QRect(150, 160, 51, 23)) | |
37 | self.cancelButton.setObjectName(_fromUtf8("cancelButton")) |
|
37 | self.cancelButton.setObjectName(_fromUtf8("cancelButton")) | |
38 | self.okButton = QtGui.QPushButton(self.centralWidget) |
|
38 | self.okButton = QtGui.QPushButton(self.centralWidget) | |
39 |
self.okButton.setGeometry(QtCore.QRect( |
|
39 | self.okButton.setGeometry(QtCore.QRect(80, 160, 61, 23)) | |
40 | self.okButton.setObjectName(_fromUtf8("okButton")) |
|
40 | self.okButton.setObjectName(_fromUtf8("okButton")) | |
41 | self.proyectNameLine = QtGui.QLineEdit(self.centralWidget) |
|
41 | self.proyectNameLine = QtGui.QLineEdit(self.centralWidget) | |
42 | self.proyectNameLine.setGeometry(QtCore.QRect(20, 30, 181, 20)) |
|
42 | self.proyectNameLine.setGeometry(QtCore.QRect(20, 30, 181, 20)) | |
@@ -44,6 +44,9 class Ui_window(object): | |||||
44 | self.descriptionTextEdit = QtGui.QTextEdit(self.centralWidget) |
|
44 | self.descriptionTextEdit = QtGui.QTextEdit(self.centralWidget) | |
45 | self.descriptionTextEdit.setGeometry(QtCore.QRect(20, 80, 181, 71)) |
|
45 | self.descriptionTextEdit.setGeometry(QtCore.QRect(20, 80, 181, 71)) | |
46 | self.descriptionTextEdit.setObjectName(_fromUtf8("descriptionTextEdit")) |
|
46 | self.descriptionTextEdit.setObjectName(_fromUtf8("descriptionTextEdit")) | |
|
47 | self.saveButton = QtGui.QPushButton(self.centralWidget) | |||
|
48 | self.saveButton.setGeometry(QtCore.QRect(20, 160, 51, 23)) | |||
|
49 | self.saveButton.setObjectName(_fromUtf8("saveButton")) | |||
47 | MainWindow.setCentralWidget(self.centralWidget) |
|
50 | MainWindow.setCentralWidget(self.centralWidget) | |
48 |
|
51 | |||
49 | self.retranslateUi(MainWindow) |
|
52 | self.retranslateUi(MainWindow) | |
@@ -55,6 +58,7 class Ui_window(object): | |||||
55 | self.label_2.setText(QtGui.QApplication.translate("MainWindow", "Description :", None, QtGui.QApplication.UnicodeUTF8)) |
|
58 | self.label_2.setText(QtGui.QApplication.translate("MainWindow", "Description :", None, QtGui.QApplication.UnicodeUTF8)) | |
56 | self.cancelButton.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) |
|
59 | self.cancelButton.setText(QtGui.QApplication.translate("MainWindow", "Cancel", None, QtGui.QApplication.UnicodeUTF8)) | |
57 | self.okButton.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) |
|
60 | self.okButton.setText(QtGui.QApplication.translate("MainWindow", "Ok", None, QtGui.QApplication.UnicodeUTF8)) | |
|
61 | self.saveButton.setText(QtGui.QApplication.translate("MainWindow", "Save", None, QtGui.QApplication.UnicodeUTF8)) | |||
58 |
|
62 | |||
59 |
|
63 | |||
60 | if __name__ == "__main__": |
|
64 | if __name__ == "__main__": |
General Comments 0
You need to be logged in to leave comments.
Login now