Compare commits

..

2 Commits

Author SHA1 Message Date
Demetrio Cassarino 9f91bafd59 -modifica grafica gradiente colore 2024-04-15 16:06:30 +02:00
Demetrio Cassarino 38fbdc08dc Merge remote-tracking branch 'origin/HEAD' into feature/Manage_Color_Style 2024-04-15 09:41:59 +02:00
68 changed files with 1246 additions and 1997 deletions
+1 -1
View File
@@ -146,7 +146,7 @@ Public Class CompoWindowVM
Friend Function MakePreview(ByRef sMsg As String) As Boolean
If Not EgtLuaExecLine(LUA_CMP_DRAW & "(true)") Then
sMsg = EgtMsg(91689) ' Error in component execution
sMsg = "Error in component execution"
m_bDrawOk = False
Else
EgtLuaGetGlobStringVar(LUA_CMP_VARS & ".MSG", sMsg)
-2
View File
@@ -77,7 +77,5 @@ Module ConstGen
Public Const SETUP_LUA As String = "SetUp.lua"
' Sottodirettorio per BackUp
Public Const BACKUP_DIR As String = "BackUp"
' Info per rotazione in registrazione grezzo
Public Const INFO_REGROT As String = "RegRot"
End Module
-2
View File
@@ -37,7 +37,6 @@ Module ConstIni
Public Const K_CONTOURFROMCAMERA As String = "ContourFromCamera"
Public Const K_SUPPORT As String = "Support"
Public Const K_PHOTODIR As String = "PhotoDir"
Public Const K_SHOWNBARROW As String = "ShowNbArrow"
Public Const S_LANGUAGES As String = "Languages"
Public Const K_LANGUAGE As String = "Language"
@@ -97,7 +96,6 @@ Module ConstIni
Public Const S_SIDES As String = "Sides"
Public Const K_MAXSIDEANGLE As String = "MaxSideAngle"
Public Const K_SIZEALWAYSONTOP As String = "SizeAlwaysOnTop"
Public Const K_PARSIDE_AS_TRF As String = "ParSideAsTrf"
Public Const K_SIDEANGLE As String = "SideAngle"
Public Const K_DELTA_ANG_TG As String = "DeltaAngTg"
+3 -3
View File
@@ -13,10 +13,10 @@
MaxWidth="500"
ResizeMode="NoResize">
<DockPanel Margin="5,5,5,0" Background="{StaticResource Omag_DarkGray}">
<DockPanel Margin="5,5,5,0" Background="{StaticResource Gradient_Gray}">
<!--Background="{StaticResource Omag_DarkGray}"-->
<UniformGrid Columns="15"
<UniformGrid Columns="15"
DockPanel.Dock="Top"
Margin="0,0,0,5">
<Button Command="{Binding NewCommand}"
+10 -71
View File
@@ -1,6 +1,5 @@
Imports System.Security.Cryptography
Imports EgtUILib
Imports EgtWPFLib5
Friend Module CamAuto
@@ -26,12 +25,9 @@ Friend Module CamAuto
bOk = bOk AndAlso EgtLuaCallFunction("CAM.Add")
EgtLuaGetGlobIntVar("CAM.ERR", nErr)
EgtLuaResetGlobVar("CAM")
If nErr > 0 Then
If nErr <> 0 Then
bOk = False
EgtOutLog("Error in CamAuto : " & nErr.ToString())
ElseIf nErr < 0 Then
EgtOutLog("Warning in CamAuto : " & nErr.ToString())
OmagOFFICEMap.refStatusBarVM.SetOutputMessage(EgtMsg(91017), MSG_TYPE.WARNING)
End If
ResetOrderMachiningFlag()
Return bOk
@@ -47,34 +43,9 @@ Friend Module CamAuto
bOk = bOk AndAlso EgtLuaCallFunction("CAM.AddWaterJet")
EgtLuaGetGlobIntVar("CAM.ERR", nErr)
EgtLuaResetGlobVar("CAM")
If nErr > 0 Then
If nErr <> 0 Then
bOk = False
EgtOutLog("Error in CamAuto : " & nErr.ToString())
' m_MainWindow.m_CurrentProjectPageUC.ClearMessage()
ElseIf nErr < 0 Then
EgtOutLog("Warning in CamAuto : " & nErr.ToString())
End If
Return bOk
End Function
' versione CamAuto 2.6l1: gestione tagli con ridotto affondamento
Friend Function AddWaterJetMachining(LocaList As List(Of Integer), ByRef nWarn As Integer) As Boolean
EgtLuaCreateGlobTable("CAM")
SetLuaStandardCamParams()
For i As Integer = 0 To LocaList.Count - 1
EgtLuaSetGlobIntVar("CAM.TAB_OPERID." & (i + 1).ToString, LocaList(i))
Next
Dim nErr As Integer = 999
Dim bOk As Boolean = EgtLuaExecFile(m_sCamAutoDir & "\CamAuto.lua")
bOk = bOk AndAlso EgtLuaGetGlobIntVar("CAM.ERR", nErr) AndAlso nErr = 0
bOk = bOk AndAlso EgtLuaCallFunction("CAM.AddWaterJets")
EgtLuaGetGlobIntVar("CAM.ERR", nErr)
EgtLuaResetGlobVar("CAM")
If nErr > 0 Then
bOk = False
EgtOutLog("Error in CamAuto : " & nErr.ToString())
ElseIf nErr < 0 Then
EgtOutLog("Warning in CamAuto : " & nErr.ToString())
End If
Return bOk
End Function
@@ -88,11 +59,9 @@ Friend Module CamAuto
bOk = bOk AndAlso EgtLuaCallFunction("CAM.Erase")
EgtLuaGetGlobIntVar("CAM.ERR", nErr)
EgtLuaResetGlobVar("CAM")
If nErr > 0 Then
If nErr <> 0 Then
bOk = False
EgtOutLog("Error in CamAuto : " & nErr.ToString())
ElseIf nErr < 0 Then
EgtOutLog("Warning in CamAuto : " & nErr.ToString())
End If
ResetOrderMachiningFlag()
Return bOk
@@ -107,11 +76,9 @@ Friend Module CamAuto
bOk = bOk AndAlso EgtLuaCallFunction("CAM.InvertVerticalCut")
EgtLuaGetGlobIntVar("CAM.ERR", nErr)
EgtLuaResetGlobVar("CAM")
If nErr > 0 Then
If nErr <> 0 Then
bOk = False
EgtOutLog("Error in CamAuto : " & nErr.ToString())
ElseIf nErr < 0 Then
EgtOutLog("Warning in CamAuto : " & nErr.ToString())
End If
Return bOk
End Function
@@ -122,7 +89,6 @@ Friend Module CamAuto
End Function
Friend Function ResetAllMachinings(ByRef nWarn As Integer) As Boolean
EgtOutLog(" ++ ReserAllMachining ++ ")
' Cancello tutte le lavorazioni
EraseMachinings(GDB_ID.NULL)
' Reinserisco tutte le lavorazioni piane (non sono previste le lavorazioni delle cornici)
@@ -307,11 +273,9 @@ Friend Module CamAuto
bOk = bOk AndAlso EgtLuaCallFunction("CAM.UpdateAllTp")
EgtLuaGetGlobIntVar("CAM.ERR", nErr)
EgtLuaResetGlobVar("CAM")
If nErr > 0 Then
If nErr <> 0 Then
bOk = False
EgtOutLog("Error in CamAuto : " & nErr.ToString())
ElseIf nErr < 0 Then
EgtOutLog("Warning in CamAuto : " & nErr.ToString())
End If
Return bOk
End Function
@@ -325,11 +289,9 @@ Friend Module CamAuto
bOk = bOk AndAlso EgtLuaCallFunction("CAM.Sort")
EgtLuaGetGlobIntVar("CAM.ERR", nErr)
EgtLuaResetGlobVar("CAM")
If nErr > 0 Then
If nErr <> 0 Then
bOk = False
EgtOutLog("Error in CamAuto : " & nErr.ToString())
ElseIf nErr < 0 Then
EgtOutLog("Warning in CamAuto : " & nErr.ToString())
End If
Return bOk
End Function
@@ -344,11 +306,9 @@ Friend Module CamAuto
bOk = bOk AndAlso EgtLuaCallFunction("CAM.SpecApplyDisp")
EgtLuaGetGlobIntVar("CAM.ERR", nErr)
EgtLuaResetGlobVar("CAM")
If nErr > 0 Then
If nErr <> 0 Then
bOk = False
EgtOutLog("Error in CamAuto : " & nErr.ToString())
ElseIf nErr < 0 Then
EgtOutLog("Warning in CamAuto : " & nErr.ToString())
End If
If ResetOrderMachiningFlag() Then
ResetOrderMachiningFlag()
@@ -491,7 +451,6 @@ Friend Module CamAuto
Return EgtRemoveOperationHome(nId)
End Function
' DA AGGIORNARE PER CAMBIO UTENSILE LAMA
Friend Function VerifySetup(ByRef sMissingTools As String) As Boolean
Dim bOk As Boolean = True
Dim bIsMultiCut = (EgtGetHeadId("H101") <> GDB_ID.NULL)
@@ -586,7 +545,6 @@ Friend Module CamAuto
Dim dReducedDepth As Double = GetPrivateProfileDouble(S_MACH_NEST, K_MACH_REDUCEDDEPTH, 1, CurrentMachine.sMachIniFile)
' Ciclo sulle lavorazioni
Dim nOperId As Integer = EgtGetFirstOperation()
Dim LocalListOperId As New List(Of Integer)
While nOperId <> GDB_ID.NULL
' verifico sia una lavorazione valida di taglio con lama
If IsValidMachining(nOperId) And EgtGetOperationType(nOperId) = MCH_OY.SAWING Then
@@ -601,14 +559,12 @@ Friend Module CamAuto
' se abilitato e attivo waterjet, lo aggiungo per completare il taglio
If CurrentMachine.WaterJettingActive Then
Dim nWarn As Integer = 0
LocalListOperId.Add(nOperId)
'AddWaterJetMachining(nOperId, nWarn)
AddWaterJetMachining(nOperId, nWarn)
End If
End If
End If
nOperId = EgtGetNextOperation(nOperId)
End While
If LocalListOperId.Count > 0 Then AddWaterJetMachining(LocalListOperId, 0)
Return bModified
End Function
@@ -903,7 +859,6 @@ Friend Module CamAuto
Private Function SetLuaStandardCamParams(Optional bDripOk As Boolean = True) As Boolean
Dim sMaterial As String = CurrentMachine.CurrMat.sName
Dim sSawMch As String = CurrentMachine.sCurrSawing
Dim sSawTiltedMch As String = CurrentMachine.sCurrSawingTilted
Dim sMillMch As String = CurrentMachine.sCurrMilling
Dim sDrillMch As String = CurrentMachine.sCurrDrilling
Dim sWaterJetMch As String = CurrentMachine.sCurrWaterJetting
@@ -921,7 +876,6 @@ Friend Module CamAuto
Dim dMillingShort As Double = GetPrivateProfileDouble(S_MACH_NEST, K_MACH_MILLING_SHORTENING, 0, CurrentMachine.sMachIniFile)
EgtLuaSetGlobStringVar("CAM.MATERIAL", sMaterial)
EgtLuaSetGlobStringVar("CAM.SAWMCH", sSawMch)
EgtLuaSetGlobStringVar("CAM.SAWTILTEDMCH", sSawTiltedMch)
EgtLuaSetGlobStringVar("CAM.MILLMCH", sMillMch)
EgtLuaSetGlobStringVar("CAM.DRILLMCH", sDrillMch)
EgtLuaSetGlobStringVar("CAM.WATERJETMCH", sWaterJetMch)
@@ -942,29 +896,24 @@ Friend Module CamAuto
Return True
End Function
' ver. 2.7f1
Friend Function GetTableCount() As Integer
If EgtGetTableId(MAIN_TAB) = GDB_ID.NULL Then Return 0
If EgtGetTableId(SECOND_TAB) = GDB_ID.NULL Then Return 1
If EgtGetTableId(THIRD_TAB) = GDB_ID.NULL Then Return 2
If EgtGetTableId(FORTH_TAB) = GDB_ID.NULL Then Return 3
Return 4
Return 3
End Function
Friend Function GetTableName(nInd As Integer) As String
If nInd = 1 Then Return MAIN_TAB
If nInd = 2 Then Return SECOND_TAB
If nInd = 3 Then Return THIRD_TAB
If nInd = 4 Then Return FORTH_TAB
Return ""
End Function
Friend Function GetCurrentTable() As Integer
Dim sTabName As String = MAIN_TAB
EgtGetTableName(sTabName)
If sTabName = FORTH_TAB Then
Return 4
ElseIf sTabName = THIRD_TAB Then
If sTabName = THIRD_TAB Then
Return 3
ElseIf sTabName = SECOND_TAB Then
Return 2
@@ -1444,14 +1393,4 @@ Friend Module CamAuto
Return EgtApplyMachining(False)
End Function
Friend Function GetRegistrationRotation() As Double
Dim dRegRot As Double = 0
EgtGetInfo(GetCurrentRaw(), INFO_REGROT, dRegRot)
Return dRegRot
End Function
Friend Function SetRegistrationRotation(dRegRot As Double) As Boolean
Return EgtSetInfo(GetCurrentRaw(), INFO_REGROT, dRegRot)
End Function
End Module
-2
View File
@@ -48,7 +48,6 @@ Module ConstMach
Public Const MAIN_TAB As String = "MainTab"
Public Const SECOND_TAB As String = "2ndTab"
Public Const THIRD_TAB As String = "3rdTab"
Public Const FORTH_TAB As String = "4thTab"
' Nome tavola ausiliaria per spostamento finale pezzi
Public Const AUX_TAB As String = "AuxTab"
@@ -167,7 +166,6 @@ Module ConstMach
' Info in entità da tagliare per affondamento
Public Const INFO_DEPTH As String = "Depth"
Public Const INFO_DEPTH2 As String = "Depth2"
Public Const INFO_AGG2 As String = "Agg2"
Public Const INFO_WIDTH As String = "Width"
' Info in entità da tagliare per taglio ristretto
Public Const INFO_STRICT As String = "Strict"
-3
View File
@@ -122,7 +122,6 @@
Public Const K_TAB2_ADDITIONALTABLE As String = "Tab2AdditionalTable"
Public Const K_TAB3_ADDITIONALTABLE As String = "Tab3AdditionalTable"
Public Const K_CENTER_RAW_ONX As String = "CenterRawOnX"
Public Const K_CHANGETABWD As String = "ChangeTabWD"
Public Const S_PHOTO As String = "Photo"
Public Const K_PHOTO_OFFSETX As String = "OffsetX"
@@ -241,7 +240,6 @@
Public Const S_MACH_MACH As String = "Mach"
Public Const K_CURRSAW As String = "CurrSaw"
Public Const K_CURRSAWTILTED As String = "CurrSawTilted"
Public Const K_CURRDRILL As String = "CurrDrill"
Public Const K_CURRMILL As String = "CurrMill"
Public Const K_CURRMILLNOTIP As String = "CurrMillNoTip"
@@ -249,7 +247,6 @@
Public Const K_CURRDRIPDRILL As String = "CurrDripDrill"
Public Const K_CURRWATERJET As String = "CurrWaterJet"
Public Const K_CURRSAWING As String = "CurrSawing"
Public Const K_CURRSAWINGTILTED As String = "CurrSawingTilted"
Public Const K_CURRSAWING_OFFICE As String = "CurrOfficeSawing"
Public Const K_CURRDRILLING As String = "CurrDrilling"
Public Const K_CURRDRILLING_OFFICE As String = "CurrOfficeDrilling"
-23
View File
@@ -107,7 +107,6 @@ Public Module CurrentMachine
' Variabili che contengono il nome degli utensili disponibili per tipo
Private m_sCurrSaw As String = String.Empty
Private m_sCurrSawTilted As String = String.Empty
Private m_sCurrDrill As String = String.Empty
Private m_sCurrMill As String = String.Empty
Private m_sCurrMillNoTip As String = String.Empty
@@ -117,7 +116,6 @@ Public Module CurrentMachine
' Variabili che contengono le lavorazioni correntemente attive (utilizzate per definire lavorazioni nel programma)
Private m_sCurrSawing As String = String.Empty
Private m_sCurrSawingTilted As String = String.Empty
Private m_sCurrDrilling As String = String.Empty
Private m_sCurrMilling As String = String.Empty
Private m_sCurrPocketing As String = String.Empty
@@ -733,18 +731,6 @@ Friend Property sCurrMillNoTip As String
End Set
End Property
Friend Property sCurrSawingTilted As String
Get
Return m_sCurrSawingTilted
End Get
Set(value As String)
If WritePrivateProfileString(S_MACH_MACH, K_CURRSAWINGTILTED, value, sMachIniFile) Then
m_sCurrSawingTilted = value
'm_MainWindow.m_CurrentProjectPageUC.MachiningTxBx.Text = value
End If
End Set
End Property
Friend Property sCurrDrilling As String
Get
Return m_sCurrDrilling
@@ -1284,13 +1270,6 @@ Friend Property sCurrMillNoTip As String
' Leggo utensili correnti
' lama
GetPrivateProfileString(S_MACH_MACH, K_CURRSAW, Nothing, m_sCurrSaw, sMachIniFile)
' lama inclinata
If m_nShowToolChanger = 4 Then
GetPrivateProfileString(S_MACH_MACH, K_CURRSAWTILTED, Nothing, m_sCurrSawTilted, sMachIniFile)
Else
' se non è configurato il cambio utensile e allora imposto l'unica lama disponibile per i tagli inclinati
m_sCurrSawTilted = m_sCurrSaw
End If
' foretto
GetPrivateProfileString(S_MACH_MACH, K_CURRDRILL, Nothing, m_sCurrDrill, sMachIniFile)
' fresa
@@ -1307,8 +1286,6 @@ Friend Property sCurrMillNoTip As String
' Leggo lavorazioni correnti
' lama
m_sCurrSawing = EstCalc.GetCurrSawing()
' lama inlicnata
m_sCurrSawingTilted = EstCalc.GetCurrSawingTilted()
' foretto
m_sCurrDrilling = EstCalc.GetCurrDrilling()
' fresa
+22 -69
View File
@@ -258,14 +258,6 @@ Module EstCalc
Return sCurrSawing
End Function
Friend Function GetCurrSawingTilted() As String
Dim nOperId As Integer = EgtGetFirstNameInGroup(EgtGetCurrMachGroup(), "Opers")
If nOperId = GDB_ID.NULL Then Return ""
Dim sCurrSawing As String = String.Empty
EgtGetInfo(nOperId, INFO_CURRSAWING, sCurrSawing)
Return sCurrSawing
End Function
Friend Function SetCurrMilling(sCurrMilling As String) As Boolean
Dim nOperId As Integer = EgtGetFirstNameInGroup(EgtGetCurrMachGroup(), "Opers")
If nOperId = GDB_ID.NULL Then Return False
@@ -340,7 +332,7 @@ Module EstCalc
Return (nFlag <> 0)
End Function
Public Function AdjustAdditionalTable(Optional bForced As Boolean = False) As Boolean
Public Function AdjustAdditionalTable() As Boolean
' Recupero altezza sottotavola corrente
Dim nFixtId As Integer = EgtGetFirstNameInGroup(EgtGetCurrMachGroup(), MACH_FIXT_GROUP)
Dim nAddTabId As Integer = EgtGetFirstNameInGroup(nFixtId, MACH_ADD_TABLE)
@@ -351,27 +343,18 @@ Module EstCalc
dCurrAddTab = b3AddTab.DimZ()
End If
' Se valore cambiato, aggiorno...
Dim dDeltaZ As Double = CurrentMachine.dAdditionalTable - dCurrAddTab
Dim bChanged As Boolean = (Math.Abs(dDeltaZ) > EPS_SMALL)
If bChanged Or bForced Then
Dim bOldEnMod As Boolean = EgtGetEnableModified()
If Not bChanged AndAlso bOldEnMod Then EgtDisableModified()
Dim dDeltaZ As Double = dAdditionalTable - dCurrAddTab
If Math.Abs(dDeltaZ) > EPS_SMALL Then
AddAdditionalTable()
UpdateAllRawsZ(dDeltaZ)
If GetPhoto() <> GDB_ID.NULL Then
UpdatePhoto()
UpdateContour()
If EgtGetRawPartCount() > 0 Then
ShowPhoto(False)
Dim nRawGrpId As Integer = EgtGetFirstRawPart()
While nRawGrpId <> GDB_ID.NULL
Dim nRawSolidId As Integer = EgtGetFirstNameInGroup(nRawGrpId, NAME_RAW_SOLID)
If nRawSolidId <> GDB_ID.NULL Then EgtSetTextureName(nRawSolidId, GetPhotoName())
nRawGrpId = EgtGetNextRawPart(nRawGrpId)
End While
End If
End If
If Not bChanged AndAlso bOldEnMod Then EgtEnableModified()
' !!! FOTO DA GESTIRE !!!
'If GetPhoto() <> GDB_ID.NULL Then
' UpdatePhoto()
' UpdateContour()
' If EgtGetRawPartCount() > 0 Then
' ShowPhoto(False)
' End If
'End If
End If
Return True
End Function
@@ -743,65 +726,49 @@ Module EstCalc
nLayId = EgtGetNextName(nLayId, NAME_INLOOP)
End While
' Aggiorno le entità con tallone e quelle con angolo esterno
Const AGG_DEPTH As Double = 0.75
Dim bSizeOnTop As Boolean = (GetMainPrivateProfileInt(S_SIDES, K_SIZEALWAYSONTOP, 0) <> 0)
Const AGG_DEPTH As Double = 2.0
For Each nEnt As Integer In vEnt
' Se aggiornamento vietato, vado oltre
If EgtExistsInfo(nEnt, INFO_SIDE_FIXED) Then Continue For
If EgtExistsInfo( nEnt, INFO_SIDE_FIXED) Then continue for
' Recupero eventuali tallone ed angolo originale
Dim dHeel As Double = 0
Dim dSideAng As Double = 0
EgtGetInfo(nEnt, INFO_HEEL, dHeel)
EgtGetInfo(nEnt, INFO_ORIG_SIDE_ANGLE, dSideAng)
' Se inclinazione con tallone
If Math.Abs(dSideAng) > EPS_ANG_SMALL And dHeel > 10 * EPS_SMALL Then
' Inclinazione esterna
' Angolo esterno
If dSideAng > 0 Then
' Se tallone inferiore a spessore
If dHeel < dTh - 10 * EPS_SMALL Then
EgtSetInfo(nEnt, INFO_SIDE_ANGLE, 0.0)
EgtSetInfo(nEnt, INFO_SIDE_ANGLE2, dSideAng)
If Not bSizeOnTop Then
EgtSetInfo(nEnt, INFO_OFFSET, 0)
EgtSetInfo(nEnt, INFO_OFFSET2, -(dTh - dHeel) * Math.Tan(dSideAng * Math.PI / 180))
Else
EgtSetInfo(nEnt, INFO_OFFSET, (dTh - dHeel) * Math.Tan(dSideAng * Math.PI / 180))
EgtSetInfo(nEnt, INFO_OFFSET2, 0)
End If
EgtSetInfo(nEnt, INFO_OFFSET2, -(dTh - dHeel) * Math.Tan(dSideAng * Math.PI / 180))
EgtSetInfo(nEnt, INFO_DEPTH2, (dTh - dHeel) + AGG_DEPTH)
EgtSetInfo(nEnt, INFO_AGG2, AGG_DEPTH)
' altrimenti, tallone superiore a spessore -> non c'è taglio inclinato
' altrimenti, tallone superiore a spessore -> non c'è taglio inclinato
Else
EgtSetInfo(nEnt, INFO_SIDE_ANGLE, 0.0)
EgtSetInfo(nEnt, INFO_SIDE_ANGLE2, 0.0)
EgtRemoveInfo(nEnt, INFO_OFFSET2)
EgtRemoveInfo(nEnt, INFO_DEPTH2)
EgtRemoveInfo(nEnt, INFO_AGG2)
End If
' Inclinazione interna
' Angolo interno
Else
' Se tallone inferiore a spessore
If dHeel < dTh - 10 * EPS_SMALL Then
EgtSetInfo(nEnt, INFO_OFFSET, dHeel * Math.Tan(-dSideAng * Math.PI / 180))
EgtSetInfo(nEnt, INFO_SIDE_ANGLE2, 0.0)
EgtSetInfo(nEnt, INFO_DEPTH2, dHeel + AGG_DEPTH)
EgtSetInfo(nEnt, INFO_AGG2, AGG_DEPTH)
' altrimenti, tallone superiore a spessore -> non c'è taglio inclinato
' altrimenti, tallone superiore a spessore -> non c'è taglio inclinato
Else
EgtSetInfo(nEnt, INFO_SIDE_ANGLE, 0.0)
EgtRemoveInfo(nEnt, INFO_OFFSET)
EgtRemoveInfo(nEnt, INFO_SIDE_ANGLE2)
EgtRemoveInfo(nEnt, INFO_DEPTH2)
EgtRemoveInfo(nEnt, INFO_AGG2)
End If
End If
' Se altrimenti inclinazione esterna
' Se altrimenti inclinazione esterna
ElseIf dSideAng > EPS_ANG_SMALL Then
If Not bSizeOnTop Then
EgtSetInfo(nEnt, INFO_OFFSET, -dTh * Math.Tan(dSideAng * Math.PI / 180))
Else
EgtSetInfo(nEnt, INFO_OFFSET, 0)
End If
EgtSetInfo(nEnt, INFO_OFFSET, -dTh * Math.Tan(dSideAng * Math.PI / 180))
End If
Next
Return True
@@ -1023,22 +990,8 @@ Module EstCalc
Const STORE_DIST As Double = 200
' 40 il Font usato per indicare il numero di pezzi in parcheggio "# N"
Const STORE_OFFS As Double = 20 + 40 + 20
Dim dStoreLarg As Double = GetPrivateProfileDouble("Store", "StoreLargh", STORE_LARGH, CurrentMachine.sMachIniFile)
Dim dStoreDist As Double = GetPrivateProfileDouble("Store", "StoreDist", STORE_DIST, CurrentMachine.sMachIniFile)
Dim dStoreOffs As Double = GetPrivateProfileDouble("Store", "StoreOffs", STORE_OFFS, CurrentMachine.sMachIniFile)
Dim dStXmin As Double = b3Tab.Min().x - 0.5 * (dStoreLarg - b3Tab.DimX())
' Verifico che il pezzo ha una posizione salvata
Dim ptCenter As Point3d
If EgtGetInfo(nId, "PosInPark", ptCenter) Then
Dim ptCurrPos As Point3d
EgtCenterPoint(nId, GDB_ID.ROOT, ptCurrPos)
Dim vt As New Vector3d(ptCenter - ptCurrPos)
EgtMove(nId, vt, GDB_RT.GLOB)
Return True
End If
Return EgtPackBox(nId, dStXmin, -INFINITO, dStXmin + dStoreLarg, b3Tab.Min().y - dStoreDist, dStoreOffs, False)
Dim dStXmin As Double = b3Tab.Min().x - 0.5 * (STORE_LARGH - b3Tab.DimX())
Return EgtPackBox(nId, dStXmin, -INFINITO, dStXmin + STORE_LARGH, b3Tab.Min().y - STORE_DIST, STORE_OFFS, False)
End Function
Friend Function VerifyPartsNesting(bReducedCut As Boolean) As Boolean
+2 -4
View File
@@ -54,7 +54,7 @@ Module EstPhoto
' Recupero le dimensioni della tavola
Dim b3Tab As New BBox3d
If Not EgtGetTableArea(1, b3Tab) Then Return False
b3Tab.Expand(1000, 1000, 0)
b3Tab.Expand(100, 100, 0)
' Elimino eventuale precedente foto
Dim nOldPhotoId = GetPhoto()
If nOldPhotoId <> GDB_ID.NULL Then EgtErase(nOldPhotoId)
@@ -428,9 +428,7 @@ Module EstPhoto
Dim nNewPhotoId As Integer = EgtAddPhoto2(GetPhotoName(), sPath, ptOri, ptCen, dDimX, dDimY, nPhGrpId, ptMin, ptMax)
If nNewPhotoId = GDB_ID.NULL Then Return False
' Eseguo eventuale rotazione attorno all'origine
If Math.Abs( dRot) > EPS_ANG_ZERO then
EgtRotatePhoto(nNewPhotoId, ptOri, Vector3d.Z_AX(), dRot)
End If
EgtRotatePhoto(nNewPhotoId, ptOri, Vector3d.Z_AX(), dRot)
' Salvo gli offset
EgtSetInfo(nNewPhotoId, "OffsX", dOffsetX)
EgtSetInfo(nNewPhotoId, "OffsY", dOffsetY)
+13 -8
View File
@@ -1,7 +1,7 @@
<Window x:Class="VeinMatchingWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Height="500" Width="500" ShowInTaskbar="False" Initialized="Window_Initialized" MinWidth="300" MinHeight="300">
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Height="500" Width="500" ShowInTaskbar="False" Initialized="Window_Initialized" MinWidth="300" MinHeight="300">
<Grid Name="VeinMatchingGrid" Background="{StaticResource Omag_Gray}">
<Grid.ColumnDefinitions>
@@ -11,16 +11,21 @@
<StackPanel Orientation="Vertical">
<ToggleButton Name="ShowTextBtn" Height="40" Width="80"
Margin="0,5,0,0"/>
Margin="0,5,0,0"
Content="ShowText"/>
<ToggleButton Name="EditBtn" Height="40" Width="80"
Margin="0,5,0,0"/>
Margin="0,5,0,0"
Content="Edit"/>
<ToggleButton Name="VerifyBtn" Height="40" Width="80"
Margin="0,5,0,0"/>
Margin="0,5,0,0"
Content="Verify"/>
<ToggleButton Name="MagneticBtn" Height="40" Width="80"
Visibility="Collapsed"
Margin="0,5,0,0"/>
Margin="0,5,0,0"
Content="Magnetic"/>
<Button Name="ExportBtn" Height="40" Width="80"
Margin="0,5,0,0"/>
Margin="0,5,0,0"
Content="Export"/>
<Button Name="AssemblyBtn" Height="40" Width="80"
Margin="0,5,0,0"
Content="3D"/>
+6 -5
View File
@@ -1,6 +1,7 @@
Imports System.IO
Imports System.Windows.Interop
Imports System.Collections.ObjectModel
Imports System.Runtime.InteropServices
Imports EgtUILib
Imports EgtWPFLib5
Imports OmagOFFICE.VeinMatchingWindow
@@ -50,11 +51,11 @@ Public Class VeinMatchingWindow
' Per non farla visualizzare alla creazione
Me.Left = 32000
' Assegno messaggi
ExportBtn.Content = EgtMsg(91601) ' Esporta
ShowTextBtn.Content = EgtMsg(91609) ' Mostra Info
EditBtn.Content = EgtMsg(91610) ' Modifica
VerifyBtn.Content = EgtMsg(91611) ' Verifica
MagneticBtn.Content = EgtMsg(91612) ' Magnetico
ExportBtn.Content = EgtMsg(MSG_VEINMATCHING + 1) ' Esporta
ShowTextBtn.Content = EgtMsg(MSG_VEINMATCHING + 2) ' Mostra Info
EditBtn.Content = EgtMsg(MSG_VEINMATCHING + 3) ' Modifica
VerifyBtn.Content = EgtMsg(MSG_VEINMATCHING + 4) ' Verifica
MagneticBtn.Content = EgtMsg(MSG_VEINMATCHING + 5) ' Magnetico
End Sub
Private Sub Window_Loaded(sender As Object, e As RoutedEventArgs) Handles Me.Loaded
+1 -1
View File
@@ -78,7 +78,7 @@ Public Class PrintPanelVM
tmpImg.Stretch = Stretch.Uniform
tmpImg.EndInit()
' eseguo la stampa
printDlg.PrintVisual(tmpImg, EgtMsg(91688)) ' Parts Layout
printDlg.PrintVisual(tmpImg, "Parts Layout")
Catch
' Rrror in executing print
EgtOutLog(EgtMsg(50182))
+2 -2
View File
@@ -576,13 +576,13 @@ Public Class MachOptionWindowVM
Public ReadOnly Property OkMsg As String
Get
Return EgtMsg(91651) ' Ok
Return "Ok"
End Get
End Property
Public ReadOnly Property CancelMsg As String
Get
Return EgtMsg(91652) ' Cancel
Return "Cancel"
End Get
End Property
+63 -32
View File
@@ -105,7 +105,7 @@ Public Class MyMachinePanelVM
' procedo ad inizializzare la classe carico la lista "MachineList" che visualizzo per l'inserimento di nuovi MachGroup
Machine.MachineListInit(sMchRoots, MachineList)
' Inizializzo valori visibilità parametri Db utensili e lavorazioni
' OmagOFFICETMDbParamVisibility.Init()
OmagOFFICETMDbParamVisibility.Init()
End Sub
''' <summary>
@@ -135,32 +135,44 @@ Public Class MyMachinePanelVM
ToolDbWindowVM.MyForegroundGrbColor = Brushes.White
' Definisco lo stile della pagina
ToolDbWindowVM.BorderBrushIsMouseOver = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.GeneralBorderBrush = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.BorderBrushIsFocused = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.BackgroundBrdEnable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.BackgroundBrdDisable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.BackgroundTxBlDisable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.BorderBrushIsMouseOver = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.GeneralBorderBrush = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.BorderBrushIsFocused = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.BackgroundBrdEnable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.BackgroundBrdDisable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.BackgroundTxBlDisable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.BorderBrushIsMouseOver = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
ToolDbWindowVM.GeneralBorderBrush = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
ToolDbWindowVM.BorderBrushIsFocused = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
ToolDbWindowVM.BackgroundBrdEnable = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
ToolDbWindowVM.BackgroundBrdDisable = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
ToolDbWindowVM.BackgroundTxBlDisable = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
ToolDbWindowVM.ForegroundTxBlEnable = Brushes.White
ToolDbWindowVM.ForegroundTxBlDisable = Brushes.White
ToolDbWindowVM.GeneralForeground = Brushes.White
ToolDbWindowVM.GeneralBackground = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.GeneralBackground = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.GeneralBackground = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
' Definisco lo stile della ComboBox
ToolDbWindowVM.BackgroundCmBxTxBl = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.BackgroundListCmBxTxBl = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.BackgroundCmBxTxBl = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.BackgroundListCmBxTxBl = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.BackgroundCmBxTxBl = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
ToolDbWindowVM.BackgroundListCmBxTxBl = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
ToolDbWindowVM.ForegroundCmBxTxBl = Brushes.White
ToolDbWindowVM.BorderBrushCmBxTxBl = Brushes.Black
ToolDbWindowVM.BorderThicknessCmBxTxBl = New Thickness(1)
ToolDbWindowVM.VerticalContentAlignmentCmBxTxBl = "Center"
ToolDbWindowVM.HeightCmBxTxBl = "25"
'ToolDbWindowVM.HeightCmBxTxBl = "25"
ToolDbWindowVM.HeightCmBxTxBl = "22"
ToolDbWindowVM.WidthCmBxTxBl = "Auto"
ToolDbWindowVM.ForegroundTextBoxCmBxTxBl = Brushes.White
'Definisco lo stile del Button
ToolDbWindowVM.BackgroundButton = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.BackgroundButton = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.BackgroundButton = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
ToolDbWindowVM.ForegroundButton = Brushes.White
ToolDbWindowVM.BorderBrushButton = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'ToolDbWindowVM.BorderBrushButton = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
ToolDbWindowVM.BorderBrushButton = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
ToolDbWindowVM.BorderThicknessButton = New Thickness(1)
''Definisco lo stile della DataGrid
@@ -228,46 +240,64 @@ Public Class MyMachinePanelVM
MachDbWindowVM.MyForegroundGrbColor = Brushes.White
' Definisco lo stile della pagina
MachDbWindowVM.BorderBrushIsMouseOver = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.GeneralBorderBrush = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BorderBrushIsFocused = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BackgroundBrdEnable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BackgroundBrdDisable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BackgroundTxBlDisable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BorderBrushIsMouseOver = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.GeneralBorderBrush = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BorderBrushIsFocused = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BackgroundBrdEnable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BackgroundBrdDisable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BackgroundTxBlDisable = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BorderBrushIsMouseOver = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.GeneralBorderBrush = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.BorderBrushIsFocused = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.BackgroundBrdEnable = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.BackgroundBrdDisable = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.BackgroundTxBlDisable = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.ForegroundTxBlEnable = Brushes.White
MachDbWindowVM.ForegroundTxBlDisable = Brushes.White
MachDbWindowVM.GeneralForeground = Brushes.White
MachDbWindowVM.GeneralBackground = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.GeneralBackground = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.GeneralBackground = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.MyForegroundChColor = Brushes.White
' Definisco lo stile della ComboBox
MachDbWindowVM.BackgroundCmBxTxBl = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BackgroundListCmBxTxBl = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BackgroundCmBxTxBl = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BackgroundCmBxTxBl = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
'MachDbWindowVM.BackgroundListCmBxTxBl = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BackgroundListCmBxTxBl = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.ForegroundCmBxTxBl = Brushes.White
MachDbWindowVM.BorderBrushCmBxTxBl = Brushes.Black
'MachDbWindowVM.BorderBrushCmBxTxBl = Brushes.Black
MachDbWindowVM.BorderBrushCmBxTxBl = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.BorderThicknessCmBxTxBl = New Thickness(1)
MachDbWindowVM.VerticalContentAlignmentCmBxTxBl = "Center"
MachDbWindowVM.HeightCmBxTxBl = "25"
'MachDbWindowVM.HeightCmBxTxBl = "25"
MachDbWindowVM.HeightCmBxTxBl = "22"
MachDbWindowVM.WidthCmBxTxBl = "Auto"
MachDbWindowVM.ForegroundTextBoxCmBxTxBl = Brushes.White
'Definisco lo stile del ToggleButton
MachDbWindowVM.BackgroundIsChecked = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BackgroundIsChecked = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BackgroundIsChecked = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.ForegroundIsChecked = Brushes.White
MachDbWindowVM.BorderBrushIsChecked = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BorderBrushIsChecked = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BorderBrushIsChecked = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.BorderThicknessIsChecked = New Thickness(1)
MachDbWindowVM.OpacityIsChecked = 0.25
'Definisco lo stile della DataGrid
MachDbWindowVM.HeaderVisibility = DataGridHeadersVisibility.Column
MachDbWindowVM.BackgroundDataGrid = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#484D55"), Brush)
MachDbWindowVM.BackGroundHeader = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#484D55"), Brush)
'MachDbWindowVM.BackgroundDataGrid = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#484D55"), Brush)
'MachDbWindowVM.BackGroundHeader = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#484D55"), Brush)
MachDbWindowVM.BackgroundDataGrid = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#696969"), Color), CType(ColorConverter.ConvertFromString("#787878"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.BackGroundHeader = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#696969"), Color), CType(ColorConverter.ConvertFromString("#787878"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.ForegroundHeader = Brushes.White
MachDbWindowVM.BorderBrushHeader = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BorderBrushHeader = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BorderBrushHeader = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.BorderThicknessHeader = New Thickness(0)
MachDbWindowVM.FontWeightHeader = FontWeights.Bold
MachDbWindowVM.BorderBrushDataGrid = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BackgroundDataGridRow = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BorderBrushDataGrid = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
'MachDbWindowVM.BackgroundDataGridRow = DirectCast(New System.Windows.Media.BrushConverter().ConvertFromString("#1C1D22"), Brush)
MachDbWindowVM.BorderBrushDataGrid = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.BackgroundDataGridRow = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
MachDbWindowVM.ForegroundDataGridRow = Brushes.White
MachDbWindowVM.BorderBrushDataGridRow = Brushes.DarkGray
MachDbWindowVM.BorderThicknessDataGridRow = New Thickness(0, 0, 0, 1)
@@ -348,7 +378,8 @@ Public Class MyMachinePanelVM
OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = Brushes.Red
Else
OmagOFFICEMap.refOptionPanelVM.RawPart_Background = OmagOFFICEDictionary.TabControl_Header_Background
OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = DirectCast(New BrushConverter().ConvertFrom("#1C1D22"), SolidColorBrush)
'OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = DirectCast(New BrushConverter().ConvertFrom("#1C1D22"), SolidColorBrush)
OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
End If
End Sub
+3 -4
View File
@@ -228,8 +228,8 @@ Public Class MainWindowM
' Verifico abilitazione nesting automatico
m_bAutoNestOption = Not String.IsNullOrWhiteSpace( sNestKey)
' Recupero livello e opzioni della chiave
Dim bKey As Boolean = EgtGetKeyLevel(9423, 3104, 1, m_nKeyLevel) And
EgtGetKeyOptions(9423, 3104, 1, m_nKeyOptions)
Dim bKey As Boolean = EgtGetKeyLevel(9423, 2604, 1, m_nKeyLevel) And
EgtGetKeyOptions(9423, 2604, 1, m_nKeyOptions)
' Verifico abilitazione prodotto
Dim bProd As Boolean = GetKeyOption(KEY_OPT.OFFICE_BASE)
' Inizializzazione generale di EgtInterface
@@ -291,7 +291,7 @@ Public Class MainWindowM
' Leggo nome cartella delle foto
GetMainPrivateProfileString(S_GENERAL, K_PHOTODIR, sDataRoot & "\Data", m_sPhotoDir)
' Creo connessione al Db
If m_SlabDB AndAlso Not ManageDb.ConnectToDb(m_sPhotoDir & "\" & DB_FILENAME) Then
If m_SlabDB And Not ManageDb.ConnectToDb(m_sPhotoDir & "\" & DB_FILENAME) Then
EgtOutLog("Error connecting to DB")
MessageBox.Show(EgtMsg(92000 + 1), EgtMsg(MSG_EGTMSGBOX + 15), MessageBoxButton.OK, MessageBoxImage.Error)
m_SlabDB = False
@@ -299,7 +299,6 @@ Public Class MainWindowM
' Info su opzioni chiave
EgtOutLog("KeyOptions : " & bKey.ToString() & " " & m_nKeyOptions.ToString() & " " & bProd.ToString())
EgtPHOTOLib.MainData.SetConfigDir(m_sConfigDir)
EgtPHOTOLib.MainData.SetDebugLevel(m_nDebug)
EgtPHOTOLib.MainData.SetKeyLevel(m_nKeyLevel)
EgtPHOTOLib.MainData.SetKeyOptions(CInt(m_nKeyOptions))
EgtPHOTOLib.MainData.SetPhotoDir(m_sPhotoDir)
+3 -2
View File
@@ -5,11 +5,12 @@
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
DataContext="{StaticResource MainWindowVM}"
Style="{DynamicResource MainWindowStyle}"
Title="{Binding Title}" Icon="/Resources/OmagOFFICE.ico"
Title="{Binding Title}" Icon="/Resources/Egalware.ico"
MinHeight="600" MinWidth="800"
AboutBoxCommand="{Binding AboutBoxCommand}" WindowStyle="None" ResizeMode="NoResize"
CloseCommand="{Binding CloseApplicationCommand,Mode=OneWay,UpdateSourceTrigger=PropertyChanged}"
Background="{StaticResource Omag_DarkGray}">
Background="{StaticResource Gradient_Gray}">
<!--Background="{StaticResource Omag_DarkGray}"-->
<EgtWPFLib5:EgtCustomWindow.TitlePanel>
<OmagOFFICE:TopCommandBarV DataContext="{StaticResource TopCommandBarVM}"/>
</EgtWPFLib5:EgtCustomWindow.TitlePanel>
+3 -3
View File
@@ -30,7 +30,7 @@ Imports System.Windows
#End If
<Assembly: AssemblyCompany("Egalware s.r.l.")>
<Assembly: AssemblyProduct("OmagOFFICE")>
<Assembly: AssemblyCopyright("Copyright © 2017-2026 by Egalware s.r.l.")>
<Assembly: AssemblyCopyright("Copyright © 2017-2023 by Egalware s.r.l.")>
<Assembly: AssemblyTrademark("")>
<Assembly: ComVisible(false)>
'In order to begin building localizable applications, set
@@ -69,6 +69,6 @@ Imports System.Windows
' by using the '*' as shown below:
' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("3.1.4.2")>
<Assembly: AssemblyFileVersion("3.1.4.2")>
<Assembly: AssemblyVersion("2.6.4.1")>
<Assembly: AssemblyFileVersion("2.6.4.1")>
+4 -2
View File
@@ -92,17 +92,19 @@
</ListBox>
<Button Content="+" Height="20" Width="20" VerticalAlignment="Center" Focusable="False"
Background="{StaticResource Omag_Black}"
Background="{StaticResource Gradient_Gray_Button}"
Foreground="{StaticResource Omag_White}"
Padding="0,0,0,5"
Margin="3,0,5,0" Command="{Binding AddMachGroupCommand}" Grid.Column="1"
IsEnabled="{Binding IsEnabledAddRemove}"/>
<!--Background="{StaticResource Omag_DarkGray}"-->
<Button Content="-" Height="20" Width="20" VerticalAlignment="Center" Focusable="False"
Background="{StaticResource Omag_Black}"
Background="{StaticResource Gradient_Gray_Button}"
Foreground="{StaticResource Omag_White}"
Padding="0,0,0,5"
Margin="0,0,5,0" Command="{Binding RemoveMachGroupCommand}" Grid.Column="2"
IsEnabled="{Binding IsEnabledAddRemove}"/>
<!--Background="{StaticResource Omag_DarkGray}"-->
</Grid>
+13 -12
View File
@@ -117,11 +117,10 @@ Public Class MyMachGroupPanelVM
' Se macchina con più tavole, chiedo quale usare
Dim nTabInd As Integer = 1
Dim nTabCnt As Integer = CamAuto.GetTableCount()
Dim SelectTableWindowVM As New SelectTableWindowVM()
If nTabCnt > 1 And nTabCnt <= 4 Then
Dim SelectTableWindowV As New SelectTableWindowV(Application.Current.MainWindow, SelectTableWindowVM)
SelectTableWindowV.ShowDialog()
nTabInd = SelectTableWindowVM.nSelectedTable
If nTabCnt > 1 And nTabCnt <= 3 Then
Dim dlg As New SelectTableWindowV(Application.Current.MainWindow, New SelectTableWindowVM(DirectCast(nTabCnt, SelectTableWindowVM.TableNumOpt)))
dlg.ShowDialog()
nTabInd = dlg.m_SelTable
End If
EgtSetTable(GetTableName(nTabInd))
' leggo nome attrezzaggio di default
@@ -247,11 +246,13 @@ Public Class MyMachGroupPanelVM
OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = Brushes.Red
Else
OmagOFFICEMap.refOptionPanelVM.RawPart_Background = OmagOFFICEDictionary.TabControl_Header_Background
OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = DirectCast(New BrushConverter().ConvertFrom("#1C1D22"), SolidColorBrush)
'OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = DirectCast(New BrushConverter().ConvertFrom("#1C1D22"), SolidColorBrush)
OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
End If
Else
OmagOFFICEMap.refOptionPanelVM.RawPart_Background = OmagOFFICEDictionary.TabControl_Header_Background
OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = DirectCast(New BrushConverter().ConvertFrom("#1C1D22"), SolidColorBrush)
'OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = DirectCast(New BrushConverter().ConvertFrom("#1C1D22"), SolidColorBrush)
OmagOFFICEMap.refRawPartTabVM.CurrMach_Background = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
End If
' Se non esiste il grezzo vado subito alla sua definizione
@@ -352,11 +353,11 @@ Public Class MyMachGroup
If Not EgtGetInfo(Id, INFO_SLABHEIGHT, dSlabHeight) Then dSlabHeight = 0
Dim sCurrSawing As String = String.Empty
If Not EgtGetInfo(m_nOpersGroupId, INFO_CURRSAWING, sCurrSawing) Then sCurrSawing = "---"
Return EgtMsg(91683) & sSlabName & Environment.NewLine & ' Name:
EgtMsg(91684) & sMaterial & Environment.NewLine & ' Material:
EgtMsg(91685) & LenToString(dSlabHeight, 3) & Environment.NewLine & ' Thickness:
EgtMsg(91686) & sCurrSawing & Environment.NewLine & ' Sawing:
EgtMsg(91687) & Machine ' Machine:
Return "Name: " & sSlabName & Environment.NewLine &
"Material: " & sMaterial & Environment.NewLine &
"Thickness: " & LenToString(dSlabHeight, 3) & Environment.NewLine &
"Sawing: " & sCurrSawing & Environment.NewLine &
"Machine: " & Machine
End Get
End Property
@@ -18,7 +18,7 @@
</EgtWPFLib5:EgtCustomWindow.InputBindings>
<EgtWPFLib5:EgtCustomWindow.Resources>
<!--<EgtWPFLib5:MachiningParamVisibilityConverter x:Key="MachiningParamVisibilityConverter"/>-->
<EgtWPFLib5:MachiningParamVisibilityConverter x:Key="MachiningParamVisibilityConverter"/>
<EgtWPFLib5:DepthUnitConverter x:Key="DepthUnitConverter"/>
<EgtWPFLib5:ErrorVisibilityConverter x:Key="ErrorVisibilityConverter"/>
<sys:Int32 x:Key="Invert">0</sys:Int32>
@@ -13,7 +13,7 @@ Public Class MyMachiningDbWindowV
m_MachiningDbWindowVM = MachiningDbWindowVM
End Sub
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_MachiningDbWindowVM.OnCloseWindow
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_MachiningDbWindowVM.m_CloseWindow
Me.DataContext = Nothing
Me.DialogResult = bDialogResult
End Sub
-9
View File
@@ -102,14 +102,12 @@ Public Class MySceneHostVM
Public Overrides Sub InitSceneEvents()
AddHandler MainScene.OnMouseDownScene, AddressOf OnMouseDownScene
'AddHandler OnMouseDownScene_DoubleClick_1, AddressOf OnMouseDownScene_DoubleClick
AddHandler MainScene.OnMouseMoveScene, AddressOf OnMouseMoveScene
AddHandler MainScene.OnMouseUpScene, AddressOf OnMouseUpScene
AddHandler MainScene.KeyDown, AddressOf OnKeyDownScene
AddHandler MainScene.OnCursorPos, AddressOf OnCursorPos
AddHandler MainScene.OnShowDistance, AddressOf OnShowDistance
AddHandler MainScene.OnChangedSnapPointType, AddressOf OnChangedSnapPointType
End Sub
Private Sub PreInitializeScene()
@@ -811,13 +809,6 @@ Public Class MySceneHostVM
Private Sub OnMouseDownScene(sender As Object, e As Windows.Forms.MouseEventArgs)
' Si può selezionare solo con il tasto sinistro e se stato NULL
If e.Button <> Windows.Forms.MouseButtons.Left Or Not MainScene.IsStatusNull() Then Return
If e.Clicks > 1 Then
Select Case OmagOFFICEMap.refOptionPanelVM.SelItem
Case OptionPanelVM.Tabs.MACHINING
OmagOFFICEMap.refMachiningTabVM.OnMouseDownScene_DoubleClick(sender, e)
Case OptionPanelVM.Tabs.SIMUL
End Select
End If
' Chiamo l'opportuno gestore
Select Case OmagOFFICEMap.refOptionPanelVM.SelItem
Case OptionPanelVM.Tabs.RAWPART
+1 -1
View File
@@ -22,7 +22,7 @@ Public Class MySetUpWindowV
End If
End Sub
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_SetUpWindowVM.OnCloseWindow
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_SetUpWindowVM.m_CloseWindow
Me.DialogResult = bDialogResult
End Sub
+139 -139
View File
@@ -1,165 +1,165 @@
<EgtWPFLib5:EgtCustomWindow x:Class="MyToolDbWindowV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:sys="clr-namespace:System;assembly=mscorlib"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
Title="{Binding Title}"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize" TitleBarHeight="30" IsResizable="False"
IsMinimizable="False" WindowStartupLocation="CenterOwner" ShowInTaskbar="False"
CloseCommand="{Binding CloseToolsDbCommand,Mode=OneWay,UpdateSourceTrigger=PropertyChanged}"
CloseCommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
Height="900">
<EgtWPFLib5:EgtCustomWindow.InputBindings>
<KeyBinding Key="Escape" Command="{Binding ReloadToolCommand}"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:sys="clr-namespace:System;assembly=mscorlib"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
Title="{Binding Title}"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize" TitleBarHeight="30" IsResizable="False"
IsMinimizable="False" WindowStartupLocation="CenterOwner" ShowInTaskbar="False"
CloseCommand="{Binding CloseToolsDbCommand,Mode=OneWay,UpdateSourceTrigger=PropertyChanged}"
CloseCommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
Height="900">
<EgtWPFLib5:EgtCustomWindow.InputBindings>
<KeyBinding Key="Escape" Command="{Binding ReloadToolCommand}"
CommandParameter="{Binding Path=SelectedItem,ElementName=ToolsTreeView}"/>
</EgtWPFLib5:EgtCustomWindow.InputBindings>
</EgtWPFLib5:EgtCustomWindow.InputBindings>
<EgtWPFLib5:EgtCustomWindow.Resources>
<!--<EgtWPFLib5:ToolParamVisibilityConverter x:Key="ToolParamVisibilityConverter"/>-->
<EgtWPFLib5:ToolDrawUUIDConverter x:Key="ToolDrawUUIDConverter"/>
<EgtWPFLib5:ErrorVisibilityConverter x:Key="ErrorVisibilityConverter"/>
<sys:Int32 x:Key="Corr">0</sys:Int32>
<sys:Int32 x:Key="ExitPar">1</sys:Int32>
<sys:Int32 x:Key="Coolant">2</sys:Int32>
<sys:Int32 x:Key="CornRad">3</sys:Int32>
<sys:Int32 x:Key="Diam">4</sys:Int32>
<sys:Int32 x:Key="TotDiam">5</sys:Int32>
<sys:Int32 x:Key="Feed">6</sys:Int32>
<sys:Int32 x:Key="EndFeed">7</sys:Int32>
<sys:Int32 x:Key="StartFeed">8</sys:Int32>
<sys:Int32 x:Key="TipFeed">9</sys:Int32>
<sys:Int32 x:Key="Len">10</sys:Int32>
<sys:Int32 x:Key="TotLen">11</sys:Int32>
<sys:Int32 x:Key="MaxMat">12</sys:Int32>
<sys:Int32 x:Key="LonOffset">13</sys:Int32>
<sys:Int32 x:Key="RadOffset">14</sys:Int32>
<sys:Int32 x:Key="Speed">15</sys:Int32>
<sys:Int32 x:Key="SideAng">16</sys:Int32>
<sys:Int32 x:Key="MaxSpeed">17</sys:Int32>
<sys:Int32 x:Key="Thick">18</sys:Int32>
<sys:Int32 x:Key="MaxAbsorption">19</sys:Int32>
<sys:Int32 x:Key="MinFeed">20</sys:Int32>
<sys:Int32 x:Key="Draw">21</sys:Int32>
<sys:Int32 x:Key="Head">22</sys:Int32>
<sys:Int32 x:Key="NamePar">23</sys:Int32>
<sys:Int32 x:Key="UserNotes">24</sys:Int32>
<sys:Int32 x:Key="TcPos">25</sys:Int32>
</EgtWPFLib5:EgtCustomWindow.Resources>
<EgtWPFLib5:EgtCustomWindow.Resources>
<EgtWPFLib5:ToolParamVisibilityConverter x:Key="ToolParamVisibilityConverter"/>
<EgtWPFLib5:ToolDrawUUIDConverter x:Key="ToolDrawUUIDConverter"/>
<EgtWPFLib5:ErrorVisibilityConverter x:Key="ErrorVisibilityConverter"/>
<sys:Int32 x:Key="Corr">0</sys:Int32>
<sys:Int32 x:Key="ExitPar">1</sys:Int32>
<sys:Int32 x:Key="Coolant">2</sys:Int32>
<sys:Int32 x:Key="CornRad">3</sys:Int32>
<sys:Int32 x:Key="Diam">4</sys:Int32>
<sys:Int32 x:Key="TotDiam">5</sys:Int32>
<sys:Int32 x:Key="Feed">6</sys:Int32>
<sys:Int32 x:Key="EndFeed">7</sys:Int32>
<sys:Int32 x:Key="StartFeed">8</sys:Int32>
<sys:Int32 x:Key="TipFeed">9</sys:Int32>
<sys:Int32 x:Key="Len">10</sys:Int32>
<sys:Int32 x:Key="TotLen">11</sys:Int32>
<sys:Int32 x:Key="MaxMat">12</sys:Int32>
<sys:Int32 x:Key="LonOffset">13</sys:Int32>
<sys:Int32 x:Key="RadOffset">14</sys:Int32>
<sys:Int32 x:Key="Speed">15</sys:Int32>
<sys:Int32 x:Key="SideAng">16</sys:Int32>
<sys:Int32 x:Key="MaxSpeed">17</sys:Int32>
<sys:Int32 x:Key="Thick">18</sys:Int32>
<sys:Int32 x:Key="MaxAbsorption">19</sys:Int32>
<sys:Int32 x:Key="MinFeed">20</sys:Int32>
<sys:Int32 x:Key="Draw">21</sys:Int32>
<sys:Int32 x:Key="Head">22</sys:Int32>
<sys:Int32 x:Key="NamePar">23</sys:Int32>
<sys:Int32 x:Key="UserNotes">24</sys:Int32>
<sys:Int32 x:Key="TcPos">25</sys:Int32>
</EgtWPFLib5:EgtCustomWindow.Resources>
<Grid Background="Transparent">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="0.95*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Grid Background="Transparent">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="0.95*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Grid Background="Transparent">
<Grid.RowDefinitions>
<RowDefinition Height="0.75*"/>
<RowDefinition Height="12*"/>
</Grid.RowDefinitions>
<Grid Background="Transparent">
<Grid.RowDefinitions>
<RowDefinition Height="0.75*"/>
<RowDefinition Height="12*"/>
</Grid.RowDefinitions>
<UniformGrid Grid.Row="0" Columns="8">
<Button ToolTip="New" Command="{Binding NewCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
IsEnabled="{Binding IsEnabledNewBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/New.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="Save" Command="{Binding SaveCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
IsEnabled="{Binding IsEnabledSaveBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/Save.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="Remove" Command="{Binding RemoveCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
IsEnabled="{Binding IsEnabledRemoveBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/Remove.png" Stretch="Uniform"/>
</Button>
<UniformGrid Grid.Row="0" Columns="8">
<Button ToolTip="New" Command="{Binding NewCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
IsEnabled="{Binding IsEnabledNewBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/New.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="Save" Command="{Binding SaveCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
IsEnabled="{Binding IsEnabledSaveBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/Save.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="Remove" Command="{Binding RemoveCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
IsEnabled="{Binding IsEnabledRemoveBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/Remove.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="Import" Command="{Binding ImportCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=MachiningsTreeView}"
IsEnabled="{Binding IsEnabledNewBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/Import.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="Export" Command="{Binding ExportCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=MachiningsTreeView}"
IsEnabled="{Binding IsEnabledSaveBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/Export_1.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="Reset" Command="{Binding ReloadToolCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=MachiningsTreeView}"
IsEnabled="{Binding IsEnabledRemoveBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/Reset.png" Stretch="Uniform"/>
</Button>
</UniformGrid>
<Button ToolTip="Import" Command="{Binding ImportCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=MachiningsTreeView}"
IsEnabled="{Binding IsEnabledNewBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/Import.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="Export" Command="{Binding ExportCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=MachiningsTreeView}"
IsEnabled="{Binding IsEnabledSaveBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/Export_1.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="Reset" Command="{Binding ReloadToolCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=MachiningsTreeView}"
IsEnabled="{Binding IsEnabledRemoveBtn, Mode=OneWay}"
Style = "{DynamicResource MachiningDB_Button}">
<Image Source="/Resources/TopCommandBar/Reset.png" Stretch="Uniform"/>
</Button>
</UniformGrid>
<!--Elenco degli utensili-->
<TreeView Name="ToolsTreeView" Grid.Row="1"
Background="Transparent" BorderThickness="0"
ItemsSource="{Binding ToolsList}">
<TreeView.ItemContainerStyle>
<!--Elenco degli utensili-->
<TreeView Name="ToolsTreeView" Grid.Row="1"
Background="Transparent" BorderThickness="0"
ItemsSource="{Binding ToolsList}">
<TreeView.ItemContainerStyle>
<Style TargetType="{x:Type TreeViewItem}" BasedOn="{StaticResource Db_TreeViewItem}">
<Setter Property="FontSize" Value="10" />
<Setter Property="Foreground" Value="{StaticResource Omag_White}" />
<Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay}" />
<Setter Property="IsExpanded" Value="{Binding IsExpanded, Mode=TwoWay}" />
<Setter Property="IsEnabled" Value="{Binding IsEnabled, Mode=TwoWay}" />
</Style>
</TreeView.ItemContainerStyle>
<Setter Property="FontSize" Value="10" />
<Setter Property="Foreground" Value="{StaticResource Omag_White}" />
<Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay}" />
<Setter Property="IsExpanded" Value="{Binding IsExpanded, Mode=TwoWay}" />
<Setter Property="IsEnabled" Value="{Binding IsEnabled, Mode=TwoWay}" />
</Style>
</TreeView.ItemContainerStyle>
<TreeView.Resources>
<HierarchicalDataTemplate DataType="{x:Type EgtWPFLib5:FamilyToolTreeViewItem}" ItemsSource="{Binding Items}">
<TreeView.Resources>
<HierarchicalDataTemplate DataType="{x:Type EgtWPFLib5:FamilyToolTreeViewItem}" ItemsSource="{Binding Items}">
<Grid Background="Transparent">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<Grid Background="Transparent">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<Image Grid.Column="0" Source="{Binding PictureString}" Height="32" Width="32" Margin="0" />
<TextBlock Grid.Column="1" Text="{Binding Name}" FontSize="15" Margin="5,0,10,0" VerticalAlignment="Center" HorizontalAlignment="left" />
<Ellipse Grid.Column="2" Height="10" Width="10" Fill="{Binding FamilyColor}" />
<Image Grid.Column="0" Source="{Binding PictureString}" Height="32" Width="32" Margin="0" />
<TextBlock Grid.Column="1" Text="{Binding Name}" FontSize="15" Margin="5,0,10,0" VerticalAlignment="Center" HorizontalAlignment="left" />
<Ellipse Grid.Column="2" Height="10" Width="10" Fill="{Binding FamilyColor}" />
</Grid>
</Grid>
</HierarchicalDataTemplate>
</HierarchicalDataTemplate>
<DataTemplate DataType="{x:Type EgtWPFLib5:ToolTreeViewItem}">
<Grid Background="Transparent">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<DataTemplate DataType="{x:Type EgtWPFLib5:ToolTreeViewItem}">
<Grid Background="Transparent">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<!--<Image Grid.Column="0" Source="{Binding PictureString}" Height="32" Margin="0,8,6,4" />-->
<TextBlock Grid.Column="1" Text="{Binding NamePar}" Height="21" FontSize="13" Margin="30,0,10,0"
VerticalAlignment="Center" HorizontalAlignment="left"/>
<Ellipse Grid.Column="2" Height="10" Width="10" Fill="{Binding ToolColor}" />
<!--<Image Grid.Column="0" Source="{Binding PictureString}" Height="32" Margin="0,8,6,4" />-->
<TextBlock Grid.Column="1" Text="{Binding NamePar}" Height="21" FontSize="13" Margin="30,0,10,0"
VerticalAlignment="Center" HorizontalAlignment="left"/>
<Ellipse Grid.Column="2" Height="10" Width="10" Fill="{Binding ToolColor}" />
</Grid>
</Grid>
</DataTemplate>
</DataTemplate>
</TreeView.Resources>
</TreeView.Resources>
</TreeView>
</TreeView>
</Grid>
</Grid>
<ContentControl Content="{Binding Path=ParamPageV}" Grid.Column="1"/>
<ContentControl Content="{Binding Path=ParamPageV}" Grid.Column="1"/>
<!--ContentControl che ospita la scena restituita sotto forma di WindowsFormsHost-->
<ContentControl Content="{Binding ToolSceneHost}" Grid.Column="2"/>
<!--ContentControl che ospita la scena restituita sotto forma di WindowsFormsHost-->
<ContentControl Content="{Binding ToolSceneHost}" Grid.Column="2"/>
</Grid>
</Grid>
</EgtWPFLib5:EgtCustomWindow>
+1 -1
View File
@@ -13,7 +13,7 @@ Public Class MyToolDbWindowV
m_ToolDbWindowVM = ToolDbWindowVM
End Sub
Private Sub ToolsDbView_Closed(bDialogResult As Boolean) Handles m_ToolDbWindowVM.OnCloseWindow
Private Sub ToolsDbView_Closed(bDialogResult As Boolean) Handles m_ToolDbWindowVM.m_CloseWindow
' Imposto contesto generale
EgtSetCurrentContext(EgtWPFLib5.ToolDbWindowVM.ProjectSceneContext)
' Cancello contesto di visualizzazione utensile
@@ -116,15 +116,6 @@
</DataTemplate>
</DataGridTextColumn.HeaderTemplate>
</DataGridTextColumn>
<!--Flux-->
<DataGridTextColumn Binding="{Binding Flux}"
Width="*">
<DataGridTextColumn.HeaderTemplate>
<DataTemplate>
<TextBlock Text="{Binding DataContext.Flux_Msg,RelativeSource={RelativeSource AncestorType={x:Type DataGrid}}}"/>
</DataTemplate>
</DataGridTextColumn.HeaderTemplate>
</DataGridTextColumn>
<!--Q1-->
<DataGridTextColumn Binding="{Binding Q1}"
Width="*">
@@ -13,7 +13,7 @@ Public Class MyWaterjetDbWindowV
m_WaterjetDbWindowVM = WaterjetDbWindowVM
End Sub
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_WaterjetDbWindowVM.OnCloseWindow
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_WaterjetDbWindowVM.m_CloseWindow
Me.DialogResult = bDialogResult
End Sub
+5 -35
View File
@@ -135,13 +135,11 @@
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\EgtProg\Dll32\EgtPHOTOLib.dll</HintPath>
</Reference>
<Reference Include="EgtUILib, Version=2.7.5.2, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\EgtProg\OmagOFFICE\EgtUILib.dll</HintPath>
<Reference Include="EgtUILib">
<HintPath>..\..\EgtProg\DllD32\EgtUILib.dll</HintPath>
</Reference>
<Reference Include="EgtWPFLib5, Version=2.7.4.1, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\EgtProg\OmagOFFICE\EgtWPFLib5.dll</HintPath>
<Reference Include="EgtWPFLib5">
<HintPath>..\..\EgtProg\DllD32\EgtWPFLib5.dll</HintPath>
</Reference>
<Reference Include="PresentationFramework.Aero" />
<Reference Include="System.Core" />
@@ -293,10 +291,6 @@
<DependentUpon>SplitModeV.xaml</DependentUpon>
</Compile>
<Compile Include="OptionPanel\MachiningTab\SplitModeVM.vb" />
<Compile Include="OptionPanel\NestingTab\ChangeTableV.xaml.vb">
<DependentUpon>ChangeTableV.xaml</DependentUpon>
</Compile>
<Compile Include="OptionPanel\NestingTab\ChangeTableVM.vb" />
<Compile Include="OptionPanel\NestingTab\MultiSelectionV.xaml.vb">
<DependentUpon>MultiSelectionV.xaml</DependentUpon>
</Compile>
@@ -503,10 +497,6 @@
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="OptionPanel\NestingTab\ChangeTableV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="OptionPanel\NestingTab\MultiSelectionV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
@@ -974,27 +964,7 @@
<Resource Include="Resources\NewIcons\DB-WJ.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\DetailPage\Cancel.png" />
<Resource Include="Resources\DetailPage\Confirm.png" />
<Resource Include="Resources\DetailPage\Elimina.png" />
<Resource Include="Resources\DetailPage\Pencil.png" />
<Resource Include="Resources\DetailPage\Photo.png" />
<Resource Include="Resources\DetailPage\Polygon.png" />
<Resource Include="Resources\DetailPage\Print.png" />
<Resource Include="Resources\DetailPage\Reset.png" />
<Resource Include="Resources\DetailPage\Rubber.png" />
<Resource Include="Resources\DetailPage\Save.png" />
<Resource Include="Resources\DetailPage\ZoomAll.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewIcons\LightArrowOff.png" />
<Resource Include="Resources\NewIcons\LightArrowOn.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewIcons\table.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewIcons\tableS.png" />
<Resource Include="Resources\Egalware.ico" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
<PropertyGroup>
+4 -4
View File
@@ -7,14 +7,14 @@
<Button Style="{StaticResource MachiningTab_Button}"
Command="{Binding PrevCommand}"
IsEnabled="{Binding PrevIsEnabled}"
Background="{StaticResource Omag_Black}"
Background="{StaticResource Gradient_Gray_Button}"
Margin="0,0,1,0">
<Image Source="/Resources/MachiningTab/BackArrow.png"/>
</Button>
<Button Style="{StaticResource MachiningTab_Button}"
Command="{Binding NextCommand}"
IsEnabled="{Binding NextIsEnabled}"
Background="{StaticResource Omag_Black}"
Background="{StaticResource Gradient_Gray_Button}"
Margin="0,0,0,0">
<Image Source="/Resources/MachiningTab/ForwardArrow.png"/>
</Button>
@@ -22,14 +22,14 @@
Content="{Binding ModifyMsg}"
Command="{Binding ModifyCommand}"
IsEnabled="{Binding ModifyIsEnabled}"
Background="{StaticResource Omag_Black}"
Background="{StaticResource Gradient_Gray_Button}"
Foreground="{StaticResource Omag_White}"
Margin="1,0,1,0"/>
<Button Style="{StaticResource MachiningTab_Button}"
Content="{Binding AutoMsg}"
Command="{Binding AutoCommand}"
Visibility="{Binding AutoVisibility}"
Background="{StaticResource Omag_Black}"
Background="{StaticResource Gradient_Gray_Button}"
Foreground="{StaticResource Omag_White}"
Margin="1,0,1,0"/>
</UniformGrid>
@@ -334,12 +334,6 @@ Public Class MachiningTabVM
End If
End Sub
Friend Sub OnMouseDownScene_DoubleClick(sender As Object, e As Windows.Forms.MouseEventArgs)
If m_MachiningMode = MachiningModeOpt.SPLIT Then
OmagOFFICEMap.refSplitModeVM.OnMouseDownScene_DoubleClick(sender, e)
End If
End Sub
#End Region ' EVENTS
End Class
+6 -5
View File
@@ -44,7 +44,7 @@
Text="{Binding MoveStep}"
HorizontalAlignment="Center"
HorizontalContentAlignment="right"
Background="{StaticResource Omag_Black}"
Background="{StaticResource Gradient_Gray}"
Foreground="{StaticResource Omag_White}"
VerticalAlignment="Center"/>
@@ -64,7 +64,7 @@
</Button>
<Button Grid.Column="0" Grid.Row="6"
Style="{StaticResource OptionPanel_MoveButton}"
Style="{StaticResource OptionPanel_MoveButton2}"
Command="{Binding CcwRotCommand}"
Visibility="{Binding RotationVisibility}">
<Image Source="/Resources/NestingTab/CounterClockwiseRotate.png"
@@ -82,14 +82,15 @@
<TextBox Text="{Binding RotationStep}" Width="40" Height="20"
HorizontalAlignment="center"
HorizontalContentAlignment="right"
Background="{StaticResource Omag_Black}"
Background="{StaticResource Gradient_Gray}"
Foreground="{StaticResource Omag_White}"/>
<TextBlock Grid.Column="1" FontSize="25" Margin="2,-5,0,0"
<!--Background="{StaticResource Omag_Black}"-->
<TextBlock Grid.Column="1" FontSize="25" Margin="2,-5,0,0"
Foreground="{StaticResource Omag_White}" Text="°"/>
</Grid>
<Button Grid.Column="4" Grid.Row="6"
Style="{StaticResource OptionPanel_MoveButton}"
Style="{StaticResource OptionPanel_MoveButton2}"
Command="{Binding CwRotCommand}"
Visibility="{Binding RotationVisibility}">
<Image Source="/Resources/NestingTab/ClockwiseRotate.png"
+3 -3
View File
@@ -749,7 +749,7 @@ Public Class MoveRawModeVM
If VerifyCollisionWithOtherRawPart(nId) Then
' mantengo la selezione del pezzo
EgtSetStatus(nId, GDB_ST.SEL)
OmagOFFICEMap.refStatusBarVM.SetOutputMessage(EgtMsg(91231), 3, MSG_TYPE.ERROR_) ' Collisione pezzi
OmagOFFICEMap.refStatusBarVM.SetOutputMessage("Collisione pezzi", 3, MSG_TYPE.ERROR_)
Else
' Se con ventose, le nascondo
If Not OmagOFFICEMap.refMachiningTabVM.ByHand Then EgtSetStatus(GetVacuumId(), GDB_ST.OFF)
@@ -761,7 +761,7 @@ Public Class MoveRawModeVM
If VerifyCollisionWithOtherRawPart(m_CurrRawOnVacuum) Then
' mantengo la selezione del pezzo
EgtSetStatus(m_CurrRawOnVacuum, GDB_ST.SEL)
OmagOFFICEMap.refStatusBarVM.SetOutputMessage(EgtMsg(91231), 3, MSG_TYPE.ERROR_) ' Collisione pezzi
OmagOFFICEMap.refStatusBarVM.SetOutputMessage("Collisione pezzi", 3, MSG_TYPE.ERROR_)
EgtDraw()
' esco dal ciclo, prima devo depositare correttamente il pezzo
Exit While
@@ -819,7 +819,7 @@ Public Class MoveRawModeVM
If VerifyCollisionWithOtherRawPart(m_CurrRawOnVacuum) Then
' mantengo la selezione del pezzo
EgtSetStatus(m_CurrRawOnVacuum, GDB_ST.SEL)
OmagOFFICEMap.refStatusBarVM.SetOutputMessage(EgtMsg(91231), 3, MSG_TYPE.ERROR_) ' Collisione pezzi
OmagOFFICEMap.refStatusBarVM.SetOutputMessage("Collisione pezzi", 3, MSG_TYPE.ERROR_)
EgtDraw()
End If
+7 -18
View File
@@ -21,12 +21,8 @@
<Image Margin="1" Height="20" Width="20"
Source="{Binding SourceImg}">
</Image>
<TextBlock Margin="1" Text="{Binding Name}"/>
<StackPanel.InputBindings>
<MouseBinding MouseAction="LeftDoubleClick"
Command="{Binding Path=DataContext.OnOffCommand,
RelativeSource={RelativeSource AncestorType=UserControl, Mode=FindAncestor }}"/>
</StackPanel.InputBindings>
<TextBlock Margin="1" Text="{Binding Name}">
</TextBlock>
</StackPanel>
</DataTemplate>
</ListBox.ItemTemplate>
@@ -44,7 +40,6 @@
</DataTrigger>
</Style.Triggers>
<Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay}" />
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
</Style>
</ListBox.ItemContainerStyle>
</ListBox>
@@ -52,27 +47,21 @@
<StackPanel HorizontalAlignment="Center" Orientation="Horizontal" Margin="0,0,0,2.5">
<Button
<Button Grid.Column="1"
IsEnabled="{Binding bEnabledCommandMove}"
Style="{StaticResource OptionPanel_Button}"
Command="{Binding MoveUpCommand}"
Margin="0,0,0.5,0">
<Image Source="/Resources/NestingTab/UpArrow.png"/>
</Button>
<Button
<Button Grid.Column="2"
IsEnabled="{Binding bEnabledCommandMove}"
Style="{StaticResource OptionPanel_Button}"
Command="{Binding MoveDownCommand}"
Margin="0.5,0,0,0">
<Image Source="/Resources/NestingTab/DownArrow.png"/>
</Button>
<ToggleButton ToolTip="{Binding LayNbArrTgBtnMsg}"
Style="{StaticResource Split_ToggleButton_Img}"
IsChecked="{Binding LayNbArrTgBtn_IsChecked}"
Height="20" Width="20"
Margin="10,0,1,0">
<Image Source="{Binding LayNbArrTgBtnImg}"/>
</ToggleButton>
</StackPanel>
<Border Style="{StaticResource Border}" Margin="0,1,0,5">
@@ -515,7 +504,7 @@
Style="{StaticResource ImgButton}"/>
</StackPanel>
</Button>
</StackPanel>
</UniformGrid>
@@ -563,7 +552,7 @@
</Button>
</StackPanel>
<StackPanel Margin="1,0,0,0">
<Button ToolTip="{Binding ModifEndMsg}"
Style="{StaticResource Split_Button_Img}"
+8 -88
View File
@@ -355,33 +355,6 @@ Public Class SplitModeVM
End Set
End Property
Private m_LayNbArrTgBtn_IsChecked As Boolean = False
Public Property LayNbArrTgBtn_IsChecked As Boolean
Get
Return m_LayNbArrTgBtn_IsChecked
End Get
Set(value As Boolean)
' imposto il valore della bottone, dell'icona e del messaggio
SetLayNbArrTgBtn_IsChecked(value)
WriteMainPrivateProfileString(S_GENERAL, K_SHOWNBARROW, If(m_LayNbArrTgBtn_IsChecked, "1", "0"))
End Set
End Property
Private Sub SetLayNbArrTgBtn_IsChecked(value As Boolean)
m_LayNbArrTgBtn_IsChecked = value
If value Then
StatusOffNumbArrow(GDB_ST.ON_)
m_LayNbArrTgBtnMsg = EgtMsg(91218) ' Hide
m_LayNbArrTgBtnImg = "/Resources/NewIcons/LightArrowOn.png"
Else
StatusOffNumbArrow(GDB_ST.OFF)
m_LayNbArrTgBtnMsg = EgtMsg(91219) ' Show
m_LayNbArrTgBtnImg = "/Resources/NewIcons/LightArrowOff.png"
End If
NotifyPropertyChanged(NameOf(LayNbArrTgBtnMsg))
NotifyPropertyChanged(NameOf(LayNbArrTgBtnImg))
End Sub
#Region "SPLIT CUT"
Private m_CreateCut_IsChecked As Boolean
@@ -610,20 +583,6 @@ Public Class SplitModeVM
End Get
End Property
Private Property m_LayNbArrTgBtnMsg As String = "Show"
Public ReadOnly Property LayNbArrTgBtnMsg As String
Get
Return m_LayNbArrTgBtnMsg
End Get
End Property
Private Property m_LayNbArrTgBtnImg As String = "/Resources/NewIcons/LightArrowOn.png"
Public ReadOnly Property LayNbArrTgBtnImg As String
Get
Return m_LayNbArrTgBtnImg
End Get
End Property
#End Region ' Messages
' Definizione comandi
@@ -656,8 +615,6 @@ Public Class SplitModeVM
Sub New()
' Creo riferimento a questa classe in OmagOFFICEMap
OmagOFFICEMap.SetRefSplitModeVM(Me)
' leggo la configurazione
SetLayNbArrTgBtn_IsChecked((GetMainPrivateProfileInt(S_GENERAL, K_SHOWNBARROW, 1) <> 0))
End Sub
#End Region ' CONSTRUCTOR
@@ -819,7 +776,7 @@ Public Class SplitModeVM
End Sub
Private Sub AddTopText(ByRef sName As String)
sName &= EgtMsg(91217) ' Top
sName &= " Top"
End Sub
Private Sub RemovePauseText(ByRef sName As String)
@@ -1206,11 +1163,6 @@ Public Class SplitModeVM
' Aggiungo a numero info con identificativo della lavorazione e viceversa
EgtSetInfo(nNbrId, "MId", m_MachiningList(nI).m_nId)
EgtSetInfo(m_MachiningList(nI).m_nId, "NbrId", nNbrId)
If Not m_LayNbArrTgBtn_IsChecked Then
EgtSetStatus(nNbrId, GDB_ST.OFF)
Else
EgtSetStatus(nNbrId, GDB_ST.ON_)
End If
End If
' Se taglio con lama, metto la direzione accanto al numero
If m_MachiningList(nI).m_nType = MCH_OY.SAWING Then
@@ -1222,11 +1174,6 @@ Public Class SplitModeVM
' Aggiungo a freccia info con identificativo della lavorazione e viceversa
EgtSetInfo(nArrId, "MId", m_MachiningList(nI).m_nId)
EgtSetInfo(m_MachiningList(nI).m_nId, "ArrId", nArrId)
If Not m_LayNbArrTgBtn_IsChecked Then
EgtSetStatus(nArrId, GDB_ST.OFF)
Else
EgtSetStatus(nArrId, GDB_ST.ON_)
End If
Else
m_MachiningList(nI).m_nArrId = GDB_ID.NULL
End If
@@ -1343,13 +1290,6 @@ Public Class SplitModeVM
EgtResetMark(nNbrId)
EgtResetMark(nArrId)
End If
If Not m_LayNbArrTgBtn_IsChecked And Not bMark Then
EgtSetStatus(nNbrId, GDB_ST.OFF)
EgtSetStatus(nArrId, GDB_ST.OFF)
Else
EgtSetStatus(nNbrId, GDB_ST.ON_)
EgtSetStatus(nArrId, GDB_ST.ON_)
End If
End Sub
Private Sub ColorNumberArrow(nI As Integer)
@@ -2325,7 +2265,7 @@ Public Class SplitModeVM
If bFirstInd Then
Dim ModifStartWindow As New ModifStartEndCutWindowV
Dim ModifStartWindowVM As New ModifStartEndCutWindowVM
ModifStartWindowVM.Title = EgtMsg(90791) ' Sawing
ModifStartWindowVM.Title = "Sawing"
ModifStartWindow.DataContext = ModifStartWindowVM
ModifStartWindow.Owner = Application.Current.MainWindow
ModifStartWindowVM.SetVal(dOrigUsal)
@@ -2386,7 +2326,7 @@ Public Class SplitModeVM
If bFirstMill Then
Dim ModifStartWindow As New ModifStartEndCutWindowV
Dim ModifStartWindowVM As New ModifStartEndCutWindowVM
ModifStartWindowVM.Title = EgtMsg(90793) ' Milling
ModifStartWindowVM.Title = "Milling"
ModifStartWindow.DataContext = ModifStartWindowVM
ModifStartWindow.Owner = Application.Current.MainWindow
ModifStartWindowVM.SetVal(dOrigUsal)
@@ -2423,7 +2363,7 @@ Public Class SplitModeVM
' Dialogo richiesta valori
Dim ModifStartWnd As New ModifStartEndWjWindowV
Dim ModifStartWndVM As New ModifStartEndWjWindowVM
ModifStartWndVM.Title = EgtMsg(90798) ' Water jetting
ModifStartWndVM.Title = "Water jetting"
ModifStartWnd.DataContext = ModifStartWndVM
ModifStartWnd.Owner = Application.Current.MainWindow
ModifStartWndVM.HoleVisibility = Visibility.Visible
@@ -2509,7 +2449,7 @@ Public Class SplitModeVM
If bFirstInd Then
Dim ModifStartWindow As New ModifStartEndCutWindowV
Dim ModifStartWindowVM As New ModifStartEndCutWindowVM
ModifStartWindowVM.Title = EgtMsg(90791) ' Sawing
ModifStartWindowVM.Title = "Sawing"
ModifStartWindow.DataContext = ModifStartWindowVM
ModifStartWindow.Owner = Application.Current.MainWindow
ModifStartWindowVM.SetVal(dOrigUeal)
@@ -2564,7 +2504,7 @@ Public Class SplitModeVM
If bFirstMill Then
Dim ModifStartWindow As New ModifStartEndCutWindowV
Dim ModifStartWindowVM As New ModifStartEndCutWindowVM
ModifStartWindowVM.Title = EgtMsg(90793) ' Milling
ModifStartWindowVM.Title = "Milling"
ModifStartWindow.DataContext = ModifStartWindowVM
ModifStartWindow.Owner = Application.Current.MainWindow
ModifStartWindowVM.SetVal(dOrigUeal)
@@ -2599,7 +2539,7 @@ Public Class SplitModeVM
' Dialogo richiesta valori
Dim ModifStartWnd As New ModifStartEndWjWindowV()
Dim ModifStartWndVM As New ModifStartEndWjWindowVM
ModifStartWndVM.Title = EgtMsg(90798) ' Water jetting
ModifStartWndVM.Title = "Water jetting"
ModifStartWnd.DataContext = ModifStartWndVM
ModifStartWnd.Owner = Application.Current.MainWindow
ModifStartWndVM.HoleVisibility = Visibility.Collapsed
@@ -3007,7 +2947,7 @@ Public Class SplitModeVM
'(m_MainWindow, m_MainWindow.m_CurrentMachine.Qualities, "Quality")
Dim ModifyQualityWnd As New ModifyQualityV
Dim ModifyQuality As New ModifyQualityVM
ModifyQuality.Title = EgtMsg(91673) ' Quality
ModifyQuality.Title = "Quality"
ModifyQuality.QualityList = CurrentMachine.Qualities
ModifyQualityWnd.DataContext = ModifyQuality
ModifyQualityWnd.Owner = Application.Current.MainWindow
@@ -3100,12 +3040,6 @@ Public Class SplitModeVM
Return bOk
End Function
Friend Sub OnMouseDownScene_DoubleClick(sender As Object, e As System.Windows.Forms.MouseEventArgs)
OnMouseDownScene(sender, e)
If m_nSelected = GDB_ID.NULL Then Return
OnOff(Nothing)
End Sub
Friend Sub OnMouseDownScene(sender As Object, e As System.Windows.Forms.MouseEventArgs)
' Se tasto premuoto allora attivo la selezione multipla da Scena
Dim bKeyCtrlPressed = (Keyboard.Modifiers And ModifierKeys.Control) > 0
@@ -3605,20 +3539,6 @@ Public Class SplitModeVM
DeselectWJBridgesPart()
End If
End Sub
Friend Sub StatusOffNumbArrow(Status As GDB_ST)
For Each Item In m_MachiningList
Dim nOperId As Integer = Item.m_nId
Dim nNbrId As Integer = Item.m_nNbrId
Dim nArrId As Integer = Item.m_nArrId
Dim nInd As Integer = m_MachiningList.IndexOf(Item)
If nInd >= 0 AndAlso nInd < m_ItemList.Count AndAlso Not m_ItemList(nInd).IsSelected Then
EgtSetStatus(nNbrId, Status)
EgtSetStatus(nArrId, Status)
End If
Next
EgtDraw()
End Sub
#End Region ' EVENTS
'-----------------------------------------------------------------------------------------------
-62
View File
@@ -1,62 +0,0 @@
<EgtWPFLib5:EgtCustomWindow x:Class="ChangeTableV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:sys="clr-namespace:System;assembly=mscorlib"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize" TitleBarHeight="30" IsResizable="False"
IsMinimizable="False" WindowStartupLocation="CenterScreen" IsClosable="False"
Title="{Binding sTitle}" Height="150" Width="320">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="2*"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<ItemsControl ItemsSource="{Binding CurrTableList}">
<!--Definisco l'organizzazione dei comandi-->
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<StackPanel Orientation="Horizontal"
HorizontalAlignment="Center"
VerticalAlignment="Center"/>
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<!--Definisco il contenuto del comando-->
<ItemsControl.ItemTemplate>
<DataTemplate>
<RadioButton GroupName="TabGrp"
IsChecked="{Binding IsActive}"
Width="60" Height="60"
Style="{DynamicResource ChangeTable_ToggleButton}">
<Grid>
<!--Nome della tavole: Tab #-->
<TextBlock Text="{Binding sName}"
HorizontalAlignment="Center"
Background="Transparent">
<TextBlock.Style>
<Style TargetType="{x:Type TextBlock}">
<Setter Property="Foreground" Value="{StaticResource Omag_LightGray}"/>
<Style.Triggers>
<DataTrigger Binding="{Binding IsChecked, RelativeSource={RelativeSource AncestorType=RadioButton}}" Value="True">
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
</DataTrigger>
</Style.Triggers>
</Style>
</TextBlock.Style>
</TextBlock>
<!--Rappresentazione di una tavola di lavoro-->
<Image Source="{Binding ImgTab}" Margin="0,20,0,0"/>
</Grid>
</RadioButton>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
<UniformGrid Grid.Row="1" Columns="2">
<Button Content="Ok" Margin="5" Command="{Binding OkCommand}"
Style="{StaticResource OptionPanel_TextButton}"/>
<Button Content="Cancel" Margin="5" Command="{Binding CancelCommand}"
Style="{StaticResource OptionPanel_TextButton}"/>
</UniformGrid>
</Grid>
</EgtWPFLib5:EgtCustomWindow>
@@ -1,3 +0,0 @@
Public Class ChangeTableV
End Class
-177
View File
@@ -1,177 +0,0 @@
Public Class ChangeTableVM
Inherits VMBase
#Region "FIELDS & PROPERTIES"
Private m_refChanTableV As ChangeTableV
Public Enum EnumDialogResult
OK
CANCEL
End Enum
Private m_MyDialogResult As EnumDialogResult
Public ReadOnly Property MyDialogResult As EnumDialogResult
Get
Return m_MyDialogResult
End Get
End Property
Private m_sTitle As String = "Seleziona tavola di lavoro"
Public ReadOnly Property sTitle As String
Get
Return m_sTitle
End Get
End Property
Private m_nSelectedTable As Integer = 0
Public ReadOnly Property nSelectedTable As Integer
Get
Return m_nSelectedTable
End Get
End Property
Private m_CurrTableList As New List(Of TableToChange)
Public ReadOnly Property CurrTableList As List(Of TableToChange)
Get
Return m_CurrTableList
End Get
End Property
' Definizione Comandi
Private m_cmdOk As ICommand
Private m_cmdCancel As ICommand
#End Region ' Fields & Properties
#Region "CONSTRUCTOR"
Sub New(refV As ChangeTableV)
m_refChanTableV = refV
' Procedo alla creazione della lista delle tavole disponibili
Initialized()
End Sub
#End Region ' Constructor
#Region "METHODS"
Private Sub Initialized()
' recuepero l'inidce della tavola corrente
Dim nIndeXCurrTab As Integer = GetCurrentTable()
' creo la lista delle tavole disponibili (attivo il bottone della tavola attualmente in uso)
For nInd As Integer = 0 To GetTableCount() - 1
m_CurrTableList.Add(New TableToChange("Tab", (nInd + 1), ((nInd + 1) = nIndeXCurrTab)))
Next
End Sub
#End Region ' Methods
#Region "COMMANDS"
#Region "OkCommand"
Public ReadOnly Property OkCommand() As ICommand
Get
If m_cmdOk Is Nothing Then
m_cmdOk = New Command(AddressOf Ok)
End If
Return m_cmdOk
End Get
End Property
Private Sub Ok()
' recupero l'indice della tavola impostata
For Each ItemTab As TableToChange In CurrTableList
If ItemTab.IsActive Then
m_nSelectedTable = ItemTab.nIndex
Exit For
End If
Next
m_MyDialogResult = EnumDialogResult.OK
' procedo alla chiusura della finetra
m_refChanTableV.Close()
End Sub
#End Region ' OkCommand
#Region "CancelCommand"
Public ReadOnly Property CancelCommand() As ICommand
Get
If m_cmdCancel Is Nothing Then
m_cmdCancel = New Command(AddressOf Cancel)
End If
Return m_cmdCancel
End Get
End Property
Private Sub Cancel()
m_MyDialogResult = EnumDialogResult.CANCEL
' procedo alla chiusura della finetra
m_refChanTableV.Close()
End Sub
#End Region ' CancelCommand
#End Region ' Commands
End Class
Public Class TableToChange
Inherits VMBase
#Region "FIELDS & PROPERTIES"
Private Property m_sName As String = "Tab"
Public ReadOnly Property sName As String
Get
Return m_sName
End Get
End Property
Private m_sImgTab As String = "\Resources\NewIcons\table.png"
Public ReadOnly Property ImgTab As String
Get
Return If(m_bIsActive, "\Resources\NewIcons\table.png", "\Resources\NewIcons\tableS.png")
End Get
End Property
Private Property m_nIndex As Integer = 3
Public ReadOnly Property nIndex As Integer
Get
Return m_nIndex
End Get
End Property
Private m_bIsActive As Boolean = False
Public Property IsActive As Boolean
Get
Return m_bIsActive
End Get
Set(value As Boolean)
m_bIsActive = value
If m_bIsActive Then
m_sImgTab = "\Resources\NewIcons\table.png"
Else
m_sImgTab = "\Resources\NewIcons\tableS.png"
End If
NotifyPropertyChanged(NameOf(IsActive))
NotifyPropertyChanged(NameOf(ImgTab))
End Set
End Property
#End Region ' Fields & Properties
#Region "CONSTRUCTOR"
Public Sub New(Name As String, Ind As Integer, IsCurrent As Boolean)
m_sName = Name & " " & Ind.ToString
m_nIndex = Ind
m_bIsActive = IsCurrent
NotifyPropertyChanged(NameOf(IsActive))
End Sub
#End Region ' Constructor
End Class
+5 -4
View File
@@ -1,4 +1,5 @@
Imports EgtUILib
Imports EgtWPFLib5
Public Class MultiSelectionVM
Inherits VMBase
@@ -7,24 +8,24 @@ Public Class MultiSelectionVM
Public ReadOnly Property TitleMsg As String
Get
Return EgtMsg(91681) ' Multiple selection
Return "Multiple selection"
End Get
End Property
Public ReadOnly Property SelectionMsg As String
Get
Return EgtMsg(91682) ' Number of Parts
Return "Number of Parts"
End Get
End Property
Public ReadOnly Property OkMsg As String
Get
Return EgtMsg(91651) ' Ok
Return "Ok"
End Get
End Property
Public ReadOnly Property CancelMsg As String
Get
Return EgtMsg(91652) ' Cancel
Return "Cancel"
End Get
End Property
+19 -14
View File
@@ -39,19 +39,19 @@
<Grid HorizontalAlignment="Center"
VerticalAlignment="Center"
Margin="0,0,0,0">
Margin="0,0,0,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="5"/>
<ColumnDefinition Width="0.5"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="5"/>
<ColumnDefinition Width="0.5"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="5"/>
<RowDefinition Height="0.5"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="5"/>
<RowDefinition Height="0.5"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="5"/>
<RowDefinition Height="Auto"/>
@@ -60,7 +60,7 @@
<!--<TextBlock Name="PositioningLbl" Grid.ColumnSpan="3" VerticalAlignment="Center"
HorizontalAlignment="Center" FontSize="15" />-->
<Button Grid.Column="0" Grid.Row="0"
Style="{StaticResource OptionPanel_NestingButton}" Width="48" Height="48"
Style="{StaticResource OptionPanel_NestingButton2}" Width="48" Height="48"
Command="{Binding PartRotOnCommand}">
<Image Source="/Resources/NestingTab/PartRotOn.png" Stretch="Uniform"/>
</Button>
@@ -71,7 +71,7 @@
Width="40"/>
</Button>
<Button Grid.Column="4" Grid.Row="0"
Style="{StaticResource OptionPanel_NestingButton}" Width="48" Height="48"
Style="{StaticResource OptionPanel_NestingButton2}" Width="48" Height="48"
Command="{Binding PartRotOffCommand}">
<Image Source="/Resources/NestingTab/PartRotOff.png" Stretch="Uniform"/>
</Button>
@@ -93,10 +93,12 @@
Width="40"/>
</Button>
<EgtWPFLib5:EgtTextBox Grid.Column="0" Grid.Row="4" Width="40"
<TextBox Grid.Column="0" Grid.Row="4" Width="40" Height="20"
Text="{Binding StepMove}"
VerticalAlignment="Center"
HorizontalContentAlignment="Right"/>
HorizontalContentAlignment="Right"
Background="{StaticResource Gradient_Gray}"
Foreground="{StaticResource Omag_White}"/>
<Button Grid.Column="2" Grid.Row="4"
Style="{StaticResource OptionPanel_NestingButton}"
@@ -111,15 +113,18 @@
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<EgtWPFLib5:EgtTextBox Text="{Binding RotationAngle}" Width="40"
<TextBox Text="{Binding RotationAngle}" Width="40" Height="20"
VerticalAlignment="Center"
HorizontalContentAlignment="Left"/>
HorizontalContentAlignment="Left"
Margin="1.5,0,0,0"
Background="{StaticResource Gradient_Gray}"
Foreground="{StaticResource Omag_White}"/>
<TextBlock Grid.Column="1" Margin="2,0,0,0"
FontSize="20" Text="°"/>
FontSize="20" Text="°" Foreground="{StaticResource Omag_White}"/>
</Grid>
<Button Grid.Column="0" Grid.Row="6"
Style="{StaticResource OptionPanel_NestingButton}"
Style="{StaticResource OptionPanel_NestingButton2}"
Command="{Binding CClockwiseRotCommand}">
<Image Source="/Resources/NestingTab/CounterClockwiseRotate.png"
Width="64" Height="65" HorizontalAlignment="Center"
@@ -133,7 +138,7 @@
VerticalAlignment="Center" />
</ToggleButton>
<Button Grid.Column="4" Grid.Row="6"
Style="{StaticResource OptionPanel_NestingButton}"
Style="{StaticResource OptionPanel_NestingButton2}"
Command="{Binding ClockwiseRotCommand}">
<Image Source="/Resources/NestingTab/ClockwiseRotate.png"
Width="65" Height="65" HorizontalAlignment="Center"
+2 -321
View File
@@ -1,7 +1,5 @@
Imports System.Drawing
Imports EgtWPFLib5
Imports EgtUILib
Imports EgtWPFLib5
Imports OmagOFFICE.ChangeTableVM
Public Class NestingTabVM
Inherits VMBase
@@ -409,8 +407,6 @@ Public Class NestingTabVM
m_CsvImportWindow = New CsvWindowV(Application.Current.MainWindow, New CsvWindowVM)
m_CsvImportWindow.Show()
End If
' Per sicurezza spengo la visualizzazione di tutti i percorsi di lavorazione
HideAllMachinings()
EgtZoom(ZM.ALL)
Return True
End Function
@@ -586,212 +582,6 @@ Public Class NestingTabVM
m_bStartRot = False
End Sub
Friend Function RotateAllRawParts(dAngDeg As Double) As Boolean
' Recupero il centro del grezzo iniziale per usarlo come centro della rotazione
Dim ptCen As New Point3d
GetRawCenter(ptCen)
' Provo la rotazione
Dim bMoveOk As Boolean = True
Dim nPhase As Integer = 1
Dim nRawId As Integer = GDB_ID.NULL
While nPhase <= EgtGetPhaseCount()
EgtSetCurrPhase(nPhase)
nRawId = EgtGetFirstRawPart()
While nRawId <> GDB_ID.NULL
If EgtVerifyRawPartPhase(nRawId, nPhase) Then
' Rotazione del centro come spostamento grezzo più rotazione grezzo attorno al suo centro
Dim ptRawCen As New Point3d
EgtGetRawPartCenter(nRawId, ptRawCen)
Dim ptMovCen As New Point3d(ptRawCen)
ptMovCen.Rotate(ptCen, Vector3d.Z_AX(), dAngDeg)
If Not EgtMoveRawPart(nRawId, ptMovCen - ptRawCen) Then
bMoveOk = False
Exit While
End If
If Not EgtRotateRawPart(nRawId, Vector3d.Z_AX(), dAngDeg) Then
EgtMoveRawPart(nRawId, -(ptMovCen - ptRawCen))
bMoveOk = False
Exit While
End If
End If
nRawId = EgtGetNextRawPart(nRawId)
End While
If Not bMoveOk Then Exit While
nPhase += 1
End While
' Se rotazione impossibile, ripristino posizione dei grezzi già spostati
If Not bMoveOk Then
Dim nRevPhase As Integer = 1
Dim nRevRawId As Integer = GDB_ID.NULL
While nRevPhase <= nPhase
EgtSetCurrPhase(nRevPhase)
nRevRawId = EgtGetFirstRawPart()
While nRevRawId <> GDB_ID.NULL And (nRevPhase < nPhase Or nRevRawId <> nRawId)
If EgtVerifyRawPartPhase(nRevRawId, nRevPhase) Then
' Eseguo al contrario
EgtRotateRawPart(nRevRawId, Vector3d.Z_AX(), -dAngDeg)
Dim ptRawCen As New Point3d
EgtGetRawPartCenter(nRevRawId, ptRawCen)
Dim ptMovCen As New Point3d(ptRawCen)
ptMovCen.Rotate(ptCen, Vector3d.Z_AX(), -dAngDeg)
EgtMoveRawPart(nRevRawId, (ptMovCen - ptRawCen))
End If
nRevRawId = EgtGetNextRawPart(nRevRawId)
End While
nRevPhase += 1
End While
' Altrimenti eseguo sistemazioni
Else
' Origine della tavola
Dim ptOri As Point3d
EgtGetTableRef(1, ptOri)
' Annullo rotazioni dei grezzi e le rifaccio sulle parti componenti
Dim nRevPhase As Integer = 1
Dim nRevRawId As Integer = GDB_ID.NULL
While nRevPhase <= EgtGetPhaseCount()
EgtSetCurrPhase(nRevPhase)
nRevRawId = EgtGetFirstRawPart()
While nRevRawId <> GDB_ID.NULL
If EgtVerifyRawPartPhase(nRevRawId, nRevPhase) Then
' Eseguo al contrario
EgtRotateRawPart(nRevRawId, Vector3d.Z_AX(), -dAngDeg)
Dim ptRawCen As New Point3d
EgtGetRawPartCenter(nRevRawId, ptRawCen)
Dim ptMovCen As New Point3d(ptRawCen)
ptMovCen.Rotate(ptCen, Vector3d.Z_AX(), -dAngDeg)
EgtMoveRawPart(nRevRawId, (ptMovCen - ptRawCen))
' Rifaccio sugli oggetti contenuti nel grezzo
Dim nId As Integer = EgtGetFirstInGroup(nRevRawId)
While nId <> GDB_ID.NULL
EgtRotate(nId, ptCen, Vector3d.Z_AX(), dAngDeg, GDB_RT.GLOB)
nId = EgtGetNext(nId)
End While
' Imposto posizione esatta del grezzo dopo rotazione
Dim b3Raw As New BBox3d
EgtGetRawPartBBox(nRevRawId, b3Raw)
EgtMoveToCornerRawPart(nRevRawId, (b3Raw.Min() - ptOri) + Point3d.ORIG(), MCH_CR.BL)
End If
nRevRawId = EgtGetNextRawPart(nRevRawId)
End While
nRevPhase += 1
End While
' Ruoto opportunamente anche i dati di movimento
Dim nOpeId As Integer = EgtGetFirstActiveOperation()
While nOpeId <> GDB_ID.NULL
If EgtGetOperationType(nOpeId) = MCH_OY.DISP Then
' Recupero i gruppi con i dati
Dim nRpmId As Integer = EgtGetFirstNameInGroup(nOpeId, "Rpm*")
While nRpmId <> GDB_ID.NULL
' Recupero le informazioni
Dim vtRawMove As New Vector3d
If EgtGetInfo(nRpmId, "Mv", vtRawMove) Then
vtRawMove.Rotate(Vector3d.Z_AX(), dAngDeg)
EgtSetInfo(nRpmId, "Mv", vtRawMove)
End If
Dim vtDelta As New Vector3d
If EgtGetInfo(nRpmId, "Dt", vtDelta) Then
vtDelta.Rotate(Vector3d.Z_AX(), dAngDeg)
EgtSetInfo(nRpmId, "Dt", vtDelta)
End If
Dim dAngRotDeg As Double = 0
If EgtGetInfo(nRpmId, "Ad", dAngRotDeg) Then
EgtSetInfo(nRpmId, "Ad", dAngRotDeg + dAngDeg)
End If
' Cerco un altro gruppo
nRpmId = EgtGetNextName(nRpmId, "Rpm*")
End While
End If
nOpeId = EgtGetNextActiveOperation(nOpeId)
End While
' Ruoto anche l'eventuale foto della lastra e sistemo il riferimento sul grezzo
Dim nPhotoId = EstPhoto.GetPhoto()
If nPhotoId <> GDB_ID.NULL then
Dim dOldRot As Double = 0
EgtGetInfo(nPhotoId, "Rot", dOldRot)
EgtRotatePhoto(nPhotoId, ptCen, Vector3d.Z_AX(), dAngDeg)
EgtSetInfo(nPhotoId, "Rot", dOldRot + dAngDeg)
Dim refTxr As New Frame3d
GetPhotoTextureRef(refTxr)
Dim nSolidId = EgtGetFirstNameInGroup(EgtGetFirstRawPart(), NAME_RAW_SOLID)
EgtSetTextureFrame(nSolidId, refTxr, GDB_RT.GLOB)
End If
' Aggiorno rotazione totale
CamAuto.SetRegistrationRotation(0)
' Dichiaro grezzo per punti
EgtSetInfo(GetCurrentRaw(), KEY_RAWBYPOINTS, 1)
End If
' Ruoto i punti SpotReg disegnati in Office
If bMoveOk Then
RotateAllSpotRegistration(dAngDeg, ptCen)
End If
' Ripristino lo stato iniziale
EgtSetCurrPhase(1)
HideAllMachinings()
Return bMoveOk
End Function
' Ruoto solo gli elementi SpotReg creati nel programma OFFICE
Private Sub RotateAllSpotRegistration(dAngRot As Double, ptCen As Point3d)
Dim nId As Integer = EgtGetFirstInGroup(OmagOFFICEMap.refRawPartTabVM.m_nRegGroupId)
While nId <> GDB_ID.NULL
Dim sName As String = String.Empty
EgtGetName(nId, sName)
If Not sName.Contains("CUT") Then
EgtRotate(nId, ptCen, Vector3d.Z_AX, dAngRot)
End If
nId = EgtGetNext(nId)
End While
EgtDraw()
End Sub
Private Sub MoveAllRawParts(vtMove As Vector3d)
' Provo il movimento
Dim bMoveOk As Boolean = True
Dim nPhase As Integer = 1
Dim nRawId As Integer = GDB_ID.NULL
While nPhase <= EgtGetPhaseCount()
EgtSetCurrPhase(nPhase)
nRawId = EgtGetFirstRawPart()
While nRawId <> GDB_ID.NULL
If EgtVerifyRawPartPhase(nRawId, nPhase) Then
If Not EgtMoveRawPart(nRawId, vtMove) Then
bMoveOk = False
Exit While
End If
End If
nRawId = EgtGetNextRawPart(nRawId)
End While
If Not bMoveOk Then Exit While
nPhase += 1
End While
' Se movimento impossibile, ripristino posizione dei grezzi già spostati
If Not bMoveOk Then
Dim nRevPhase As Integer = 1
Dim nRevRawId As Integer = GDB_ID.NULL
While nRevPhase <= nPhase
EgtSetCurrPhase(nRevPhase)
nRevRawId = EgtGetFirstRawPart()
While nRevRawId <> GDB_ID.NULL And (nRevPhase < nPhase Or nRevRawId <> nRawId)
If EgtVerifyRawPartPhase(nRevRawId, nRevPhase) Then
EgtMoveRawPart(nRevRawId, -vtMove)
End If
nRevRawId = EgtGetNextRawPart(nRevRawId)
End While
nRevPhase += 1
End While
End If
If bMoveOk Then
' Traslo anche l'eventuale foto della lastra
Dim nPhotoId = EstPhoto.GetPhoto()
If nPhotoId <> GDB_ID.NULL then EgtMovePhoto(nPhotoId, vtMove)
' Muovo i punti SpotReg generati nel programma OFFICE
OmagOFFICEMap.refRawPartTabVM.MoveAllSpotRegistration(vtMove)
End If
' Ripristino lo stato iniziale
EgtSetCurrPhase(1)
HideAllMachinings()
End Sub
' verifica che la rotazione sia ammessa
Private Function RotatePartInsideBond(dAngRotDeg As Double, nIdMove As Integer) As Boolean
' Verifico se ci sono dei pezzi bloccati in rotazione
@@ -2412,14 +2202,12 @@ Public Class NestingTabVM
While nId <> GDB_ID.NULL
' Recupero l'identificativo del pezzo cui appartiene
Dim nPartId As Integer = EgtGetParent(EgtGetParent(nId))
Dim sNamePartId As String = String.Empty
EgtGetName(nPartId, sNamePartId)
Dim bPartInTable As Boolean = (EgtGetParent(nPartId) = GetRawId())
If EgtIsPart(nPartId) Or bPartInTable Then
Dim nStat As Integer = GDB_ST.ON_
EgtGetStatus(nPartId, nStat)
' verifico se l'elemento selezionato è il numero di pezzi
' verifico se l'lemento selezionato è il numero di pezzi
If EgtGetType(nId) = GDB_TY.EXT_TEXT Then
Dim NameLayer As String = String.Empty
EgtGetName(EgtGetParent(nId), NameLayer)
@@ -2451,113 +2239,6 @@ Public Class NestingTabVM
' Drag possibile
m_bDrag = True
Exit While
Else
' verifico se l'elemento selezionato è il nome della tavola
If EgtGetType(nId) = GDB_TY.EXT_TEXT AndAlso (sNamePartId = MAIN_TAB Or
sNamePartId = SECOND_TAB Or
sNamePartId = THIRD_TAB Or
sNamePartId = FORTH_TAB) Then
' Apro la finestra per la selezione della tavola da usare
Dim ChgTbV As New ChangeTableV
Dim ChgTbVM As New ChangeTableVM(ChgTbV)
ChgTbV.DataContext = ChgTbVM
ChgTbV.ShowDialog()
' se non è stata eseguita nessuna scelta esco dal ciclo
If ChgTbVM.MyDialogResult = EnumDialogResult.CANCEL Or ChgTbVM.nSelectedTable = 0 Then Exit While
' salvo l'origine della precente tavola
Dim ptOldTabOri As Point3d
EgtGetTableRef( 1, ptOldTabOri)
' recupero il nome della nuova tavola corrente
Dim sOtherTab As String = GetTableName(ChgTbVM.nSelectedTable)
EgtChangeTable(sOtherTab, True)
' Traslo anche l'eventuale foto della lastra
Dim nPhotoId = EstPhoto.GetPhoto()
If nPhotoId <> GDB_ID.NULL then
Dim ptTabOri As Point3d
EgtGetTableRef( 1, ptTabOri)
EgtMovePhoto(nPhotoId, ptTabOri - ptOldTabOri)
End If
EstCalc.AdjustAdditionalTable(True)
EgtSetMachineLook(MCH_LOOK.TAB)
' aggiorno le lavorazioni
UpdateAllMachiningsToolpaths()
' aggiorno i movimenti pezzi tra disposizioni
For nI As Integer = 1 To EgtGetPhaseCount()
EgtSetCurrPhase(nI)
Dim nDispId As Integer = EgtGetPhaseDisposition(nI)
SpecialApplyDisposition(nDispId, True)
Next
' aggiorno posizionamento ventose per lavorazioni da sotto
UpdateVacuumsForDrip()
' dichiaro tutto aggiornato
EstCalc.SetOrderMachiningFlag()
EgtSetCurrPhase(1)
' aggiorno posizione pezzi in parcheggio
Dim nPPId As Integer = EgtGetFirstPart()
While nPPId <> GDB_ID.NULL
PackPartInStore(nPPId)
nPPId = EgtGetNextPart(nPPId)
End While
' se prevista rotazione
If GetPrivateProfileInt(S_TABLE, K_CHANGETABWD, 0, CurrentMachine.sMachIniFile) = 2 Then
' Dati tavola
Dim b3Tab As New BBox3d
EgtGetTableArea(1, b3Tab)
' Box lastra
Dim b3OrigRaw As New BBox3d
GetRawBox(b3OrigRaw)
' Allargo i limiti della tavola in tutte le fasi
Const TAB_OFFS As Double = 3000
For nI As Integer = 1 To EgtGetPhaseCount()
EgtSetCurrPhase(nI)
EgtSetTableAreaOffset(TAB_OFFS, TAB_OFFS, TAB_OFFS, TAB_OFFS)
Next
' aggiorno posizionamento ventose per lavorazioni da sotto
UpdateVacuumsForDrip()
' dichiaro tutto aggiornato
EstCalc.SetOrderMachiningFlag()
EgtSetCurrPhase(1)
' Rotazione
Dim dAngRot As Double = If(sOtherTab = SECOND_TAB, 180, -180)
If Not RotateAllRawParts(dAngRot) Then
'm_CurrProjPage.SetWarningMessage(EgtMsg(90339)) 'Rotazione impossibile
End If
' Traslazione per riportare la lastra nella stessa posizione rispetto all'angolo BL che diventa TR e viceversa
Dim b3Raw As New BBox3d
GetRawBox(b3Raw)
Dim vtMove As Vector3d
If sOtherTab = SECOND_TAB Then
Dim vtDiffIni As Vector3d = b3OrigRaw.Min() - b3Tab.Min()
Dim vtDiffFin As Vector3d = b3Tab.Max() - b3Raw.Max()
vtMove = vtDiffFin - vtDiffIni
Else
Dim vtDiffIni As Vector3d = b3Tab.Max() - b3OrigRaw.Max()
Dim vtDiffFin As Vector3d = b3Raw.Min() - b3Tab.Min()
vtMove = -(vtDiffFin - vtDiffIni)
End If
vtMove.z = 0
MoveAllRawParts(vtMove)
' Ripristino i limiti della tavola in tutte le fasi
For nI As Integer = 1 To EgtGetPhaseCount()
EgtSetCurrPhase(nI)
EgtSetTableAreaOffset(0, 0, 0, 0)
Next
EgtSetCurrPhase(1)
HideAllMachinings()
End If
' visualizzazione
EgtZoom(ZM.ALL)
' Elimino il datacontext della finestra per la selezione della tavola
ChgTbVM = Nothing
Exit While
End If
End If
nId = EgtGetNextObjInSelWin()
End While
+7 -5
View File
@@ -10,10 +10,12 @@
d:DesignHeight="300" d:DesignWidth="300"
Title="OmagPHOTO"
ResizeMode="NoResize" ShowInTaskbar="False">
<DockPanel>
<!--Progetto corrente-->
<EgtPHOTOLib:ProjectSlabV DataContext="{StaticResource ProjectSlabVM}"/>
<EgtPHOTOLib:ProjectSlabV DataContext="{StaticResource ProjectSlabVM}"/>
<!--<DockPanel>
<Grid>
<ContentControl Content="{Binding OmagPhotoContent}"/>
</Grid>
</DockPanel>-->
</DockPanel>
</EgtWPFLib5:EgtCustomWindow>
+5 -3
View File
@@ -2,11 +2,13 @@
'Private m_OmagPhotoVM As OmagPhotoVM
'Public Sub New(Owner As Window)
'Sub New(Owner As Window, OmagPhotoVM As OmagPhotoVM)
' MyBase.New(Owner)
' 'This call Is required by the designer.
' ' This call is required by the designer.
' InitializeComponent()
' Me.DataContext = OmagPhotoVM
' ' Assegno al riferimento locale al VM il VM preso dal DataContext
' m_OmagPhotoVM = OmagPhotoVM
'End Sub
End Class
+13 -24
View File
@@ -43,7 +43,7 @@ Public Class RawPartTabVM
Private m_nTempLay As Integer = GDB_ID.NULL
' Layer per crocette dei punti REG
Friend m_nRegGroupId As Integer = GDB_ID.NULL
Private m_nRegGroupId As Integer = GDB_ID.NULL
' Numero di spot inseriti nel grezzo corrente
Private m_nCountSpot As Integer = 0
' Gruppo Spot attualmente selezionato
@@ -904,7 +904,8 @@ Public Class RawPartTabVM
End Set
End Property
Private m_CurrMach_Background As Brush = DirectCast(New BrushConverter().ConvertFrom("#1C1D22"), SolidColorBrush)
'Private m_CurrMach_Background As Brush = DirectCast(New BrushConverter().ConvertFrom("#1C1D22"), SolidColorBrush)
Private m_CurrMach_Background As Brush = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
Public Property CurrMach_Background As Brush
Get
Return m_CurrMach_Background
@@ -1091,12 +1092,9 @@ Public Class RawPartTabVM
' Creo riferimento a questa classe in OmagOFFICEMap
OmagOFFICEMap.SetRefRawPartTabVM(Me)
If OmagOFFICEMap.refMainWindowVM.MainWindowM.m_SlabDB Then
' Me.OmagPhoto = New OmagPhotoV(Application.Current.MainWindow())
'Me.OmagPhoto = New OmagPhotoV(Application.Current.MainWindow(), New OmagPhotoVM)
Me.OmagPhoto = New OmagPhotoV
If Not PhotoMap.ContinueApplication Then
EgtOutLog("Key protection denied to acces to DB photo, set configuration to image directory")
End
End If
If Not PhotoMap.ContinueApplication Then End
End If
' Aggiungo voci alla lista di tipi di definizione grezzo
m_TypeList.Add(EgtMsg(MSG_RAWPARTPAGEUC + 1))
@@ -1978,14 +1976,10 @@ Public Class RawPartTabVM
Return True
End Function
Friend Sub MoveAllSpotRegistration(vtMove As Vector3d, Optional bOnlyOfficeSpot As Boolean = True)
Dim nId As Integer = EgtGetFirstInGroup(OmagOFFICEMap.refRawPartTabVM.m_nRegGroupId)
Private Sub MoveAllSpotRegistration(vtMove As Vector3d)
Dim nId As Integer = EgtGetFirstInGroup(m_nRegGroupId)
While nId <> GDB_ID.NULL
Dim sName As String = String.Empty
EgtGetName(nId, sName)
If Not sName.Contains("CUT") Or Not bOnlyOfficeSpot Then
EgtMove(nId, vtMove)
End If
EgtMove(nId, vtMove)
nId = EgtGetNext(nId)
End While
EgtDraw()
@@ -2107,7 +2101,8 @@ Public Class RawPartTabVM
OmagOFFICEMap.refOptionPanelVM.MachTabIsEnabled = True
OmagOFFICEMap.refOptionPanelVM.SimulTabIsEnabled = True
OmagOFFICEMap.refOptionPanelVM.RawPart_Background = OmagOFFICEDictionary.TabControl_Header_Background
CurrMach_Background = DirectCast(New BrushConverter().ConvertFrom("#1C1D22"), SolidColorBrush)
'CurrMach_Background = DirectCast(New BrushConverter().ConvertFrom("#1C1D22"), SolidColorBrush)
CurrMach_Background = New LinearGradientBrush(CType(ColorConverter.ConvertFromString("#808080"), Color), CType(ColorConverter.ConvertFromString("#909090"), Color), New Point(0.0, 0.0), New Point(0.0, 1.1))
Else
OmagOFFICEMap.refOptionPanelVM.NestTabIsEnabled = False
OmagOFFICEMap.refOptionPanelVM.MachTabIsEnabled = False
@@ -2262,13 +2257,6 @@ Public Class RawPartTabVM
PhotoMap.refSearchPanelVM.InitSearchPanel()
' inizializzo la ricerca a tutti le lastre di tipo "AVAILABLE" (=1)
PhotoMap.refSearchPanelVM.State = 1
' Resetto la data corrente per la prima ricerca
PhotoMap.refSearchPanelVM.StartAddedDate = Nothing
PhotoMap.refSearchPanelVM.NotifyPropertyChanged("StartAddedDate")
PhotoMap.refSearchPanelVM.EndAddedDate = Nothing
PhotoMap.refSearchPanelVM.NotifyPropertyChanged("EndAddedDate")
PhotoMap.refSearchPanelVM.Search()
' inserisco in elenco solo i materiali della macchina corrente
AddHandler PhotoMap.refOptionPanelVM.SlabIsSelectedOFFICE, AddressOf OmagOFFICEMap.refRawPartTabVM.ClosePhotoWnd
@@ -2278,9 +2266,10 @@ Public Class RawPartTabVM
m_RefreshTimer.Interval = TimeSpan.FromMilliseconds(2000)
m_RefreshTimer.Start()
' apro la finestra per accedere al DB delle lastre (Devo crea una nuova istanza perchè la chiusura elimina la stessa)
' apro la finestra per accedere al DB delle lastre
Me.OmagPhoto = New OmagPhotoV
Me.OmagPhoto.ShowDialog()
OmagPhoto.ShowDialog()
m_RefreshTimer.Stop()
EgtSetCurrentContext(EgtPHOTOLib.MainData.PreviousContext)
+2 -1
View File
@@ -3,7 +3,8 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:OmagOFFICE="clr-namespace:OmagOFFICE"
Background="{StaticResource Omag_DarkGray}">
Background="{StaticResource Gradient_Gray}">
<!--Background="{StaticResource Omag_DarkGray}"-->
<DockPanel x:Name="LEFTTRAY" DockPanel.Dock="Left" Background="Transparent">
<OmagOFFICE:OptionPanelV DataContext="{StaticResource OptionPanelVM}"
Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 703 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 637 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 610 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

+47 -51
View File
@@ -1,60 +1,56 @@
<EgtWPFLib5:EgtCustomWindow x:Class="SelectTableWindowV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize" TitleBarHeight="30" IsResizable="False"
IsMinimizable="False" WindowStartupLocation="CenterScreen" IsClosable="False"
Title="{Binding Title}" Height="150" Width="320">
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
IsClosable="False"
IsMinimizable="False"
ShowInTaskbar="False"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
SizeToContent="WidthAndHeight"
Title="{Binding Title}"
WindowStartupLocation="CenterOwner" ResizeMode="NoResize">
<Grid>
<Grid HorizontalAlignment="Center"
VerticalAlignment="Center"
Margin="10,10,10,20">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="2*"/>
<RowDefinition Height="1*"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<ItemsControl ItemsSource="{Binding CurrTableList}">
<!--Definisco l'organizzazione dei comandi-->
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<StackPanel Orientation="Horizontal"
HorizontalAlignment="Center"
VerticalAlignment="Center"/>
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<!--Definisco il contenuto del comando-->
<ItemsControl.ItemTemplate>
<DataTemplate>
<RadioButton GroupName="TabGrp"
IsChecked="{Binding IsActive}"
Width="60" Height="60"
Style="{DynamicResource ChangeTable_ToggleButton}">
<Grid>
<!--Nome della tavole: Tab #-->
<TextBlock Text="{Binding sName}"
HorizontalAlignment="Center"
Background="Transparent">
<TextBlock.Style>
<Style TargetType="{x:Type TextBlock}">
<Setter Property="Foreground" Value="{StaticResource Omag_LightGray}"/>
<Style.Triggers>
<DataTrigger Binding="{Binding IsChecked, RelativeSource={RelativeSource AncestorType=RadioButton}}" Value="True">
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
</DataTrigger>
</Style.Triggers>
</Style>
</TextBlock.Style>
</TextBlock>
<!--Rappresentazione di una tavola di lavoro-->
<Image Source="{Binding ImgTab}" Margin="0,20,0,0"/>
</Grid>
</RadioButton>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
<Button Grid.Row="1" Content="Ok" Margin="5"
Command="{Binding OkCommand}"
Style="{StaticResource OptionPanel_TextButton}"/>
<TextBlock Text="{Binding WndMsg}"
FontSize="18"
Grid.ColumnSpan="3"
Margin="0,0,0,10"/>
<Button Grid.Column="0" Grid.Row="1"
Content="1" FontSize="40"
Style="{StaticResource OptionPanel_NestingButton}"
Command="{Binding Table_Command}"
CommandParameter="1"
Margin="10,0,10,0">
</Button>
<Button Grid.Column="1" Grid.Row="1"
Content="2" FontSize="40"
Style="{StaticResource OptionPanel_NestingButton}"
Command="{Binding Table_Command}"
CommandParameter="2"
Margin="10,0,10,0">
</Button>
<Button Grid.Column="2" Grid.Row="1"
Content="3" FontSize="40"
Style="{StaticResource OptionPanel_NestingButton}"
Command="{Binding Table_Command}"
CommandParameter="3"
Visibility="{Binding Table3_Visibility}"
Margin="10,0,10,0">
</Button>
</Grid>
</EgtWPFLib5:EgtCustomWindow>
@@ -1,6 +1,7 @@
Public Class SelectTableWindowV
Private WithEvents m_SelectTableWindowVM As SelectTableWindowVM
Public m_SelTable As Integer
Sub New(Owner As Window, SelectTableWindowVM As SelectTableWindowVM)
MyBase.New(Owner)
@@ -12,6 +13,7 @@
End Sub
Private Sub CloseWindow(DialogResult As Integer) Handles m_SelectTableWindowVM.m_CloseWindow
m_SelTable = DialogResult
Me.DialogResult = True
End Sub
+27 -33
View File
@@ -1,24 +1,26 @@
Imports EgtUILib
Imports EgtWPFLib5
Public Class SelectTableWindowVM
Inherits VMBase
#Region "FIELDS & PROPERTIES"
Public Enum TableNumOpt As Integer
TWO = 2
THREE = 3
End Enum
Friend Event m_CloseWindow(DialogResult As Integer)
Private m_nSelectedTable As Integer = 0
Public ReadOnly Property nSelectedTable As Integer
Private m_Table3_Visibility As Visibility
Public Property Table3_Visibility As Visibility
Get
Return m_nSelectedTable
End Get
End Property
Private m_CurrTableList As New List(Of TableToChange)
Public ReadOnly Property CurrTableList As List(Of TableToChange)
Get
Return m_CurrTableList
Return m_Table3_Visibility
End Get
Set(value As Visibility)
m_Table3_Visibility = value
End Set
End Property
#Region "Messages"
@@ -38,49 +40,41 @@ Public Class SelectTableWindowVM
#End Region
' Definizione comandi
Private m_cmdOk As ICommand
Private m_cmdTable As ICommand
#End Region ' FIELDS & PROPERTIES
#Region "CONSTRUCTOR"
Sub New()
' recuepero l'inidce della tavola corrente
Dim nIndeXCurrTab As Integer = GetCurrentTable()
' creo la lista delle tavole disponibili (attivo il bottone della tavola attualmente in uso)
For nInd As Integer = 0 To GetTableCount() - 1
m_CurrTableList.Add(New TableToChange("Tab", (nInd + 1), ((nInd + 1) = nIndeXCurrTab)))
Next
Sub New(nTableNum As TableNumOpt)
If nTableNum = TableNumOpt.TWO Then
m_Table3_Visibility = Visibility.Collapsed
Else
m_Table3_Visibility = Visibility.Visible
End If
NotifyPropertyChanged("Table3_Visibility")
End Sub
#End Region ' CONSTRUCTOR
#Region "COMMANDS"
#Region "OkCommand"
#Region "Table"
Public ReadOnly Property OkCommand() As ICommand
Public ReadOnly Property Table_Command As ICommand
Get
If m_cmdOk Is Nothing Then
m_cmdOk = New Command(AddressOf Ok)
If m_cmdTable Is Nothing Then
m_cmdTable = New Command(AddressOf Table)
End If
Return m_cmdOk
Return m_cmdTable
End Get
End Property
Private Sub Ok(ByVal param As Object)
' recupero l'indice della tavola impostata
For Each ItemTab As TableToChange In CurrTableList
If ItemTab.IsActive Then
m_nSelectedTable = ItemTab.nIndex
Exit For
End If
Next
' procedo alla chiusura della finetra
Public Sub Table(ByVal param As Object)
RaiseEvent m_CloseWindow(CInt(param))
End Sub
#End Region ' OkCommand
#End Region ' DrawCommand
#End Region ' COMMANDS
+7 -7
View File
@@ -70,7 +70,7 @@ Public Class SideEntityControlVM
sMsg = EgtMsg(91653)
ElseIf m_Mode = SideEntityControlVM.ModeOpt.ALZANDFRONT Then
' Alz
sMsg = EgtMsg(91674)
sMsg = "Alz."
End If
Return sMsg
End Get
@@ -87,7 +87,7 @@ Public Class SideEntityControlVM
sMsg = EgtMsg(91654)
ElseIf m_Mode = SideEntityControlVM.ModeOpt.ALZANDFRONT Then
' Front
sMsg = EgtMsg(91675)
sMsg = "Front."
End If
Return sMsg
End Get
@@ -617,7 +617,7 @@ Public Class SideEntityControlVM
ElseIf m_Mode = ModeOpt.FILOTOP Then
Parameter1Msg = EgtMsg(MSG_IMPORTPAGEUC + 10) ' Offset
Parameter2Msg = EgtMsg(MSG_IMPORTPAGEUC + 11) ' Depth
Parameter5Msg = EgtMsg(91676) ' Round Off
Parameter5Msg = "Round Off"
m_dOffsetFiloTop = GetMainPrivateProfileDouble(S_SIDES, K_FILOTOPOFFSET, 5)
m_dDepthFiloTop = GetMainPrivateProfileDouble(S_SIDES, K_FILOTOPDEPTH, 5)
m_bCornerRadius = GetMainPrivateProfileInt(S_SIDES, K_FILOTOPROUNDOFF, 0) <> 0
@@ -646,9 +646,9 @@ Public Class SideEntityControlVM
ElseIf m_Mode = ModeOpt.ALZANDFRONT Then
' definisco i nomi dei campi
Parameter1Msg = EgtMsg(91677) ' Spessore
Parameter2Msg = EgtMsg(91678) ' Altezza
Parameter3Msg = EgtMsg(91679) ' Delta Ang.
Parameter1Msg = "Spessore"
Parameter2Msg = "Altezza"
Parameter3Msg = "Delta Ang."
' carico i valori letti da file ini
m_HeightA = GetMainPrivateProfileDouble("Alz&Front", "A_Height", 0)
m_HeightF = GetMainPrivateProfileDouble("Alz&Front", "F_Height", 0)
@@ -1844,7 +1844,7 @@ Public Class SideEntityControlVM
Dim sMsg As String = String.Empty
' eseguo la funzione per il disegno della componente (CMP_Draw)
If Not EgtLuaExecLine("CMP_Draw" & "(true)") Then
sMsg = EgtMsg(91680) ' Error in component execution
sMsg = "Error in component execution"
'm_bDrawOk = False
Else
EgtLuaGetGlobStringVar("CMP" & ".MSG", sMsg)
+2 -2
View File
@@ -456,6 +456,7 @@ Public Class TopCommandBarVM
If String.IsNullOrEmpty(sFilePath) Then EgtGetCurrFilePath(sFilePath)
Dim nPartInRawsProj As Integer = 0
Dim nGrpId = EgtGetFirstMachGroup()
While nGrpId <> GDB_ID.NULL
' Imposto la macchinata corrente
EgtSetCurrMachGroup(nGrpId)
@@ -467,6 +468,7 @@ Public Class TopCommandBarVM
End While
nGrpId = EgtGetNextMachGroup(nGrpId)
End While
nGrpId = EgtGetFirstMachGroup()
While nGrpId <> GDB_ID.NULL
' percorso progetto
@@ -482,8 +484,6 @@ Public Class TopCommandBarVM
EgtOutLog(" NbrProjParts:" & nPartInRawsProj.ToString)
' Reimposto la macchina corrente
EgtSetCurrMachGroup(CurrGrpId)
' Nascondo tutte le lavorazioni
CamAuto.HideAllMachinings()
End Sub
End Class
+140 -76
View File
@@ -45,12 +45,29 @@
<SolidColorBrush x:Key="Omag_Green" Color="LawnGreen" />
<SolidColorBrush x:Key="Omag_VeryLightGray" Color="#FFF2F2F2" />
<SolidColorBrush x:Key="Omag_LightGray" Color="LightGray" />
<SolidColorBrush x:Key="Omag_Gray" Color="#FF9E9E9E" />
<SolidColorBrush x:Key="Omag_DarkGray" Color="#484D55" />
<SolidColorBrush x:Key="Omag_Gray" Color="#808080" />
<SolidColorBrush x:Key="Omag_DarkGray" Color="#484D55" />
<SolidColorBrush x:Key="Omag_White" Color="#FFFFFFFF" />
<SolidColorBrush x:Key="Omag_Black" Color="#1C1D22" />
<Thickness x:Key="BorderBtn_Thickness">0</Thickness>
<LinearGradientBrush x:Key="Gradient_Gray" StartPoint="0,0" EndPoint="1500,1500" MappingMode="Absolute">
<GradientStop Color="#808080" Offset="0.7"/>
<GradientStop Color="#505050" Offset="0.3"/>
</LinearGradientBrush>
<LinearGradientBrush x:Key="Gradient_Gray_Button" StartPoint="0,0" EndPoint="1,1">
<GradientStop Color="#808080" Offset="0"/>
<GradientStop Color="#909090" Offset="0.5"/>
</LinearGradientBrush>
<LinearGradientBrush x:Key="Combo_Gradient">
<GradientStop Color="#808080" Offset="0"/>
<GradientStop Color="#909090" Offset="1"/>
<GradientStop Color="#909090" Offset="0.50"/>
<GradientStop Color="#808080" Offset="0.95"/>
</LinearGradientBrush>
<Thickness x:Key="BorderBtn_Thickness">0.25</Thickness>
<Thickness x:Key="BorderGpBx_Thickness">0.25</Thickness>
<Thickness x:Key="BorderBrd_Thickness">0.5</Thickness>
@@ -68,7 +85,8 @@
<!--Colore del contorno quando il Mouse è sopra la TextBox-->
<LinearGradientBrush x:Key="BrushBorderIsMouseOverTText" EndPoint="0,20" MappingMode="Absolute" StartPoint="0,0">
<GradientStop Color="#1C1D22" Offset="0.05"/>
<!--<GradientStop Color="#1C1D22" Offset="0.05"/>-->
<GradientStop Color="#484D55" Offset="0.05"/>
<GradientStop Color="#1C1D22" Offset="0.07"/>
</LinearGradientBrush>
@@ -128,8 +146,9 @@
<SolidColorBrush x:Key="Button.Disabled.Foreground" Color="#FF838383"/>
<Style TargetType="{x:Type Button}">
<Setter Property="FocusVisualStyle" Value="{StaticResource FocusVisual}"/>
<Setter Property="Background" Value="{StaticResource Button.Static.Background}"/>
<Setter Property="BorderBrush" Value="{StaticResource Button.Static.Border}"/>
<!--<Setter Property="Background" Value="{StaticResource Button.Static.Background}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderBrush" Value="{StaticResource Button.Static.Border}"/>
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<Setter Property="HorizontalContentAlignment" Value="Center"/>
@@ -297,15 +316,17 @@
<Style x:Key="ToolBar_TextButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="30"/>
<Setter Property="Width" Value="80"/>
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}" />
</Style>
<Style x:Key="OptionPanel_Button" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="40"/>
<Setter Property="Width" Value="40"/>
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type Button}">
@@ -360,8 +381,9 @@
<Style x:Key="Split_Button_Img" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="42"/>
<Setter Property="Width" Value="42"/>
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type Button}">
@@ -389,8 +411,9 @@
<Style x:Key="Nest_Button_Img" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="45"/>
<Setter Property="Width" Value="45"/>
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
</Style>
<Style x:Key="Simul_Button_Img" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
@@ -403,8 +426,9 @@
<Style x:Key="OptionPanel_TextButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="30"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type Button}">
@@ -439,8 +463,9 @@
<Style x:Key="SimulPanel_TextButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="30"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
</Style>
<Style x:Key="OptionPanel_TextWrapButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
@@ -452,11 +477,20 @@
<Style x:Key="OptionPanel_NestingButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="50"/>
<Setter Property="Width" Value="50"/>
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
</Style>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
</Style>
<Style x:Key="DrawImport_NestingButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Style x:Key="OptionPanel_NestingButton2" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="50"/>
<Setter Property="Width" Value="50"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
</Style>
<Style x:Key="DrawImport_NestingButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="50"/>
<Setter Property="Width" Value="50"/>
<Setter Property="Background" Value="Transparent"/>
@@ -466,11 +500,20 @@
<Style x:Key="OptionPanel_MoveButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="55"/>
<Setter Property="Width" Value="55"/>
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
</Style>
<Style x:Key="CompoWindow_Button" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Style x:Key="OptionPanel_MoveButton2" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="55"/>
<Setter Property="Width" Value="55"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
</Style>
<Style x:Key="CompoWindow_Button" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Height" Value="40"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="Background" Value="#636974"/>
@@ -487,8 +530,9 @@
<Style TargetType="{x:Type ToggleButton}">
<Setter Property="FocusVisualStyle" Value="{StaticResource FocusVisual}"/>
<Setter Property="Background" Value="#636974"/>
<Setter Property="BorderBrush" Value="#636974"/>
<!--<Setter Property="Background" Value="#636974"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderBrush" Value="#636974"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
@@ -576,7 +620,8 @@
<Style x:Key="OptionPanel_NestingToggleButton" TargetType="{x:Type ToggleButton}" BasedOn="{StaticResource {x:Type ToggleButton}}">
<Setter Property="Height" Value="50"/>
<Setter Property="Width" Value="50"/>
</Style>
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
</Style>
<Style x:Key="DrawImport_NestingToggleButton" TargetType="{x:Type ToggleButton}" BasedOn="{StaticResource {x:Type ToggleButton}}">
<Setter Property="Height" Value="50"/>
@@ -595,12 +640,6 @@
<Setter Property="Height" Value="40"/>
</Style>
<Style x:Key="ChangeTable_ToggleButton" TargetType="{x:Type ToggleButton}" BasedOn="{StaticResource {x:Type ToggleButton}}">
<Setter Property="Height" Value="50"/>
<Setter Property="Width" Value="50"/>
<Setter Property="Background" Value="Transparent"/>
</Style>
<Style x:Key="Option_ColorButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Padding" Value="5"/>
<Setter Property="HorizontalContentAlignment" Value="Center"/>
@@ -673,17 +712,23 @@
<Setter Property="HorizontalContentAlignment" Value="Right"/>
<Setter Property="ExplicitUpdateSource" Value="EnterKeyPress"/>
<!--Nuovi Parametri-->
<Setter Property="BackgroundBrdEnable" Value="{StaticResource Omag_Black}"/>
<Setter Property="BackgroundBrdDisable" Value="{StaticResource Omag_Black}"/>
<!--<Setter Property="BackgroundBrdEnable" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="BackgroundBrdEnable" Value="{StaticResource Gradient_Gray_Button}"/>
<!--<Setter Property="BackgroundBrdDisable" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="BackgroundBrdDisable" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderBrushIsMouseOver" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderBrushIsFocused" Value="{StaticResource Omag_White}"/>
<Setter Property="GeneralBorderBrush" Value="{StaticResource BrushBorderIsMouseOverTText}"/>
<Setter Property="BackgroundTxBlDisable" Value="{StaticResource BrushBorderIsMouseOverTText}"/>
<!--<Setter Property="GeneralBorderBrush" Value="{StaticResource BrushBorderIsMouseOverTText}"/>-->
<Setter Property="GeneralBorderBrush" Value="{StaticResource Gradient_Gray_Button}"/>
<!--<Setter Property="BackgroundTxBlDisable" Value="{StaticResource BrushBorderIsMouseOverTText}"/>-->
<Setter Property="BackgroundTxBlDisable" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="ForegroundTxBlEnable" Value="{StaticResource Omag_White}"/>
<Setter Property="ForegroundTxBlDisable" Value="{StaticResource Omag_Gray}"/>
<Setter Property="GeneralForeground" Value="{StaticResource Omag_White}"/>
<Setter Property="GeneralBackground" Value="{StaticResource Omag_Black}"/>
</Style>
<!--<Setter Property="ForegroundTxBlDisable" Value="{StaticResource Omag_Gray}"/>-->
<Setter Property="ForegroundTxBlDisable" Value="{StaticResource Omag_White}"/>
<Setter Property="GeneralForeground" Value="{StaticResource Omag_White}"/>
<!--<Setter Property="GeneralBackground" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="GeneralBackground" Value="{StaticResource Gradient_Gray_Button}"/>
</Style>
<Style x:Key="ToolsTextBox" TargetType="{x:Type EgtWPFLib5:EgtTextBox}" BasedOn="{StaticResource {x:Type EgtWPFLib5:EgtTextBox}}">
<Setter Property="Margin" Value="0,0,5,0"/>
@@ -711,8 +756,9 @@
</Style>
<Style x:Key="AxisTextBox" TargetType="{x:Type TextBox}" BasedOn="{StaticResource {x:Type TextBox}}">
<Setter Property="Background" Value="#2D3036"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<!--<Setter Property="Background" Value="#2D3036"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="IsReadOnly" Value="True"/>
<Setter Property="IsEnabled" Value="False"/>
<Setter Property="TextAlignment" Value="Right"/>
@@ -800,10 +846,11 @@
<Style TargetType="{x:Type EgtWPFLib5:EgtCustomWindow}" BasedOn="{StaticResource {x:Type EgtWPFLib5:EgtCustomWindow}}">
<Setter Property="TitleBarHeight" Value="32"/>
<!--<Setter Property="TitleBarBrush" Value="{StaticResource Omag_LightGray}"/>
<Setter Property="BorderBrush" Value="{StaticResource Omag_Gray}"/>-->
<Setter Property="Background" Value ="{StaticResource Omag_DarkGray}"/>
<Setter Property="TitleBarForeground" Value="{StaticResource Omag_White}" />
<Setter Property="TitleBarBrush" Value="{StaticResource Omag_LightGray}"/>
<!--<Setter Property="BorderBrush" Value="{StaticResource Omag_Gray}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray}"/>
<!--<Setter Property="Background" Value ="{StaticResource Omag_DarkGray}"/>-->
<Setter Property="TitleBarForeground" Value="{StaticResource Omag_White}" />
<Setter Property="TitleBarBrush" Value="{StaticResource BrushBorderIsMouseOverTText}" />
<Setter Property="BorderBrush" Value="Transparent" />
</Style>
@@ -812,10 +859,13 @@
<Setter Property="TitleBarHeight" Value="32"/>
<!--<Setter Property="TitleBarBrush" Value="{StaticResource Omag_LightGray}"/>
<Setter Property="BorderBrush" Value="{StaticResource Omag_Gray}"/>-->
<Setter Property="Background" Value ="{StaticResource Omag_DarkGray}"/>
<Setter Property="TitleBarForeground" Value="{StaticResource Omag_White}" />
<Setter Property="TitleBarBrush" Value="{StaticResource Omag_DarkGray}" />
<Setter Property="BorderBrush" Value="Transparent" />
<!--<Setter Property="Background" Value ="{StaticResource Omag_DarkGray}"/>-->
<Setter Property="Background" Value ="{StaticResource Gradient_Gray}"/>
<Setter Property="TitleBarForeground" Value="{StaticResource Omag_White}" />
<!--<Setter Property="TitleBarBrush" Value="{StaticResource Omag_DarkGray}" />-->
<!--<Setter Property="TitleBarBrush" Value="{StaticResource Omag_Gray}" />-->
<Setter Property="TitleBarBrush" Value="{StaticResource Gradient_Gray}"/>
<Setter Property="BorderBrush" Value="Transparent" />
</Style>
<!-- ______________________________________________________________________________________________________________________________________________ -->
@@ -826,24 +876,27 @@
<!--<Setter Property="Background" Value="{StaticResource Omag_Gray}"/>
<Setter Property="BorderBrush" Value="{StaticResource Omag_Gray}"/>-->
<Setter Property="Background" Value="Transparent"/>
<Setter Property="BorderBrush" Value="{StaticResource Omag_DarkGray}"/>
<Setter Property="BorderThickness" Value="0"/>
<!--<Setter Property="BorderBrush" Value="{StaticResource Omag_DarkGray}"/>-->
<Setter Property="BorderBrush" Value="{StaticResource Gradient_Gray}"/>
<Setter Property="BorderThickness" Value="0"/>
</Style>
<Style x:Key="Machine_EgtFloatingPanel" TargetType="{x:Type EgtFloating:EgtFloatingPanel}" BasedOn="{StaticResource {x:Type EgtFloating:EgtFloatingPanel}}">
<!--<Setter Property="Background" Value="{StaticResource Omag_Gray}"/>
<Setter Property="BorderBrush" Value="{StaticResource Omag_Gray}"/>-->
<Setter Property="Background" Value="Transparent"/>
<Setter Property="BorderBrush" Value="{StaticResource Omag_DarkGray}"/>
<Setter Property="BorderThickness" Value="0"/>
<!--<Setter Property="BorderBrush" Value="{StaticResource Omag_DarkGray}"/>-->
<Setter Property="BorderBrush" Value="{StaticResource Gradient_Gray}"/>
<Setter Property="BorderThickness" Value="0"/>
</Style>
<Style x:Key="Option_EgtFloatingPanel" TargetType="{x:Type EgtFloating:EgtFloatingPanel}" BasedOn="{StaticResource {x:Type EgtFloating:EgtFloatingPanel}}">
<Setter Property="IsToolBar" Value="False"/>
<Setter Property="TitleBarOrientation" Value="Vertical"/>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="BorderBrush" Value="{StaticResource Omag_DarkGray}"/>
<Setter Property="BorderThickness" Value="0"/>
<!--<Setter Property="BorderBrush" Value="{StaticResource Omag_DarkGray}"/>-->
<Setter Property="BorderBrush" Value="{StaticResource Gradient_Gray}"/>
<Setter Property="BorderThickness" Value="0"/>
</Style>
<!-- ______________________________________________________________________________________________________________________________________________ -->
@@ -1133,8 +1186,9 @@
</Style>
<Style TargetType="{x:Type ComboBox}">
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="Height" Value="25" />
@@ -1194,17 +1248,21 @@
</Style>
<Style x:Key="Raw_ComboBox" TargetType="{x:Type ComboBox}" BasedOn="{StaticResource {x:Type ComboBox}}">
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Combo_Gradient}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="Height" Value="25" />
<Setter Property="Width" Value="Auto" />
</Style>
<Style x:Key="OptionWnd_ComboBox" TargetType="{x:Type ComboBox}" BasedOn="{StaticResource {x:Type ComboBox}}">
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="Height" Value="25" />
@@ -1212,8 +1270,9 @@
</Style>
<Style x:Key="MachiningsComboBox" TargetType="{x:Type ComboBox}" BasedOn="{StaticResource {x:Type ComboBox}}">
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="Height" Value="25" />
@@ -1222,8 +1281,9 @@
</Style>
<Style x:Key="MachiningsToolComboBox" TargetType="{x:Type ComboBox}" BasedOn="{StaticResource {x:Type ComboBox}}">
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="Height" Value="25" />
@@ -1257,11 +1317,12 @@
<ControlTemplate TargetType="{x:Type TabItem}">
<Grid>
<Border Name="border" Margin="1,0,0,0" BorderThickness="0" CornerRadius="0"
Background="{StaticResource Omag_DarkGray}"
BorderBrush="{StaticResource Omag_Gray}">
Background="{StaticResource Gradient_Gray_Button}"
BorderBrush="{StaticResource Gradient_Gray_Button}">
<ContentPresenter x:Name="contentPresenter" VerticalAlignment="Center" HorizontalAlignment="Center"
ContentSource="Header" RecognizesAccessKey="True"/>
</Border>
<!--Background="{StaticResource Omag_DarkGray}"-->
</Border>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsEnabled" Value="False">
@@ -1269,9 +1330,11 @@
<Setter Property="BorderBrush" TargetName="border" Value="#FFADB2B5"/>
</Trigger>
<Trigger Property="IsEnabled" Value="True">
<Setter Property="Background" TargetName="border" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderBrush" TargetName="border" Value="{StaticResource Omag_Black}"/>
</Trigger>
<!--<Setter Property="Background" TargetName="border" Value="{StaticResource Omag_Black}"/>
<Setter Property="BorderBrush" TargetName="border" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" TargetName="border" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="BorderBrush" TargetName="border" Value="{StaticResource Gradient_Gray_Button}"/>
</Trigger>
<Trigger Property="IsSelected" Value="True">
<Setter Property="Background" TargetName="border" Value="{StaticResource Omag_Blue}"/>
<Setter Property="BorderBrush" TargetName="border" Value="{StaticResource Omag_Gray}"/>
@@ -1321,8 +1384,9 @@
<!-- ListBox -->
<Style x:Key="OptionWnd_ListBox" TargetType="{x:Type ListBox}" BasedOn="{StaticResource {x:Type ListBox}}">
<Setter Property="Background" Value="{StaticResource Omag_Black}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<!--<Setter Property="Background" Value="{StaticResource Omag_Black}"/>-->
<Setter Property="Background" Value="{StaticResource Gradient_Gray_Button}"/>
<Setter Property="Foreground" Value="{StaticResource Omag_White}"/>
<Setter Property="BorderThickness" Value="{StaticResource BorderBtn_Thickness}"/>
</Style>
File diff suppressed because it is too large Load Diff