EgtDOORCreator 2.2c4 :
- aggiunta quotatura su hardware per report. - aggiunti parametri quotature nelle opzioni.
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports System.Drawing.Text
|
||||
Imports System.ComponentModel
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
@@ -14,6 +16,30 @@ Public Class OptionsVM
|
||||
Private m_HardwarePartV As HardwarePartV
|
||||
Private m_HardwarePartVM As HardwarePartVM
|
||||
|
||||
Private m_UnitMeasureList As List(Of String) = New List(Of String)({"mm", "inch", EgtMsg(6545)})
|
||||
Public ReadOnly Property UnitMeasureList As List(Of String)
|
||||
Get
|
||||
Return m_UnitMeasureList
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Private m_FontList As New ObservableCollection(Of String)
|
||||
Public ReadOnly Property FontList As ObservableCollection(Of String)
|
||||
Get
|
||||
Dim sNfeDir As String = String.Empty
|
||||
GetMainPrivateProfileString(S_GEOMDB, K_NFEFONTDIR, "", sNfeDir)
|
||||
Dim EgtFontList As String() = Directory.GetFiles(sNfeDir)
|
||||
For i = 0 To EgtFontList.Count - 1
|
||||
m_FontList.Add(Path.GetFileName(EgtFontList(i)))
|
||||
Next
|
||||
Dim fonts As New InstalledFontCollection
|
||||
For i = 0 To fonts.Families.Count - 1
|
||||
m_FontList.Add(fonts.Families(i).Name)
|
||||
Next
|
||||
Return m_FontList
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property HardwarePart As ContentControl
|
||||
Get
|
||||
Return m_HardwarePartV
|
||||
@@ -47,7 +73,18 @@ Public Class OptionsVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
#End Region ' Hardware_part
|
||||
Private m_SelectedTabGeneral As Integer = 0
|
||||
Public Property SelectedTabGeneral As Integer
|
||||
Get
|
||||
Return m_SelectedTabGeneral
|
||||
End Get
|
||||
Set(value As Integer)
|
||||
m_SelectedTabGeneral = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
|
||||
#End Region ' Hardware_part
|
||||
|
||||
Public ReadOnly Property LanguageList As ObservableCollection(Of Language)
|
||||
Get
|
||||
@@ -176,6 +213,114 @@ Public Class OptionsVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
#Region "Dimensionig"
|
||||
|
||||
Public Property ExtLineLen As String
|
||||
Get
|
||||
Return LenToString(OptionModule.m_ExtLineLen, 5)
|
||||
End Get
|
||||
Set(value As String)
|
||||
Dim dVal As Double = 0
|
||||
If StringToLen(value, dVal) AndAlso dVal > 0 Then
|
||||
OptionModule.m_ExtLineLen = dVal
|
||||
EgtSetCurrDimensionStyle(m_ExtLineLen, m_ArrowLen, m_TextDist, m_LenIsMM, m_DecDigit, m_Font, m_TextHeight)
|
||||
WriteMainPrivateProfileString(S_DIMENSIONSTYLE, K_EXTLINELEN, DoubleToString(OptionModule.m_ExtLineLen, 5))
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property ArrowLen As String
|
||||
Get
|
||||
Return LenToString(OptionModule.m_ArrowLen, 5)
|
||||
End Get
|
||||
Set(value As String)
|
||||
Dim dVal As Double = 0
|
||||
If StringToLen(value, dVal) AndAlso dVal > 0 Then
|
||||
OptionModule.m_ArrowLen = dVal
|
||||
EgtSetCurrDimensionStyle(m_ExtLineLen, m_ArrowLen, m_TextDist, m_LenIsMM, m_DecDigit, m_Font, m_TextHeight)
|
||||
WriteMainPrivateProfileString(S_DIMENSIONSTYLE, K_ARROWLEN, DoubleToString(OptionModule.m_ArrowLen, 5))
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property TextDist As String
|
||||
Get
|
||||
Return LenToString(OptionModule.m_TextDist, 5)
|
||||
End Get
|
||||
Set(value As String)
|
||||
Dim dVal As Double = 0
|
||||
If StringToLen(value, dVal) AndAlso dVal > 0 Then
|
||||
OptionModule.m_TextDist = dVal
|
||||
EgtSetCurrDimensionStyle(m_ExtLineLen, m_ArrowLen, m_TextDist, m_LenIsMM, m_DecDigit, m_Font, m_TextHeight)
|
||||
WriteMainPrivateProfileString(S_DIMENSIONSTYLE, K_TEXTDIST, DoubleToString(OptionModule.m_TextDist, 5))
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property SelectedUnitMeasure As String
|
||||
Get
|
||||
If OptionModule.m_LenIsMM = 0 Then
|
||||
Return "inch"
|
||||
ElseIf OptionModule.m_LenIsMM = 1 Then
|
||||
Return "mm"
|
||||
Else
|
||||
Return EgtMsg(6545)
|
||||
End If
|
||||
End Get
|
||||
Set(value As String)
|
||||
Dim nVal As Integer = 2
|
||||
If value = "inch" Then
|
||||
nVal = 0
|
||||
ElseIf value = "mm" Then
|
||||
nVal = 1
|
||||
End If
|
||||
OptionModule.m_LenIsMM = nVal
|
||||
EgtSetCurrDimensionStyle(m_ExtLineLen, m_ArrowLen, m_TextDist, m_LenIsMM, m_DecDigit, m_Font, m_TextHeight)
|
||||
WriteMainPrivateProfileString(S_DIMENSIONSTYLE, K_LENISMM, OptionModule.m_LenIsMM.ToString())
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property DecDigit As String
|
||||
Get
|
||||
Return OptionModule.m_DecDigit.ToString()
|
||||
End Get
|
||||
Set(value As String)
|
||||
Dim nVal As Integer = 0
|
||||
If Integer.TryParse(value, nVal) AndAlso nVal > 0 Then
|
||||
OptionModule.m_DecDigit = nVal
|
||||
EgtSetCurrDimensionStyle(m_ExtLineLen, m_ArrowLen, m_TextDist, m_LenIsMM, m_DecDigit, m_Font, m_TextHeight)
|
||||
WriteMainPrivateProfileString(S_DIMENSIONSTYLE, K_DECDIGIT, OptionModule.m_DecDigit.ToString())
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property SelectedFont As String
|
||||
Get
|
||||
Return m_FontList(m_FontList.IndexOf(OptionModule.m_Font))
|
||||
End Get
|
||||
Set(value As String)
|
||||
OptionModule.m_Font = value
|
||||
EgtSetCurrDimensionStyle(m_ExtLineLen, m_ArrowLen, m_TextDist, m_LenIsMM, m_DecDigit, m_Font, m_TextHeight)
|
||||
WriteMainPrivateProfileString(S_DIMENSIONSTYLE, K_DIMFONT, OptionModule.m_Font)
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property TextHeight As String
|
||||
Get
|
||||
Return LenToString(OptionModule.m_TextHeight, 5)
|
||||
End Get
|
||||
Set(value As String)
|
||||
Dim dVal As Double = 0
|
||||
If StringToLen(value, dVal) AndAlso dVal > 0 Then
|
||||
OptionModule.m_TextHeight = dVal
|
||||
EgtSetCurrDimensionStyle(m_ExtLineLen, m_ArrowLen, m_TextDist, m_LenIsMM, m_DecDigit, m_Font, m_TextHeight)
|
||||
WriteMainPrivateProfileString(S_DIMENSIONSTYLE, K_TEXTHEIGHT, DoubleToString(OptionModule.m_TextHeight, 5))
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
#End Region ' Dimensioning
|
||||
|
||||
' Carico i valori di Default della porta
|
||||
Public Property WidthValue As String
|
||||
Get
|
||||
@@ -1137,6 +1282,70 @@ Public Class OptionsVM
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property GeneralOption As String
|
||||
Get
|
||||
' General
|
||||
Return EgtMsg(50716)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property GeneralCam As String
|
||||
Get
|
||||
' Report
|
||||
Return EgtMsg(50715)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property ExtLineLenMsg As String
|
||||
Get
|
||||
' Estensione linea
|
||||
Return EgtMsg(6537)
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property ArrowLenMsg As String
|
||||
Get
|
||||
' Dimensione freccia
|
||||
Return EgtMsg(6538)
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property TextDistMsg As String
|
||||
Get
|
||||
' Distanza messaggio
|
||||
Return EgtMsg(6539)
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property LenIsMMMsg As String
|
||||
Get
|
||||
' Unità di misura
|
||||
Return EgtMsg(6540)
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property DecDigitMsg As String
|
||||
Get
|
||||
' Numero dicmali
|
||||
Return EgtMsg(6541)
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property FontMsg As String
|
||||
Get
|
||||
' Caretteri
|
||||
Return EgtMsg(6542)
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property TextHeightMsg As String
|
||||
Get
|
||||
' Dimensione testo
|
||||
Return EgtMsg(6543)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property DimensionMsg As String
|
||||
Get
|
||||
' Quotatura
|
||||
Return EgtMsg(6544)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property DispConfiguration As String
|
||||
Get
|
||||
Dim Msg As String = String.Empty
|
||||
|
||||
Reference in New Issue
Block a user