|
@@ -669,6 +669,8 @@ namespace OTSMeasureApp
|
|
IDC_EDIT_QuantifyMinSize.Text = m_cotsxrayprm.GetFeatureModeMinSize().ToString();
|
|
IDC_EDIT_QuantifyMinSize.Text = m_cotsxrayprm.GetFeatureModeMinSize().ToString();
|
|
|
|
|
|
IDC_EDIT_SmallPartAQTime.Text = m_cotsxrayprm.GetFastXrayTime().ToString();
|
|
IDC_EDIT_SmallPartAQTime.Text = m_cotsxrayprm.GetFastXrayTime().ToString();
|
|
|
|
+
|
|
|
|
+ IDC_EDIT_XrayLimit.Text = m_cotsxrayprm.GetXrayLimit().ToString();
|
|
//IDC_XRAY_MODE_SWITCH.Checked = m_cotsxrayprm.GetShowScanMode();
|
|
//IDC_XRAY_MODE_SWITCH.Checked = m_cotsxrayprm.GetShowScanMode();
|
|
//IDC_XRAY_TIME_SWITCH.Checked = m_cotsxrayprm.GetShowSpeed();
|
|
//IDC_XRAY_TIME_SWITCH.Checked = m_cotsxrayprm.GetShowSpeed();
|
|
//IDC_XRAY_COUNT_SWITCH.Checked = m_cotsxrayprm.GetShowExpCount();
|
|
//IDC_XRAY_COUNT_SWITCH.Checked = m_cotsxrayprm.GetShowExpCount();
|
|
@@ -843,6 +845,8 @@ namespace OTSMeasureApp
|
|
m_cotsxrayprm.SetQuantifyMinSize(Convert.ToDouble(IDC_EDIT_QuantifyMinSize.Text));
|
|
m_cotsxrayprm.SetQuantifyMinSize(Convert.ToDouble(IDC_EDIT_QuantifyMinSize.Text));
|
|
|
|
|
|
m_cotsxrayprm.SetFastXrayTime(Convert.ToInt32(IDC_EDIT_SmallPartAQTime.Text));
|
|
m_cotsxrayprm.SetFastXrayTime(Convert.ToInt32(IDC_EDIT_SmallPartAQTime.Text));
|
|
|
|
+
|
|
|
|
+ m_cotsxrayprm.SetXrayLimit(Convert.ToInt32(IDC_EDIT_XrayLimit.Text));
|
|
//m_cotsxrayprm.SetShowScanMode(IDC_XRAY_MODE_SWITCH.Checked);
|
|
//m_cotsxrayprm.SetShowScanMode(IDC_XRAY_MODE_SWITCH.Checked);
|
|
//m_cotsxrayprm.SetShowSpeed(IDC_XRAY_TIME_SWITCH.Checked);
|
|
//m_cotsxrayprm.SetShowSpeed(IDC_XRAY_TIME_SWITCH.Checked);
|
|
//m_cotsxrayprm.SetShowExpCount(IDC_XRAY_COUNT_SWITCH.Checked);
|
|
//m_cotsxrayprm.SetShowExpCount(IDC_XRAY_COUNT_SWITCH.Checked);
|
|
@@ -1285,9 +1289,11 @@ namespace OTSMeasureApp
|
|
string pat = @"^-?[0-9]\d*$";//只能限定正负整数,包含0
|
|
string pat = @"^-?[0-9]\d*$";//只能限定正负整数,包含0
|
|
string scope = @"^(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])$";
|
|
string scope = @"^(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])$";
|
|
string PositiveDecimals = @"^(([1-9]\d*)(\.\d+)?)$|^0\.\d*[1-9]$"; //正浮点数
|
|
string PositiveDecimals = @"^(([1-9]\d*)(\.\d+)?)$|^0\.\d*[1-9]$"; //正浮点数
|
|
|
|
+ string positiveInteger = @"^?[0-9]\d*$";//只能限定正整数,包含0
|
|
Regex rg = new Regex(pat);
|
|
Regex rg = new Regex(pat);
|
|
Regex rgScope = new Regex(scope);
|
|
Regex rgScope = new Regex(scope);
|
|
Regex rgPositiveDecimals = new Regex(PositiveDecimals);
|
|
Regex rgPositiveDecimals = new Regex(PositiveDecimals);
|
|
|
|
+ Regex rgpositiveInteger = new Regex(positiveInteger);
|
|
//是否是正确的数值格式类型判断
|
|
//是否是正确的数值格式类型判断
|
|
//100倍时屏幕尺寸
|
|
//100倍时屏幕尺寸
|
|
if (false == rg.Match(IDC_EDIT_SCREENWIDTH.Text.Trim()).Success)
|
|
if (false == rg.Match(IDC_EDIT_SCREENWIDTH.Text.Trim()).Success)
|
|
@@ -1601,6 +1607,15 @@ namespace OTSMeasureApp
|
|
MessageBox.Show(message, "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
|
|
MessageBox.Show(message, "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
|
|
return false;
|
|
return false;
|
|
}
|
|
}
|
|
|
|
+ //最小放大倍数
|
|
|
|
+ if (false == rgpositiveInteger.Match(IDC_EDIT_XrayLimit.Text.Trim()).Success)
|
|
|
|
+ {
|
|
|
|
+ IDC_EDIT_XrayLimit.Focus();
|
|
|
|
+ IDC_EDIT_XrayLimit.SelectAll();
|
|
|
|
+ string message = table["message64"].ToString();
|
|
|
|
+ MessageBox.Show(message, "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
|
|
|
|
+ return false;
|
|
|
|
+ }
|
|
return true;
|
|
return true;
|
|
}
|
|
}
|
|
|
|
|