개정판 9133d5d8
dev issue #683: 2개의 심볼 모델링
DTI_PID/SPPIDConverter/AutoModeling.vb | ||
---|---|---|
143 | 143 |
End If |
144 | 144 |
SetListBoxItems(ListBox_Result, "Create Symbol (" + sCnt.ToString + "/" + CDrawing.SYMBOLS.Count.ToString + ") UID : " + symbol.UID) |
145 | 145 |
sCnt += 1 |
146 |
symbol.SPPID_ITEM_OBJECT = DrawSymbol(symbol)
|
|
146 |
symbol.Modeling()
|
|
147 | 147 |
If symbol.SPPID_ITEM_OBJECT IsNot Nothing Then |
148 | 148 |
prevSymbol = symbol |
149 | 149 |
prevIndex = index |
... | ... | |
742 | 742 |
|
743 | 743 |
If sysPath <> "" Then |
744 | 744 |
Dim connectSymbol As LMSymbol = Nothing |
745 |
|
|
746 | 745 |
For Each connector As Connector In symbol.CONNECTORS |
747 | 746 |
If String.IsNullOrEmpty(connector.CONNECTEDITEM) = False Or connector.CONNECTEDITEM <> "None" Then |
748 | 747 |
Dim _sym As Symbol = FindSymbolByUID(CDrawing.SYMBOLS, connector.CONNECTEDITEM) |
... | ... | |
754 | 753 |
End If |
755 | 754 |
End If |
756 | 755 |
Next |
757 |
|
|
758 | 756 |
If connectSymbol IsNot Nothing Then |
759 | 757 |
_lmSymbol = _Placement.PIDPlaceSymbol(sysPath, symbol.LOCATION_X, symbol.LOCATION_Y, Rotation:=symbol.ANGLE, Mirror:=symbol.MIRROR, TargetItem:=connectSymbol) |
760 | 758 |
Else |
761 | 759 |
_lmSymbol = _Placement.PIDPlaceSymbol(sysPath, symbol.LOCATION_X, symbol.LOCATION_Y, Rotation:=symbol.ANGLE, Mirror:=symbol.MIRROR) |
762 | 760 |
End If |
763 |
|
|
764 | 761 |
_lmSymbol.Commit() |
762 |
|
|
763 |
'' Check Child |
|
764 |
For Each _child As String In symbol.CHILD |
|
765 |
Dim arrChild As String() = _child.Split(",") |
|
766 |
Dim arrow As String = arrChild(0) |
|
767 |
Dim mappingName As String = arrChild(1) |
|
768 |
|
|
769 |
Dim childAngle = 0 |
|
770 |
If arrow = "UP" Then |
|
771 |
childAngle = 0 |
|
772 |
ElseIf arrow = "RIGHT" Then |
|
773 |
childAngle = 90 |
|
774 |
ElseIf arrow = "DOWN" Then |
|
775 |
childAngle = 180 |
|
776 |
Else |
|
777 |
childAngle = 270 |
|
778 |
End If |
|
779 |
|
|
780 |
Dim _childLmSymbol As LMSymbol = _Placement.PIDPlaceSymbol(mappingName, symbol.LOCATION_X, symbol.LOCATION_Y, Rotation:=childAngle, TargetItem:=_lmSymbol) |
|
781 |
symbol.CHILD_SPPID_ITEM_OBJECT.Add(_childLmSymbol) |
|
782 |
Next |
|
783 |
|
|
765 | 784 |
Debug.WriteLine(symbol.LOCATION_X.ToString + "," + symbol.LOCATION_Y.ToString + "/" + symbol.UID + "/" + symbol.SIZE) |
766 | 785 |
End If |
767 | 786 |
|
내보내기 Unified diff