개정판 587e8b33
revised issue #587: change line property type
DTI_PID/DTI_PID/AttrEditor_UI.py | ||
---|---|---|
1 |
# -*- coding: utf-8 -*- |
|
2 |
|
|
3 |
# Form implementation generated from reading ui file './UI/AttrEditor.ui' |
|
4 |
# |
|
5 |
# Created by: PyQt5 UI code generator 5.9.2 |
|
6 |
# |
|
7 |
# WARNING! All changes made in this file will be lost! |
|
8 |
|
|
9 |
from PyQt5 import QtCore, QtGui, QtWidgets |
|
10 |
|
|
11 |
class Ui_AttrEditorDialog(object): |
|
12 |
def setupUi(self, AttrEditorDialog): |
|
13 |
AttrEditorDialog.setObjectName("AttrEditorDialog") |
|
14 |
AttrEditorDialog.resize(825, 446) |
|
15 |
font = QtGui.QFont() |
|
16 |
font.setFamily("맑은 고딕") |
|
17 |
font.setBold(True) |
|
18 |
font.setWeight(75) |
|
19 |
AttrEditorDialog.setFont(font) |
|
20 |
self.gridLayout = QtWidgets.QGridLayout(AttrEditorDialog) |
|
21 |
self.gridLayout.setObjectName("gridLayout") |
|
22 |
self.groupBox = QtWidgets.QGroupBox(AttrEditorDialog) |
|
23 |
self.groupBox.setObjectName("groupBox") |
|
24 |
self.gridLayout_2 = QtWidgets.QGridLayout(self.groupBox) |
|
25 |
self.gridLayout_2.setObjectName("gridLayout_2") |
|
26 |
self.verticalLayout = QtWidgets.QVBoxLayout() |
|
27 |
self.verticalLayout.setObjectName("verticalLayout") |
|
28 |
self.horizontalLayout = QtWidgets.QHBoxLayout() |
|
29 |
self.horizontalLayout.setObjectName("horizontalLayout") |
|
30 |
self.comboBoxSymbolType = QtWidgets.QComboBox(self.groupBox) |
|
31 |
self.comboBoxSymbolType.setObjectName("comboBoxSymbolType") |
|
32 |
self.horizontalLayout.addWidget(self.comboBoxSymbolType) |
|
33 |
self.labelLineNo = QtWidgets.QLabel(self.groupBox) |
|
34 |
self.labelLineNo.setObjectName("labelLineNo") |
|
35 |
self.horizontalLayout.addWidget(self.labelLineNo) |
|
36 |
spacerItem = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) |
|
37 |
self.horizontalLayout.addItem(spacerItem) |
|
38 |
self.pushButtonAddAttr = QtWidgets.QPushButton(self.groupBox) |
|
39 |
self.pushButtonAddAttr.setMaximumSize(QtCore.QSize(24, 16777215)) |
|
40 |
self.pushButtonAddAttr.setObjectName("pushButtonAddAttr") |
|
41 |
self.horizontalLayout.addWidget(self.pushButtonAddAttr, 0, QtCore.Qt.AlignRight) |
|
42 |
self.pushButtonDelAttr = QtWidgets.QPushButton(self.groupBox) |
|
43 |
self.pushButtonDelAttr.setMaximumSize(QtCore.QSize(24, 16777215)) |
|
44 |
self.pushButtonDelAttr.setObjectName("pushButtonDelAttr") |
|
45 |
self.horizontalLayout.addWidget(self.pushButtonDelAttr, 0, QtCore.Qt.AlignRight) |
|
46 |
self.verticalLayout.addLayout(self.horizontalLayout) |
|
47 |
self.horizontalLayout_2 = QtWidgets.QHBoxLayout() |
|
48 |
self.horizontalLayout_2.setObjectName("horizontalLayout_2") |
|
49 |
self.verticalLayout.addLayout(self.horizontalLayout_2) |
|
50 |
self.gridLayout_2.addLayout(self.verticalLayout, 0, 0, 1, 1) |
|
51 |
self.gridLayout.addWidget(self.groupBox, 0, 0, 1, 1) |
|
52 |
self.buttonBox = QtWidgets.QDialogButtonBox(AttrEditorDialog) |
|
53 |
self.buttonBox.setOrientation(QtCore.Qt.Horizontal) |
|
54 |
self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Cancel|QtWidgets.QDialogButtonBox.Ok) |
|
55 |
self.buttonBox.setObjectName("buttonBox") |
|
56 |
self.gridLayout.addWidget(self.buttonBox, 1, 0, 1, 1) |
|
57 |
|
|
58 |
self.retranslateUi(AttrEditorDialog) |
|
59 |
self.buttonBox.accepted.connect(AttrEditorDialog.accept) |
|
60 |
self.buttonBox.rejected.connect(AttrEditorDialog.reject) |
|
61 |
QtCore.QMetaObject.connectSlotsByName(AttrEditorDialog) |
|
62 |
|
|
63 |
def retranslateUi(self, AttrEditorDialog): |
|
64 |
_translate = QtCore.QCoreApplication.translate |
|
65 |
AttrEditorDialog.setWindowTitle(_translate("AttrEditorDialog", "속성 편집")) |
|
66 |
self.groupBox.setTitle(_translate("AttrEditorDialog", "속성")) |
|
67 |
self.labelLineNo.setText(_translate("AttrEditorDialog", "Line No Attribute")) |
|
68 |
self.pushButtonAddAttr.setText(_translate("AttrEditorDialog", "+")) |
|
69 |
self.pushButtonDelAttr.setText(_translate("AttrEditorDialog", "-")) |
|
70 |
|
|
71 |
|
|
72 |
if __name__ == "__main__": |
|
73 |
import sys |
|
74 |
app = QtWidgets.QApplication(sys.argv) |
|
75 |
AttrEditorDialog = QtWidgets.QDialog() |
|
76 |
ui = Ui_AttrEditorDialog() |
|
77 |
ui.setupUi(AttrEditorDialog) |
|
78 |
AttrEditorDialog.show() |
|
79 |
sys.exit(app.exec_()) |
|
80 |
|
DTI_PID/DTI_PID/SymbolAttrEditorDialog.py | ||
---|---|---|
14 | 14 |
from TableWidgetEx import QTableWidgetEx |
15 | 15 |
from SymbolSvgItem import SymbolSvgItem |
16 | 16 |
|
17 |
import AttrEditor_UI |
|
17 |
import SymbolAttrEditor_UI
|
|
18 | 18 |
|
19 | 19 |
class QSymbolAttrEditorDialog(QDialog): |
20 | 20 |
def __init__(self, parent, symbolType = None): |
21 | 21 |
QDialog.__init__(self, parent) |
22 | 22 |
|
23 |
self.ui = AttrEditor_UI.Ui_AttrEditorDialog()
|
|
23 |
self.ui = SymbolAttrEditor_UI.Ui_SymbolAttrEditorDialog()
|
|
24 | 24 |
self.ui.setupUi(self) |
25 | 25 |
|
26 | 26 |
self._symbolType = symbolType |
DTI_PID/DTI_PID/SymbolAttrEditor_UI.py | ||
---|---|---|
1 |
# -*- coding: utf-8 -*- |
|
2 |
|
|
3 |
# Form implementation generated from reading ui file './UI/AttrEditor.ui' |
|
4 |
# |
|
5 |
# Created by: PyQt5 UI code generator 5.9.2 |
|
6 |
# |
|
7 |
# WARNING! All changes made in this file will be lost! |
|
8 |
|
|
9 |
from PyQt5 import QtCore, QtGui, QtWidgets |
|
10 |
|
|
11 |
class Ui_SymbolAttrEditorDialog(object): |
|
12 |
def setupUi(self, AttrEditorDialog): |
|
13 |
AttrEditorDialog.setObjectName("AttrEditorDialog") |
|
14 |
AttrEditorDialog.resize(825, 446) |
|
15 |
font = QtGui.QFont() |
|
16 |
font.setFamily("맑은 고딕") |
|
17 |
font.setBold(True) |
|
18 |
font.setWeight(75) |
|
19 |
AttrEditorDialog.setFont(font) |
|
20 |
self.gridLayout = QtWidgets.QGridLayout(AttrEditorDialog) |
|
21 |
self.gridLayout.setObjectName("gridLayout") |
|
22 |
self.groupBox = QtWidgets.QGroupBox(AttrEditorDialog) |
|
23 |
self.groupBox.setObjectName("groupBox") |
|
24 |
self.gridLayout_2 = QtWidgets.QGridLayout(self.groupBox) |
|
25 |
self.gridLayout_2.setObjectName("gridLayout_2") |
|
26 |
self.verticalLayout = QtWidgets.QVBoxLayout() |
|
27 |
self.verticalLayout.setObjectName("verticalLayout") |
|
28 |
self.horizontalLayout = QtWidgets.QHBoxLayout() |
|
29 |
self.horizontalLayout.setObjectName("horizontalLayout") |
|
30 |
self.comboBoxSymbolType = QtWidgets.QComboBox(self.groupBox) |
|
31 |
self.comboBoxSymbolType.setObjectName("comboBoxSymbolType") |
|
32 |
self.horizontalLayout.addWidget(self.comboBoxSymbolType) |
|
33 |
self.labelLineNo = QtWidgets.QLabel(self.groupBox) |
|
34 |
self.labelLineNo.setObjectName("labelLineNo") |
|
35 |
self.horizontalLayout.addWidget(self.labelLineNo) |
|
36 |
spacerItem = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) |
|
37 |
self.horizontalLayout.addItem(spacerItem) |
|
38 |
self.pushButtonAddAttr = QtWidgets.QPushButton(self.groupBox) |
|
39 |
self.pushButtonAddAttr.setMaximumSize(QtCore.QSize(24, 16777215)) |
|
40 |
self.pushButtonAddAttr.setObjectName("pushButtonAddAttr") |
|
41 |
self.horizontalLayout.addWidget(self.pushButtonAddAttr, 0, QtCore.Qt.AlignRight) |
|
42 |
self.pushButtonDelAttr = QtWidgets.QPushButton(self.groupBox) |
|
43 |
self.pushButtonDelAttr.setMaximumSize(QtCore.QSize(24, 16777215)) |
|
44 |
self.pushButtonDelAttr.setObjectName("pushButtonDelAttr") |
|
45 |
self.horizontalLayout.addWidget(self.pushButtonDelAttr, 0, QtCore.Qt.AlignRight) |
|
46 |
self.verticalLayout.addLayout(self.horizontalLayout) |
|
47 |
self.horizontalLayout_2 = QtWidgets.QHBoxLayout() |
|
48 |
self.horizontalLayout_2.setObjectName("horizontalLayout_2") |
|
49 |
self.verticalLayout.addLayout(self.horizontalLayout_2) |
|
50 |
self.gridLayout_2.addLayout(self.verticalLayout, 0, 0, 1, 1) |
|
51 |
self.gridLayout.addWidget(self.groupBox, 0, 0, 1, 1) |
|
52 |
self.buttonBox = QtWidgets.QDialogButtonBox(AttrEditorDialog) |
|
53 |
self.buttonBox.setOrientation(QtCore.Qt.Horizontal) |
|
54 |
self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Cancel|QtWidgets.QDialogButtonBox.Ok) |
|
55 |
self.buttonBox.setObjectName("buttonBox") |
|
56 |
self.gridLayout.addWidget(self.buttonBox, 1, 0, 1, 1) |
|
57 |
|
|
58 |
self.retranslateUi(AttrEditorDialog) |
|
59 |
self.buttonBox.accepted.connect(AttrEditorDialog.accept) |
|
60 |
self.buttonBox.rejected.connect(AttrEditorDialog.reject) |
|
61 |
QtCore.QMetaObject.connectSlotsByName(AttrEditorDialog) |
|
62 |
|
|
63 |
def retranslateUi(self, AttrEditorDialog): |
|
64 |
_translate = QtCore.QCoreApplication.translate |
|
65 |
AttrEditorDialog.setWindowTitle(_translate("AttrEditorDialog", "속성 편집")) |
|
66 |
self.groupBox.setTitle(_translate("AttrEditorDialog", "속성")) |
|
67 |
self.labelLineNo.setText(_translate("AttrEditorDialog", "Line No Attribute")) |
|
68 |
self.pushButtonAddAttr.setText(_translate("AttrEditorDialog", "+")) |
|
69 |
self.pushButtonDelAttr.setText(_translate("AttrEditorDialog", "-")) |
|
70 |
|
|
71 |
|
|
72 |
if __name__ == "__main__": |
|
73 |
import sys |
|
74 |
app = QtWidgets.QApplication(sys.argv) |
|
75 |
AttrEditorDialog = QtWidgets.QDialog() |
|
76 |
ui = Ui_AttrEditorDialog() |
|
77 |
ui.setupUi(AttrEditorDialog) |
|
78 |
AttrEditorDialog.show() |
|
79 |
sys.exit(app.exec_()) |
|
80 |
|
DTI_PID/DTI_PID/UI/AttrEditor.ui | ||
---|---|---|
1 |
<?xml version="1.0" encoding="UTF-8"?> |
|
2 |
<ui version="4.0"> |
|
3 |
<class>AttrEditorDialog</class> |
|
4 |
<widget class="QDialog" name="AttrEditorDialog"> |
|
5 |
<property name="geometry"> |
|
6 |
<rect> |
|
7 |
<x>0</x> |
|
8 |
<y>0</y> |
|
9 |
<width>825</width> |
|
10 |
<height>446</height> |
|
11 |
</rect> |
|
12 |
</property> |
|
13 |
<property name="font"> |
|
14 |
<font> |
|
15 |
<family>맑은 고딕</family> |
|
16 |
<weight>75</weight> |
|
17 |
<bold>true</bold> |
|
18 |
</font> |
|
19 |
</property> |
|
20 |
<property name="windowTitle"> |
|
21 |
<string>속성 편집</string> |
|
22 |
</property> |
|
23 |
<layout class="QGridLayout" name="gridLayout"> |
|
24 |
<item row="0" column="0"> |
|
25 |
<widget class="QGroupBox" name="groupBox"> |
|
26 |
<property name="title"> |
|
27 |
<string>속성</string> |
|
28 |
</property> |
|
29 |
<layout class="QGridLayout" name="gridLayout_2"> |
|
30 |
<item row="0" column="0"> |
|
31 |
<layout class="QVBoxLayout" name="verticalLayout"> |
|
32 |
<item> |
|
33 |
<layout class="QHBoxLayout" name="horizontalLayout"> |
|
34 |
<item> |
|
35 |
<widget class="QComboBox" name="comboBoxSymbolType"/> |
|
36 |
</item> |
|
37 |
<item> |
|
38 |
<widget class="QLabel" name="labelLineNo"> |
|
39 |
<property name="text"> |
|
40 |
<string>Line No Attribute</string> |
|
41 |
</property> |
|
42 |
</widget> |
|
43 |
</item> |
|
44 |
<item> |
|
45 |
<spacer name="horizontalSpacer"> |
|
46 |
<property name="orientation"> |
|
47 |
<enum>Qt::Horizontal</enum> |
|
48 |
</property> |
|
49 |
<property name="sizeHint" stdset="0"> |
|
50 |
<size> |
|
51 |
<width>40</width> |
|
52 |
<height>20</height> |
|
53 |
</size> |
|
54 |
</property> |
|
55 |
</spacer> |
|
56 |
</item> |
|
57 |
<item alignment="Qt::AlignRight"> |
|
58 |
<widget class="QPushButton" name="pushButtonAddAttr"> |
|
59 |
<property name="maximumSize"> |
|
60 |
<size> |
|
61 |
<width>24</width> |
|
62 |
<height>16777215</height> |
|
63 |
</size> |
|
64 |
</property> |
|
65 |
<property name="text"> |
|
66 |
<string>+</string> |
|
67 |
</property> |
|
68 |
</widget> |
|
69 |
</item> |
|
70 |
<item alignment="Qt::AlignRight"> |
|
71 |
<widget class="QPushButton" name="pushButtonDelAttr"> |
|
72 |
<property name="maximumSize"> |
|
73 |
<size> |
|
74 |
<width>24</width> |
|
75 |
<height>16777215</height> |
|
76 |
</size> |
|
77 |
</property> |
|
78 |
<property name="text"> |
|
79 |
<string>-</string> |
|
80 |
</property> |
|
81 |
</widget> |
|
82 |
</item> |
|
83 |
</layout> |
|
84 |
</item> |
|
85 |
<item> |
|
86 |
<layout class="QHBoxLayout" name="horizontalLayout_2"/> |
|
87 |
</item> |
|
88 |
</layout> |
|
89 |
</item> |
|
90 |
</layout> |
|
91 |
</widget> |
|
92 |
</item> |
|
93 |
<item row="1" column="0"> |
|
94 |
<widget class="QDialogButtonBox" name="buttonBox"> |
|
95 |
<property name="orientation"> |
|
96 |
<enum>Qt::Horizontal</enum> |
|
97 |
</property> |
|
98 |
<property name="standardButtons"> |
|
99 |
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set> |
|
100 |
</property> |
|
101 |
</widget> |
|
102 |
</item> |
|
103 |
</layout> |
|
104 |
</widget> |
|
105 |
<resources/> |
|
106 |
<connections> |
|
107 |
<connection> |
|
108 |
<sender>buttonBox</sender> |
|
109 |
<signal>accepted()</signal> |
|
110 |
<receiver>AttrEditorDialog</receiver> |
|
111 |
<slot>accept()</slot> |
|
112 |
<hints> |
|
113 |
<hint type="sourcelabel"> |
|
114 |
<x>248</x> |
|
115 |
<y>254</y> |
|
116 |
</hint> |
|
117 |
<hint type="destinationlabel"> |
|
118 |
<x>157</x> |
|
119 |
<y>274</y> |
|
120 |
</hint> |
|
121 |
</hints> |
|
122 |
</connection> |
|
123 |
<connection> |
|
124 |
<sender>buttonBox</sender> |
|
125 |
<signal>rejected()</signal> |
|
126 |
<receiver>AttrEditorDialog</receiver> |
|
127 |
<slot>reject()</slot> |
|
128 |
<hints> |
|
129 |
<hint type="sourcelabel"> |
|
130 |
<x>316</x> |
|
131 |
<y>260</y> |
|
132 |
</hint> |
|
133 |
<hint type="destinationlabel"> |
|
134 |
<x>286</x> |
|
135 |
<y>274</y> |
|
136 |
</hint> |
|
137 |
</hints> |
|
138 |
</connection> |
|
139 |
</connections> |
|
140 |
</ui> |
DTI_PID/DTI_PID/UI/SymbolAttrEditor.ui | ||
---|---|---|
1 |
<?xml version="1.0" encoding="UTF-8"?> |
|
2 |
<ui version="4.0"> |
|
3 |
<class>SymbolAttrEditorDialog</class> |
|
4 |
<widget class="QDialog" name="SymbolAttrEditorDialog"> |
|
5 |
<property name="geometry"> |
|
6 |
<rect> |
|
7 |
<x>0</x> |
|
8 |
<y>0</y> |
|
9 |
<width>825</width> |
|
10 |
<height>446</height> |
|
11 |
</rect> |
|
12 |
</property> |
|
13 |
<property name="font"> |
|
14 |
<font> |
|
15 |
<family>맑은 고딕</family> |
|
16 |
<weight>75</weight> |
|
17 |
<bold>true</bold> |
|
18 |
</font> |
|
19 |
</property> |
|
20 |
<property name="windowTitle"> |
|
21 |
<string>속성 편집</string> |
|
22 |
</property> |
|
23 |
<layout class="QGridLayout" name="gridLayout"> |
|
24 |
<item row="0" column="0"> |
|
25 |
<widget class="QGroupBox" name="groupBox"> |
|
26 |
<property name="title"> |
|
27 |
<string>속성</string> |
|
28 |
</property> |
|
29 |
<layout class="QGridLayout" name="gridLayout_2"> |
|
30 |
<item row="0" column="0"> |
|
31 |
<layout class="QVBoxLayout" name="verticalLayout"> |
|
32 |
<item> |
|
33 |
<layout class="QHBoxLayout" name="horizontalLayout"> |
|
34 |
<item> |
|
35 |
<widget class="QComboBox" name="comboBoxSymbolType"/> |
|
36 |
</item> |
|
37 |
<item> |
|
38 |
<widget class="QLabel" name="labelLineNo"> |
|
39 |
<property name="text"> |
|
40 |
<string>Line No Attribute</string> |
|
41 |
</property> |
|
42 |
</widget> |
|
43 |
</item> |
|
44 |
<item> |
|
45 |
<spacer name="horizontalSpacer"> |
|
46 |
<property name="orientation"> |
|
47 |
<enum>Qt::Horizontal</enum> |
|
48 |
</property> |
|
49 |
<property name="sizeHint" stdset="0"> |
|
50 |
<size> |
|
51 |
<width>40</width> |
|
52 |
<height>20</height> |
|
53 |
</size> |
|
54 |
</property> |
|
55 |
</spacer> |
|
56 |
</item> |
|
57 |
<item alignment="Qt::AlignRight"> |
|
58 |
<widget class="QPushButton" name="pushButtonAddAttr"> |
|
59 |
<property name="maximumSize"> |
|
60 |
<size> |
|
61 |
<width>24</width> |
|
62 |
<height>16777215</height> |
|
63 |
</size> |
|
64 |
</property> |
|
65 |
<property name="text"> |
|
66 |
<string>+</string> |
|
67 |
</property> |
|
68 |
</widget> |
|
69 |
</item> |
|
70 |
<item alignment="Qt::AlignRight"> |
|
71 |
<widget class="QPushButton" name="pushButtonDelAttr"> |
|
72 |
<property name="maximumSize"> |
|
73 |
<size> |
|
74 |
<width>24</width> |
|
75 |
<height>16777215</height> |
|
76 |
</size> |
|
77 |
</property> |
|
78 |
<property name="text"> |
|
79 |
<string>-</string> |
|
80 |
</property> |
|
81 |
</widget> |
|
82 |
</item> |
|
83 |
</layout> |
|
84 |
</item> |
|
85 |
<item> |
|
86 |
<layout class="QHBoxLayout" name="horizontalLayout_2"/> |
|
87 |
</item> |
|
88 |
</layout> |
|
89 |
</item> |
|
90 |
</layout> |
|
91 |
</widget> |
|
92 |
</item> |
|
93 |
<item row="1" column="0"> |
|
94 |
<widget class="QDialogButtonBox" name="buttonBox"> |
|
95 |
<property name="orientation"> |
|
96 |
<enum>Qt::Horizontal</enum> |
|
97 |
</property> |
|
98 |
<property name="standardButtons"> |
|
99 |
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set> |
|
100 |
</property> |
|
101 |
</widget> |
|
102 |
</item> |
|
103 |
</layout> |
|
104 |
</widget> |
|
105 |
<resources/> |
|
106 |
<connections> |
|
107 |
<connection> |
|
108 |
<sender>buttonBox</sender> |
|
109 |
<signal>accepted()</signal> |
|
110 |
<receiver>SymbolAttrEditorDialog</receiver> |
|
111 |
<slot>accept()</slot> |
|
112 |
<hints> |
|
113 |
<hint type="sourcelabel"> |
|
114 |
<x>248</x> |
|
115 |
<y>254</y> |
|
116 |
</hint> |
|
117 |
<hint type="destinationlabel"> |
|
118 |
<x>157</x> |
|
119 |
<y>274</y> |
|
120 |
</hint> |
|
121 |
</hints> |
|
122 |
</connection> |
|
123 |
<connection> |
|
124 |
<sender>buttonBox</sender> |
|
125 |
<signal>rejected()</signal> |
|
126 |
<receiver>SymbolAttrEditorDialog</receiver> |
|
127 |
<slot>reject()</slot> |
|
128 |
<hints> |
|
129 |
<hint type="sourcelabel"> |
|
130 |
<x>316</x> |
|
131 |
<y>260</y> |
|
132 |
</hint> |
|
133 |
<hint type="destinationlabel"> |
|
134 |
<x>286</x> |
|
135 |
<y>274</y> |
|
136 |
</hint> |
|
137 |
</hints> |
|
138 |
</connection> |
|
139 |
</connections> |
|
140 |
</ui> |
내보내기 Unified diff