개정판 2696115f
issue #563: fix attr and disable symbol tree selection
Change-Id: Ic332d836428a2dcbbb203cbc7dd115925085e8d4
DTI_PID/DTI_PID/MainWindow.py | ||
---|---|---|
1029 | 1029 |
self.tableWidgetInconsistency.selectRow(index) |
1030 | 1030 |
break |
1031 | 1031 |
if issubclass(type(item), SymbolSvgItem): |
1032 |
self.symbolTreeWidget.select_symbol(item) |
|
1032 |
pass |
|
1033 |
#self.symbolTreeWidget.select_symbol(item) |
|
1033 | 1034 |
else: |
1034 | 1035 |
self.resultPropertyTableWidget.show_item_property(None) |
1035 | 1036 |
|
... | ... | |
1835 | 1836 |
from TextInfo import TextInfo |
1836 | 1837 |
|
1837 | 1838 |
textItems = [text for text in self.graphicsView.scene().selectedItems() if |
1838 |
type(text) is QEngineeringTextItem]
|
|
1839 |
issubclass(type(text), QEngineeringTextItem)]
|
|
1839 | 1840 |
if not textItems or len(textItems) is 1: |
1840 | 1841 |
return |
1841 | 1842 |
|
DTI_PID/DTI_PID/Shapes/EngineeringAbstractItem.py | ||
---|---|---|
350 | 350 |
for match in matches: |
351 | 351 |
attr_name = attr.Expression[(match.start() + 1):(match.end() - 1)] |
352 | 352 |
values = [value for key, value in _attrs.items() if key.Attribute == attr_name] |
353 |
value += attr.Expression[pos:match.start()] + values[0] if values else '' |
|
353 |
value += attr.Expression[pos:match.start()] + values[0] if values and values[0] else ''
|
|
354 | 354 |
pos = match.end() |
355 | 355 |
|
356 | 356 |
value += attr.Expression[pos:len(attr.Expression)] |
DTI_PID/DTI_PID/Shapes/SymbolSvgItem.py | ||
---|---|---|
1041 | 1041 |
elif event.key() == Qt.Key_F and type(self) is not QEngineeringErrorItem: |
1042 | 1042 |
self.flipSymbol() |
1043 | 1043 |
elif event.key() == Qt.Key_Return: |
1044 |
return |
|
1045 |
# disable |
|
1044 | 1046 |
dialog = QRotateSymbolDialog(None, self.angle, self.origin, self.zValue()) |
1045 | 1047 |
(isAccept, angle, x, y, z) = dialog.showDialog() |
1046 | 1048 |
|
내보내기 Unified diff