개정판 421a15cb
issue #501: save fixed
DTI_PID/DTI_PID/MainWindow.py | ||
---|---|---|
422 | 422 |
appDocData.symbols.clear() |
423 | 423 |
appDocData.lineNos.clear() |
424 | 424 |
appDocData.texts.clear() |
425 |
appDocData.lines.clear() |
|
425 | 426 |
|
426 | 427 |
self.dbUpdate() |
428 |
items = self.graphicsView.scene.items() |
|
429 |
for item in items: |
|
430 |
if type(item) is not QGraphicsPixmapItem: |
|
431 |
appDocData.equipments.append(item) |
|
432 |
if type(item) is QEngineeringLineItem: |
|
433 |
print('a') |
|
427 | 434 |
self.saveToXml(True) |
428 | 435 |
|
429 | 436 |
drawings = appDocData.getDrawings() |
DTI_PID/DTI_PID/Shapes/EngineeringLineNoTextItem.py | ||
---|---|---|
184 | 184 |
textNode.text = self.text() |
185 | 185 |
node.append(textNode) |
186 | 186 |
|
187 |
rect = self.sceneBoundingRect() |
|
188 | 187 |
locNode = Element('LOCATION') |
189 |
locNode.text = '{},{}'.format(rect.left(), rect.top())
|
|
188 |
locNode.text = '{},{}'.format(self.loc[0], self.loc[1])
|
|
190 | 189 |
node.append(locNode) |
191 | 190 |
|
192 | 191 |
widthNode = Element('WIDTH') |
193 |
widthNode.text = str(rect.width())
|
|
192 |
widthNode.text = str(self.size[0])
|
|
194 | 193 |
node.append(widthNode) |
195 | 194 |
|
196 | 195 |
heightNode = Element('HEIGHT') |
197 |
heightNode.text = str(rect.height())
|
|
196 |
heightNode.text = str(self.size[1])
|
|
198 | 197 |
node.append(heightNode) |
199 | 198 |
|
200 | 199 |
angleNode = Element('ANGLE') |
내보내기 Unified diff